hlmod.hu
https://hlmod.hu/

Hud szerver infó
https://hlmod.hu/viewtopic.php?f=29&t=13798
Oldal: 1 / 1

Szerző:  AsD# [ 2014.01.14. 19:17 ]
Hozzászólás témája:  Hud szerver infó

Helló nekem egy olyan plugin kelene ami a radar alat ki írja a következőket:
Egy példa:
Idő: 13:35
Te Fregek: 24
Ct Fregek: 43
Kör: 20/40
Online Játékosok: 25/32

Melyik cvarral lehe álítani hogy hány körlegyen egy mappon? És hány kört ajánlasz.
Aki elkészíti annak megy a gomb!

Szerző:  CeDee [ 2014.01.15. 21:27 ]
Hozzászólás témája:  Re: Hud szerver infó

Teszteld
SMA Forráskód: [ Mindet kijelol ]
  1. #include <amxmodx>
  2. #include <amxmisc>
  3. #include <cstrike>
  4.  
  5. #define PLUGIN "HUD Info"
  6. #define VERSION "1.0"
  7. #define AUTHOR "N/A"
  8.  
  9. #define MAXROUNDS 40
  10.  
  11. new Rounds
  12.  
  13. new iCTKills
  14. new iTTKills
  15.  
  16. public plugin_init() {
  17. register_plugin(PLUGIN, VERSION, AUTHOR)
  18. register_event( "DeathMsg", "DeathEvent", "a" );
  19. register_event("TextMsg","ResetAll","a","2&#Game_C","2&#Game_w")
  20. register_logevent("NewRounds", 2, "0=World triggered", "1=Round_Start")
  21. set_task(1.0,"HUDInfo" , _ , _ , _ , "b")
  22. }
  23.  
  24. public ResetAll() {
  25. Rounds = 0
  26. iCTKills = 0
  27. iTTKills = 0
  28. }
  29.  
  30. public DeathEvent(){
  31. new Killer = read_data( 1 );
  32. new CsTeams:Team
  33. Team = cs_get_user_team( Killer );
  34. if (Team == CS_TEAM_T)
  35. {
  36. iTTKills++
  37. }
  38. if (Team == CS_TEAM_CT)
  39. {
  40. iCTKills++
  41. }
  42. }
  43.  
  44. public NewRounds(){
  45. Rounds++
  46. }
  47.  
  48. public HUDInfo(){
  49. new Time[9]
  50. get_time("%H:%M",Time,8)
  51.  
  52. new CurrentPlayers = get_playersnum();
  53. new MaxPlayers = get_maxplayers();
  54.  
  55. set_hudmessage(255, 255, 255, 0.0, 0.12, 0, 6.0, 1.0)
  56. show_hudmessage(0, "Idő: %s^nFrags of T: %d^nFrags of CT: %d^nKör: %d/%d^nJátékosok: %d/%d", Time, iTTKills, iCTKills, Rounds, MAXROUNDS, CurrentPlayers, MaxPlayers)
  57.  
  58. }

Szerző:  alfanero [ 2014.01.16. 05:12 ]
Hozzászólás témája:  Re: Hud szerver infó

Teszteltem Müködik(csak én még megcsináltam ékezetesre)! Köszi kelett nekem ilyen is megy a gomb

Oldal: 1 / 1 Minden időpont UTC+02:00 időzóna szerinti
Powered by phpBB® Forum Software © phpBB Limited
https://www.phpbb.com/