diff --git a/bin/scripts/exit.def b/bin/scripts/exit.def index 615b97b..71be10a 100644 --- a/bin/scripts/exit.def +++ b/bin/scripts/exit.def @@ -1,3 +1,4 @@ +#permission=255 // just a name alternative QUIT \ No newline at end of file diff --git a/src/Client/World/CMSGConstructor.cpp b/src/Client/World/CMSGConstructor.cpp index fb2827f..a68c6b3 100644 --- a/src/Client/World/CMSGConstructor.cpp +++ b/src/Client/World/CMSGConstructor.cpp @@ -91,12 +91,18 @@ void WorldSession::SendSetSelection(uint64 guid) SendWorldPacket(packet); } -void WorldSession::SendCastSpell(uint32 spellid) +void WorldSession::SendCastSpell(uint32 spellid, bool nocheck) { if(!spellid) return; MyCharacter *my = GetMyChar(); - bool known = my->HasSpell(spellid); + bool known = nocheck ? true : my->HasSpell(spellid); + + //-- TEMP FIX --// TODO: need a list of spells that is excluded from the check and can always be casted. + // settable via DefScript? + if(spellid==836) + known=true; + if( (!known) && (!GetInstance()->GetConf()->disablespellcheck) ) { logerror("Attempt to cast not-known spell %u",spellid); diff --git a/src/Client/World/WorldSession.h b/src/Client/World/WorldSession.h index 0f689e1..8ebeb96 100644 --- a/src/Client/World/WorldSession.h +++ b/src/Client/World/WorldSession.h @@ -60,7 +60,7 @@ public: void SendEmote(uint32); void SendQueryItem(uint32, uint64); void SendSetSelection(uint64); - void SendCastSpell(uint32); + void SendCastSpell(uint32 spellid, bool nocheck=false); PlayerNameCache plrNameCache; ObjMgr objmgr;