Advertisement
Guest User

Untitled

a guest
Aug 10th, 2016
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.85 KB | None | 0 0
  1. actor thingy replaces healthbonus
  2. {
  3. var int user_xAdd;
  4. var int user_yAdd;
  5. var int user_Pos;
  6. States
  7. {
  8. Spawn:
  9. BON1 A 0 NoDelay
  10. {
  11. A_SetUserVar ("user_xAdd",x);
  12. A_SetUserVar ("user_yAdd",y);
  13.  
  14. if (user_xAdd < 0)
  15. {
  16. A_SetUserVar ("user_xAdd",-user_xAdd); // Makes x positive.
  17. }
  18.  
  19. if (user_yAdd < 0)
  20. {
  21. A_SetUserVar ("user_yAdd",-user_yAdd); // Makes y positive.
  22. }
  23.  
  24. A_SetUserVar ("user_Pos",((user_xAdd+1024) * (user_yAdd+1024) / 997));
  25. }
  26. BON1 A 0 A_Jumpif (user_Pos % 4 == 0, "Zero")
  27. BON1 A 0 A_Jumpif (user_Pos % 4 == 1, "One")
  28. BON1 A 0 A_Jumpif (user_Pos % 4 == 2, "Two")
  29. BON1 A 0 A_Jumpif (user_Pos % 4 == 3, "Three")
  30. fallback:
  31. ROCK ABCDCB 6
  32. stop
  33. Zero:
  34. BON1 ABCDCB 6
  35. Loop
  36. One:
  37. BON2 ABCDCB 6
  38. Loop
  39. Two:
  40. SHEL A 6
  41. Loop
  42. Three:
  43. STIM A 6
  44. Loop
  45. }
  46. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement