• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Dla czego

GrubeJointy2

nIe Ma PrObLeMu
Joined
Aug 5, 2011
Messages
101
Reaction score
0
Location
Łódź
Witam, skrypt działa idealnie czyli zero błedu w konsoli ale gdy wykonam reload to następuję crash. Crashuje na pewno ten skrypt może będzie ktoś wiedział dla czego :)


local trainery = {x=431, y=1367, z=5}

function onStepIn(cid, item, item2, fromPos, toPos, pos)

if (item.actionid == 998) then
doTeleportThing(cid, trainery)
setPlayerStorageValue(cid, 998, 1)
doPlayerSendTextMessage(cid, 19, "Lece z enigma")
doSendMagicEffect(getPlayerPosition(cid), 14)


else

if (item.actionid == 999) then
doTeleportThing(cid, trainery)
setPlayerStorageValue(cid, 999, 1)
doPlayerSendTextMessage(cid, 19, "Lece z thais")
doSendMagicEffect(getPlayerPosition(cid), 14)


end
end
return true
end
 
Teraz użyłem elseif bez jednego enda i to samo. Przy przeładowaniu crash :(

local tp = {x=431, y=1367, z=5}

function onStepIn(cid, item, item2, fromPos, toPos, pos)

if (item.actionid == 997) then --venore
doTeleportThing(cid, tp)
setPlayerStorageValue(cid, 997, 1)
doSendMagicEffect(getPlayerPosition(cid), 14)
return false

elseif (item.actionid == 998) then --enigma
doTeleportThing(cid, tp)
setPlayerStorageValue(cid, 998, 1)
doSendMagicEffect(getPlayerPosition(cid), 14)
return false

elseif (item.actionid == 999) then --thais
doTeleportThing(cid, tp)
setPlayerStorageValue(cid, 999, 1)
doSendMagicEffect(getPlayerPosition(cid), 14)
return false

end
return TRUE
end
 
Last edited:
Kolejny z wieeeelu bugów TFS 0.4. Winą są tutaj średniki, zmień tą linię na:
Code:
<movevent type="StepIn" actionid="997" event="script" value="trainstor2.lua"/>
<movevent type="StepIn" actionid="998" event="script" value="trainstor2.lua"/>
<movevent type="StepIn" actionid="999" event="script" value="trainstor2.lua"/>
 
Last edited:
Back
Top