Pomoc Skrypt LUA

Shazoru

New User
Zarejestrowany
Dołączył
Październik 16, 2022
Posty
6
Liczba reakcji
0
Witajcie ma skrypt że za 2NG zabiera na expowisko.
Potrzebuje by sprawdzal LVL i jezeli lvl jest to przeniesie jeżeli lvl brak to nie wezmie ng i nie przeteleportuje.

Kod:
function onUse(cid, item, frompos, item2, topos)

if item.uid == 18901 then
kasapos = {x=1248, y=276, z=8, stackpos=255}
getkasa = getThingfromPos(kasapos)
topos = {x=1248, y=274, z=8}

if getkasa.itemid == 2157 and getkasa.type == 2 then
doRemoveItem(getkasa.uid,2)
doTeleportThing(cid,topos)
doSendAnimatedText(topos,'Exp Run!',190)

else
doPlayerSendTextMessage(cid,22,"Poloz obok dzwigni 2 NG, aby wejsc na expowisko!.")
end

return 1
end
end

Próbowałem na tej zasadzie:
Kod:
function onUse(cid, item, frompos, item2, topos)
lvl = 60000
if item.uid == 18901 then
if getPlayerLevel(cid) < lvl then
kasapos = {x=1248, y=276, z=8, stackpos=255}
getkasa = getThingfromPos(kasapos)
topos = {x=1248, y=274, z=8}
else
doPlayerSendTextMessage(cid,22,"Aby dostac sie na Expowisko'a musisz posiadać 60k LVL!.")
end
if getkasa.itemid == 2157 and getkasa.type == 2 then
doRemoveItem(getkasa.uid,2)
doTeleportThing(cid,topos)
doSendAnimatedText(topos,'Exp Run!',190)

else
doPlayerSendTextMessage(cid,22,"Poloz obok dzwigni 2 NG, aby wejsc na expowisko!.")
end

return 1
end
end

I dupa.
 
Ok do zamknięcia ktoś pomógł na gg. Dziękuje i przepraszam.
 
Back
Do góry