i have tp in Venore with UniqueID 8000 , after enter you became citizen , in Edron its 8001 , Carlin 8002 , take a look at my script , what i did wrong?
Lua:
function onStepIn(cid, item, position, fromPosition)
if item.uniqueid > 8000 and item.uniqueid < 8100 then
doPlayerSetTown(cid, item.uniqueid - 8000)
if getPlayerTown(cid) == 1 then
doSendAnimatedText(playerPos, 'You became citizen of a Venore', TEXTCOLOR_GOLD)
elseif getPlayerTown(cid) == 2 then
doSendAnimatedText(playerPos, 'You became citizen of a Edron', TEXTCOLOR_GOLD)
elseif getPlayerTown(cid) == 3 then
doSendAnimatedText(playerPos, 'You became citizen of a Carlin', TEXTCOLOR_GOLD)
end
end
return TRUE
end
Last edited: