Difference between revisions of "Talk:Make character disappear"

280 bytes removed ,  13:46, 13 April 2006
m
removing my now-redundant commentary
imported>JBurgess
imported>JBurgess
m (removing my now-redundant commentary)
Line 1: Line 1:
--[[User:Mrflippy|Mrflippy]] 13:15, 12 April 2006 (EDT): I think OnDeath is only run once. I would try putting code in the GameMode block and running it if the actor is dead. (I think there's a check?)
--[[User:Mrflippy|Mrflippy]] 13:15, 12 April 2006 (EDT): I think OnDeath is only run once. I would try putting code in the GameMode block and running it if the actor is dead. (I think there's a check?)
You can deadguy.getav health <= 0, but it's probably more efficient to set a flag in your onDeath block.  So you may have this:
<pre>
short DeathFlag
begin onDeath
    set DeathFlag to 1
end
begin gameMode
    if DeathFlag == 1
        ; do stuff here
    endif
end
</pre>
Anonymous user