To disable spell casting in a zone?
I am currently learning C++ and I know sql... though I imagine it needs to be done with C++ in the source...
Anyway, does anyone have any information/resources or ideas on how to disable spell casting or to specifically disable certian spells in a zone? For example to disable the use of teleports and gates in plane of justice...or to just simply disable spell casting. Thanks in advance... |
This would definitely need custom code. The method that handles cast spell requests would just need to check the zone id before it processed anything for the spell.
|
actualy i believer that info is handled by the spell themselves.
|
its in client_process.cpp OP_Castspell
|
I'm not too good with C++, I'll use the weekend to try and figure out the syntax, but basically it would need to be an "if" line of if zone=soandso... in proper syntax ofcourse?
Or does it need to be an if line with specification if "if" is met... I was looking at the syntax of other lines near it and assumed it would automatically end the cast spell if the "if" was met, unless "break" was to end the cast if "if" was met. |
Quote:
|
But could you not then designate an area of a zone as one of those types?
|
OK in OP_Castspell (clientprocess.cpp if you didn't know)
under Code:
CastSpell_Struct* castspell = (CastSpell_Struct*)app->pBuffer; Code:
if (zone->GetZoneID() == 152 && castspell->spell_id == 13) |
Funny thing is if I recall correctly at one point in time certain spells could only be cast in certain zones... Like the druid port to EJ could only be cast in KC.
|
Quote:
Thus you had people going from Dreadlands to KC to have it cast, since KC was indoors and DL was outdoors. |
Oh, didn't know that :oops: at the time I was a newbie and had only played a warrior. Thought it only worked in KC since I started a druid after the patch that changed it.
|
All times are GMT -4. The time now is 10:29 AM. |
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.