Disable levitate effects in certain zones?
Zones like the hole (where on live levitation effects are disabled), or other zones where players can currently levitate their way to success by climbing some wall then floating over to the top floor of some building or whatnot is a pain... I am wondering if anyone knows of a way or can think of a doable way to force levitate effects off in a zone?
We have some zones that are pretty much an open book if players can levitate to laces they shouldn't be able to get to. I'd love to be able to turn levitation off in those zones. Just wondering if anyone can offer some guidance on how this may be accomplished. Thank you. |
What about if someone smarter than I can modify the #nukebuffs command so that it can also nuke single spells? Maybe a #nukebuff command can be added that works like:
#nukebuff <spellid> and it nukes that buff from the player whereas #nukebuffs will still nuke them all? Can make it a quest object too and in scripts we can put an invisible mob in the game with a proximity check that will $client->nukebuff(spellnum) the spells we want nuked. A fancy way to do it might be to give it an array as input, so we can list the spells to nuke... like: $client->nukebuff(spell1,spell2,spell3,spell4,spell5) And #nukebuff spell1 spell2 spell3 spell4 Like that. This alone would give us the ability to emulate zones like Siren's grotto properly (nuking the speed/lev buffs at the zone in) OR even set an npc in the middle of the zone with a zone-wide proximity trigger and a timer that keeps them nuked in a zone. I'm sure there's a cleaner way to approach this... such as setting zone flags in the database to allow or disallow and having something global simply turning those spells off in those zones or whatnot.... but heck, I dunno. I just think this is badly needed, especially since it IS available on live and should be emulated if at all possible, you know? Oh, also, it will definitely help against certain exploits where people can levitate, climb stuff then float to parts of the zone they should be so easily able to reach without fighting their way to them. |
I think we should really just make certain zones lev restricted, I noticed it a while back too but haven't gotten around to implementing it yet.
|
Yes that WOULD be the best solution for certain.
Would there be any way to choose which zones are level restricted too (I mean, they wouldn't be hardcoded would they?) I ask because for example, we're working on a custom zone (an OZ zone that we made) and it has lots of towers in it and multi level stuff. We'd definitely want lev off in that zone. |
l would be nice to be able to nukebuff just one buff from a player though... so that if a GM only wants to remove one effect from a player, they can, without having to nuke them all just to get rid of the one.
|
As requested, zone can be levitate restricted.
http://eqoffline.free.fr/levitrestricted.jpg Code changes: 1/ In zone.h, after Code:
bool CanDoCombat() const { return(can_combat); } Code:
bool CanLevitate() const {return(can_levitate); } Code:
bool can_combat; Code:
bool can_levitate; replace Code:
bool GetZoneCFG(int32 zoneid, NewZone_Struct *data, bool &can_bind, bool &can_combat); Code:
bool GetZoneCFG(int32 zoneid, NewZone_Struct *data, bool &can_bind, bool &can_combat, bool &can_levitate); replace Code:
if(!database.GetZoneCFG(database.GetZoneID(filename), &newzone_data, can_bind, can_combat)) { Code:
if(!database.GetZoneCFG(database.GetZoneID(filename), &newzone_data, can_bind, can_combat, can_levitate)) { replace Code:
bool ZoneDatabase::GetZoneCFG(int32 zoneid, NewZone_Struct *zone_data, bool &can_bind, bool &can_combat) { Code:
bool ZoneDatabase::GetZoneCFG(int32 zoneid, NewZone_Struct *zone_data, bool &can_bind, bool &can_combat, bool &can_levitate) { find Code:
if(!IsValidSpell(spell_id)) Code:
if( IsEffectInSpell(spell_id, SE_Levitate) && !zone->CanLevitate() ) replace Code:
case SE_Levitate: Code:
case SE_Levitate: Code:
alter table `zone` add column `canlevitate` tinyint (4) DEFAULT '1' NOT NULL after `cancombat` It seems to work correctly. Mag. |
Incredible!!! Thank You!
|
This IS INDEED great!
KLS or someone, please, this is SO BADLY needed... can it be committed please? |
I have this up on TGC and it indeed is working wonderfully. It even strips lev off the player if they enter a no lev zone already buffed. Very nice.
This thread should be moved to Development submission, but I'll let Wild know about it. |
Thanks Magoth78! I was wondering if you could do the same with SOW? I'm tired of seeing NPC's in dungeons running around on like if they snorted coke - not to mention PC's shouldn't be sowed either.
|
That goes for any "indoor" spell. Right now, Druids are really doing pretty well for themselves because they can cast anywhere. A good portion of their spells should be outdoor only. I think there is data in the spell files concerning whether a spell is restricted by indoor/outdoor. Perhaps that can be tapped into and a new column in zone be created?
|
I was looking for this code a week ago but couldn't find it.. buried in another post apparently.
I'll probably mod it to apply to all indoor type spells. |
Quote:
/em remembers /shouting "SNARE!! SNARE!!! FOR THE LOVE OF GOD, SNARE IT!!!!" == sfisque |
Excellent, thank you!!
|
Any chance we can get this code in the source?
Thanks in advance |
All times are GMT -4. The time now is 02:17 AM. |
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.