... To everyone ...
Please run tests and small example programs, made by you, to learn the basic concept of programming... Once that is understood, the syntax of any language is the real challenge...
So in your case, mark.sparky, there's multiple ways to determine what direction, even with your vague question... As for when a button isnt pressed, Im using the basic concept of the 'not' operator with-in an argument/function returning 1 on pressed, 'not-1' when not pressed... So you do the basic puesdo code for this...
I dont even know probably 1/2 of the LUA syntax as an average LUA coder does, yet i understand the concept/routines to use in accomplishing what you want... It comes in very handy... Anyway, good luck with your new game mark.sparky!Code:-- I dont know all the syntax of LUA, so w/e the 'not' operator is, use it... Im
-- guessing it's the ~ thing... in C its the !
while true do
sg57 = Controls.read()
-- Ex: Pause
if ~sg57:start() then
--While not paused, have movement calls here
else -- if start is pressed
-- app now paused...
end
end
