aleixbcn90
New Member
- Joined
- Dec 18, 2010
- Messages
- 6
- Reaction score
- 0
The error is:
[04/01/2011 02:20:21] Lua Script Error: [MoveEvents Interface]
[04/01/2011 02:20:21] data/movements/scripts/citizen.luanStepIn
[04/01/2011 02:20:21] data/movements/scripts/citizen.lua:5: attempt to call global 'getTownName' (a nil value)
[04/01/2011 02:20:21] stack traceback:
[04/01/2011 02:20:21] [C]: in function 'getTownName'
[04/01/2011 02:20:21] data/movements/scripts/citizen.lua:5: in function <data/movements/scripts/citizen.lua:1>
While i'm using TFS 0.2.9.0 with scripts on movement:
movement.xml
and for citizen.xml
PLZ HELP ME!!
[04/01/2011 02:20:21] Lua Script Error: [MoveEvents Interface]
[04/01/2011 02:20:21] data/movements/scripts/citizen.luanStepIn
[04/01/2011 02:20:21] data/movements/scripts/citizen.lua:5: attempt to call global 'getTownName' (a nil value)
[04/01/2011 02:20:21] stack traceback:
[04/01/2011 02:20:21] [C]: in function 'getTownName'
[04/01/2011 02:20:21] data/movements/scripts/citizen.lua:5: in function <data/movements/scripts/citizen.lua:1>
While i'm using TFS 0.2.9.0 with scripts on movement:
movement.xml
PHP:
<!-- Citizen teleport -->
<movevent event="StepIn" itemid="1387" script="citizen.lua"/>
and for citizen.xml
PHP:
function onStepIn(cid, item, position, fromPosition)
if(item.actionid > 30020 and item.actionid < 30100) then
local townId = (item.actionid - 30020)
doPlayerSetTown(cid, townId)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You are the newest resident of " .. getTownName(townId) .. ".")
end
return true
end
PLZ HELP ME!!