Hello help me with this script, I want you to ask for several storages to be able to pass
these would be the other storages
these would be the other storages
- Storage.GraveDanger.CobraBastion.DukeKill
- Storage.GraveDanger.CobraBastion.LordKill
- Storage.GraveDanger.CobraBastion.TwinsKill
- Storage.GraveDanger.CobraBastion.VlarkKill
- Storage.GraveDanger.CobraBastion.EarlKill
Lua:
local hauntedhoused = Action()
function hauntedhoused.onUse(player, item, fromPosition, target, toPosition, isHotkey)
if player:getStorageValue(Storage.GraveDanger.CobraBastion.DukeKill) == 1 then
if item.actionid == 23151 then
if item.itemid == 6261 then
player:teleportTo(toPosition, true)
item:transform(item.itemid + 1)
elseif item.itemid == 6262 then
if Creature.checkCreatureInsideDoor(player, toPosition) then
return true
end
if item.itemid == 6262 then
item:transform(item.itemid - 1)
return true
end
end
end
else
player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "You need to kill all bosses of Grave Danger Quest to pass.")
end
return true
end
hauntedhoused:aid(23151)
hauntedhoused:register()