Fix trap removal

This commit is contained in:
Michael Cook (mackal) 2017-07-24 22:58:58 -04:00
parent 6bf2cf8cb8
commit f6f3060c9d
2 changed files with 12 additions and 1 deletions

View File

@ -11805,7 +11805,17 @@ void Client::Handle_OP_RemoveTrap(const EQApplicationPacket *app)
}
auto id = app->ReadUInt32(0);
RemoveAura(id);
bool good = false;
for (int i = 0; i < trap_mgr.count; ++i) {
if (trap_mgr.auras[i].spawn_id == id) {
good = true;
break;
}
}
if (good)
RemoveAura(id);
else
Message_StringID(MT_SpellFailure, NOT_YOUR_TRAP); // pretty sure this was red
}
void Client::Handle_OP_Report(const EQApplicationPacket *app)

View File

@ -286,6 +286,7 @@
#define TRADESKILL_LEARN_RECIPE 3457 //You have learned the recipe %1!
#define EXPEDITION_MIN_REMAIN 3551 //You only have %1 minutes remaining before this expedition comes to an end.
#define LOOT_NOT_ALLOWED 3562 //You are not allowed to loot the item: %1.
#define NOT_YOUR_TRAP 3671 //You cannot remove this, you are only allowed to remove traps you have set.
#define NO_CAST_ON_PET 4045 //You cannot cast this spell on your pet.
#define REWIND_WAIT 4059 //You must wait a bit longer before using the rewind command again.
#define CORPSEDRAG_LIMIT 4061 //You are already dragging as much as you can!