Add files via upload

This commit is contained in:
Dinkledork
2023-03-12 08:55:05 -06:00
committed by GitHub
parent 42dfad0ec5
commit 5f808c0589
17 changed files with 490 additions and 29 deletions

View File

@@ -4,6 +4,8 @@ local NPC_ID = 400034 -- The ID of the NPC you want players to get kill credit f
local ALLOWED_ZONES = {
1519, -- SW City
12,
14,
1637
}
-- List of allowed spell IDs
@@ -32,7 +34,7 @@ function OnPlayerCastSpell(event, player, spell)
if table.indexOf(ALLOWED_SPELLS, spellId) ~= -1 then
if table.indexOf(ALLOWED_ZONES, zoneId) == -1 then
spell:Cancel()
player:SendBroadcastMessage("You cannot cast this spell in this area.")
player:SendBroadcastMessage("You cannot use that here.")
else
player:KilledMonsterCredit(NPC_ID)
player:SendBroadcastMessage("You have successfuly placed a trap!")