Advertisement
Guest User

Untitled

a guest
Feb 25th, 2020
255
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.06 KB | None | 0 0
  1. if (NETWORK::NETWORK_IS_SESSION_STARTED())
  2. {
  3. for (int z = 0; z < 32; ++z)
  4. {
  5. if (NETWORK::NETWORK_IS_PLAYER_CONNECTED(z))
  6. {
  7. if (ENTITY::DOES_ENTITY_EXIST(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(z)))
  8. {
  9.  
  10. int index = 1385296; /////STANDART GLOBAL + 2
  11. char* headShot;
  12.  
  13. const char* playerTag;
  14. for (int x = 0; x <= 150; x += 5)
  15. {
  16. int playerId = globalHandle(index).At(x).As<int>();
  17.  
  18. if (playerId == z) {
  19. int logo = globalHandle(index).At(x).At(1).As<int>();
  20. headShot = PED::GET_PEDHEADSHOT_TXD_STRING(logo);
  21.  
  22. if (PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(z) == PLAYER::PLAYER_PED_ID())
  23. {
  24. char* PlayerName = PLAYER::GET_PLAYER_NAME(z);
  25. char Buffer[255];
  26. sprintf(Buffer, "%s ~HUD_COLOUR_GOLD~[~HUD_COLOUR_GOLD~Me~HUD_COLOUR_GOLD~]", PlayerName);
  27. PlayerName = Buffer;
  28.  
  29. Menu::MenuPlayer(PlayerName, headShot, playermenu, z) ? selectedPlayer = z : NULL;
  30. }
  31. else if (PLAYER::GET_PLAYER_INVINCIBLE(z))
  32. {
  33. char* PlayerName = PLAYER::GET_PLAYER_NAME(z);
  34. char Buffer[255];
  35. sprintf(Buffer, "%s ~r~[God]", PlayerName);
  36. PlayerName = Buffer;
  37. Menu::MenuPlayer(PlayerName, headShot, playermenu, z) ? selectedPlayer = z : NULL;
  38. }
  39. else if (PLAYER::GET_PLAYER_WANTED_LEVEL(z))
  40. {
  41. char* PlayerName = PLAYER::GET_PLAYER_NAME(z);
  42. char Buffer[255];
  43. sprintf(Buffer, "%s ~r~[Wanted]", PlayerName);
  44. PlayerName = Buffer;
  45. Menu::MenuPlayer(PlayerName, headShot, playermenu, z) ? selectedPlayer = z : NULL;
  46. }
  47. else {
  48. playerTag = PLAYER::GET_PLAYER_NAME(z);
  49. }
  50. Menu::MenuPlayer(playerTag, headShot, playermenu, z) ? selectedPlayer = z : NULL;
  51. }
  52. }
  53. }
  54.  
  55. }
  56. }
  57.  
  58. }
  59. else {
  60. for (int z = 0; z < 32; ++z) {
  61.  
  62. Menu::MenuPlayer(PLAYER::GET_PLAYER_NAME(z), "CHAR_MULTIPLAYER", playermenu, z) ? selectedPlayer = z : NULL;
  63. break;
  64. }
  65. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement