Demo entry 6357547

123

   

Submitted by 1 on Apr 23, 2017 at 08:56
Language: Lua. Code size: 318 Bytes.

local status {
	duck = {
		RELEASE_DOWN = "stand"
	},
	stand = {
		PRESS_UP = "jump"
		PRESS_DOWN = "duck"
	},
	jump = {
		PRESS_DOWN = "skill"
	},
	skill = {

	},
}

function handleInput(key)
	local nextStatus = status.currStatus[key]
	if nextStatus ~= nil then
		currStatus = nextStatus
	end
end

This snippet took 0.00 seconds to highlight.

Back to the Entry List or Home.

Delete this entry (admin only).