eardrums
Member
- Joined
- May 27, 2010
- Messages
- 101
- Solutions
- 1
- Reaction score
- 11
Hi!
I am trying to make a script that makes you able to walk on lava if you only have firewalker boots on. If you dont then the lava will kill you. So this is what I did
Now the problem is that when I step on the lava regardless if I'm wearing the id 2646 it always burns me. I know 2646 is golden boots but lets just pretend thats the id for firewalker boots. Now I want to know what the problem is. What did I do wrong? Im still beginning to understand scripting
and dont worry i didnt forget to type the lava id in the action files.
I am trying to make a script that makes you able to walk on lava if you only have firewalker boots on. If you dont then the lava will kill you. So this is what I did
Code:
local slot = 8
local condition = createConditionObject(CONDITION_FIRE)
setConditionParam(condition, CONDITION_PARAM_PERIODICDAMAGE, -99999)
setConditionParam(condition, CONDITION_PARAM_TICKINTERVAL, 20000)
function onStepIn(cid, item, pos)
if isPlayer(cid) then
if getPlayerSlotItem(cid, slot) == 2646 == TRUE then
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
elseif getPlayerSlotItem(cid, slot) == 2646 == FALSE then
doCreatureSay(cid, "IT BURNS!", TALKTYPE_ORANGE_1)
doAddCondition(cid, condition)
end
end
return TRUE
end
Now the problem is that when I step on the lava regardless if I'm wearing the id 2646 it always burns me. I know 2646 is golden boots but lets just pretend thats the id for firewalker boots. Now I want to know what the problem is. What did I do wrong? Im still beginning to understand scripting