frozenLake

Untitled

Sep 27th, 2014
255
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.78 KB | None | 0 0
  1. local v6flips
  2.  
  3. addHook("ThinkFrame", do
  4. for player in players.iterate
  5. if not P_IsObjectOnGround(player.mo) and player.mo.state ~= S_PLAY_SPRING
  6. P_SetObjectMomZ(player.mo,-16*FRACUNIT)
  7. if player.mo.state ~= S_PLAY_FALL1 and player.mo.state ~=S_PLAY_FALL2
  8. player.mo.state = S_PLAY_FALL1
  9. end
  10. end
  11. if player.pamim==PA_IDLE or player.pamim==PA_WALK or player.pamim==PA_RUN
  12. v6flips=0
  13. end
  14. end
  15. end)
  16.  
  17. addHook("JumpSpecial", do
  18. for player in players.iterate
  19. if player.pflags ~= player.pflags|PF_JUMPDOWN
  20. if player.mo.health>10 or v6flips<1
  21. player.mo.flags2 = $1^^MF2_OBJECTFLIP
  22. player.mo.health = $1-10
  23. player.health = $1-10
  24. player.mo.state = S_PLAY_FALL1
  25. v6flips=$1+1
  26. end
  27. end
  28. end
  29. return true
  30. end)
Advertisement
Add Comment
Please, Sign In to add comment