Sky The Destroyer
Member
I'm just experimenting with Lua for my own personal pleasure and I'm trying to get this to work:
But MT_SMOKE doesn't work. I've tried MT_SMOK and MT_SMOKE, but neither work. They don't spawn at all. They only spawn in the first frame that I move, then never spawn ever again.
Code:
addHook("ThinkFrame", do
for player in players.iterate
if P_IsObjectOnGround(player.mo, player.mo) // If the player is on the ground...
and not player.mo.state==S_PLAY_STND // And not standing...
and not player.mo.state>=S_PLAY_TAP1 // And not idling...
and not player.mo.state>=S_PLAY_TEETER1 // And not teetering on an edge...
P_SpawnMobj(player.mo.x, player.mo.y, player.mo.z, MT_SMOKE) // Spawn a smoke object.
end
end
end)
But MT_SMOKE doesn't work. I've tried MT_SMOK and MT_SMOKE, but neither work. They don't spawn at all. They only spawn in the first frame that I move, then never spawn ever again.