chackie
New Member
- Joined
- Nov 1, 2009
- Messages
- 87
- Reaction score
- 0
EDITED:
Can someone help me fix this script:
THE PROBLEM:
The things that needs to be fixed.. If Player A pulled the lever and dies in the quest, then player B gets message: "you cannot enter until whos there finishes the quest!" Can someone fix if player A gets offline (dies or logg off) then player B can pulled the lever.
Can someone help me fix this script:
Code:
local annihistorage = 8790
local annihiglobalstorage = 8679
local demonposition = {x=EDIT, y=EDIT, z=EDIT} ------ Position where player will be teleported.
function onUse(cid, item, fromPosition, itemEx, toPosition)
if getPlayerStorageValue(cid,annihistorage) < 1 then
if getGlobalStorageValue(cid,annihiglobalstorage) < 1 then
setGlobalStorageValue(cid,annihiglobalstorage,1)
doTeleportThing(cid,demonposition)
else
doPlayerSendCancel(cid, "You cannot enter until whos there finishes the quest!")
end
else
doPlayerSendCancel(cid, "You have already done this quest")
end
return true
end
Code:
<movevent type="StepIn" uniqueid="29333" event="script" value="tp.lua"/>
Code:
local annihiglobalstorage = 8679
local position = {x=EDIT, y=EDIT, z=EDIT} ---- Position you go when you leave annihi reward room
function onStepIn(cid, item, pos)
doTeleportThing(cid,position)
setGlobalStorageValue(cid,annihiglobalstorage,-1)
return true
end
THE PROBLEM:
The things that needs to be fixed.. If Player A pulled the lever and dies in the quest, then player B gets message: "you cannot enter until whos there finishes the quest!" Can someone fix if player A gets offline (dies or logg off) then player B can pulled the lever.
Last edited: