Follow-up Comment #7, patch #3495 (project freeciv):
>According to http://freeciv.wikia.com/wiki/Lua_reference_manual#find this
would be (if it is working) the missing function: Player find.leader
It's not working.
local owner = find.player(0)
Test (not working)
local owner = find.leader(Swedish)
local owner = find.leader('Swedish')
local owner = find.leader("Swedish")
local owner = find.leader(nation_swedish)
local owner = find.leader('nation_swedish')
local owner = find.leader("nation_swedish")
Error: [string "script.code"]:4: attempt to call field 'leader' (a nil value)
>Question: should such functions be collected in something like a lua
I don't know. I write my function in scenario files between [script] code=$
Now I test the (untested) function, but... Where should I insert? Function
turn_cb(turn, year) or function city_nation_swedish()?
Reply to this item at:
Message sent via/by Gna!
Freeciv-dev mailing list