Coding problom
Fri, 2011-11-25 17:55
I want so when you start a turn that you have no weapon equipped. Heres what I have thats not working.
loadfile(GetDataPath() .. "Scripts/Locale.lua")()
function onNewTurn
set weapon to amNothing
end
lol yes not much. But Its not working. Anyone know how to do this?
Hi, the problem I see is that you do not know how Lua works.
Try looking at existing scripts and some of our wiki pages from here (http://code.google.com/p/hedgewars/w/list) related to Lua and maybe search google for a quick Lua tutorial.
If you after that have other questions you can ask on our irc-channel.
Ps. there is a game mode that already resets weapons on new turn, you HAVE TO use that one as it is not possible to change the ammo store later on in lua.
Good Luck
One of those hedgewars developers. I am specially knowledgeable in lua scripting, and the father of gameplay scripts.