Advertisement
Guest User

Untitled

a guest
Jun 19th, 2019
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.77 KB | None | 0 0
  1. stock void DEBUG_PrintButtons(int buttons, const char[] message) {
  2. char button_text[128];
  3. Format(button_text, sizeof(buttons), "|");
  4. if (buttons & IN_ATTACK)
  5. Format(button_text, sizeof(buttons), "%sIN_ATTACK|", button_text);
  6. if (buttons & IN_JUMP)
  7. Format(button_text, sizeof(buttons), "%sIN_JUMP|", button_text);
  8. if (buttons & IN_DUCK)
  9. Format(button_text, sizeof(buttons), "%sIN_DUCK|", button_text);
  10. if (buttons & IN_FORWARD)
  11. Format(button_text, sizeof(buttons), "%sIN_FORWARD|", button_text);
  12. if (buttons & IN_BACK)
  13. Format(button_text, sizeof(buttons), "%sIN_BACK|", button_text);
  14. if (buttons & IN_USE)
  15. Format(button_text, sizeof(buttons), "%sIN_USE|", button_text);
  16. if (buttons & IN_CANCEL)
  17. Format(button_text, sizeof(buttons), "%sIN_CANCEL|", button_text);
  18. if (buttons & IN_LEFT)
  19. Format(button_text, sizeof(buttons), "%sIN_LEFT|", button_text);
  20. if (buttons & IN_RIGHT)
  21. Format(button_text, sizeof(buttons), "%sIN_RIGHT|", button_text);
  22. if (buttons & IN_MOVELEFT)
  23. Format(button_text, sizeof(buttons), "%sIN_MOVELEFT|", button_text);
  24. if (buttons & IN_MOVERIGHT)
  25. Format(button_text, sizeof(buttons), "%sIN_MOVERIGHT|", button_text);
  26. if (buttons & IN_ATTACK2)
  27. Format(button_text, sizeof(buttons), "%sIN_ATTACK2|", button_text);
  28. if (buttons & IN_RUN)
  29. Format(button_text, sizeof(buttons), "%sIN_RUN|", button_text);
  30. if (buttons & IN_RELOAD)
  31. Format(button_text, sizeof(buttons), "%sIN_RELOAD|", button_text);
  32. if (buttons & IN_ALT1)
  33. Format(button_text, sizeof(buttons), "%sIN_ALT1|", button_text);
  34. if (buttons & IN_ALT2)
  35. Format(button_text, sizeof(buttons), "%sIN_ALT2|", button_text);
  36. if (buttons & IN_SCORE)
  37. Format(button_text, sizeof(buttons), "%sIN_SCORE|", button_text);
  38. if (buttons & IN_SPEED)
  39. Format(button_text, sizeof(buttons), "%sIN_SPEED|", button_text);
  40. if (buttons & IN_ZOOM)
  41. Format(button_text, sizeof(buttons), "%sIN_ZOOM|", button_text);
  42. if (buttons & IN_WEAPON1)
  43. Format(button_text, sizeof(buttons), "%sIN_WEAPON1|", button_text);
  44. if (buttons & IN_WEAPON2)
  45. Format(button_text, sizeof(buttons), "%sIN_WEAPON2|", button_text);
  46. if (buttons & IN_BULLRUSH)
  47. Format(button_text, sizeof(buttons), "%sIN_BULLRUSH|", button_text);
  48. if (buttons & IN_GRENADE1)
  49. Format(button_text, sizeof(buttons), "%sIN_GRENADE1|", button_text);
  50. if (buttons & IN_GRENADE2)
  51. Format(button_text, sizeof(buttons), "%sIN_GRENADE2|", button_text);
  52. if (buttons & IN_ATTACK3)
  53. Format(button_text, sizeof(buttons), "%sIN_ATTACK3", button_text);
  54. PrintToChatAll("%s: %s", message, button_text);
  55. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement