hlmod.hu
https://hlmod.hu/

Szerver Info
https://hlmod.hu/viewtopic.php?f=9&t=5447
Oldal: 1 / 1

Szerző:  norbee.16 [2012.07.28. 12:30 ]
Hozzászólás témája:  Re: Szerver Info

Tessék itt egy hasonló kicsit át írod és olyasmi lesz :)
Link: http://amxmodx.crys.hu/site/?p=pluginz& ... erverinfos

Szerző:  CeDee [2012.07.29. 23:34 ]
Hozzászólás témája:  Re: Szerver Info

[spoiler]
Kód:
  1. #include <amxmodx>

  2. #include <amxmisc>

  3. #include <engine>

  4.  

  5.  

  6. #define PLUGIN "New Plug-In"

  7. #define VERSION "1.0"

  8. #define AUTHOR "N/A"

  9.  

  10. new const fejlec [ ] = "Jo Jatekot"; //Fejléc szövege

  11. new const serverslot [ ] = "14"; //Szervered Slot száma

  12. new const fb [ ] = "www.fb.com/cs1.6"; //Itt megadhatod a Skype, MSN, Weboldalad, Facebookod címét

  13.  

  14. new bool:admin_c[33]

  15.  

  16. new g_round = 1;

  17. new g_maxclients

  18. new g_admins

  19.  

  20.  

  21. public plugin_init() {

  22.         register_plugin(PLUGIN, VERSION, AUTHOR)

  23.         register_event("HLTV", "korok", "a", "1=0", "2=0");

  24.         set_task(1.0, "info", 0, "", 0, "b")

  25.         g_maxclients = get_maxplayers()

  26. }

  27.  

  28. public client_putinserver(id)

  29. {

  30.         if(get_user_flags(id) & ADMIN_KICK)

  31.         {

  32.                 admin_c[id] = true

  33.                 g_admins++

  34.         }

  35. }

  36.  

  37. public client_disconnect(id)

  38. {

  39.         if(admin_c[id])

  40.         {

  41.                 admin_c[id] = false

  42.                 g_admins--

  43.         }

  44. }

  45.  

  46. public korok() {

  47.         g_round++

  48. }

  49.  

  50. public  info(id)

  51. {

  52.         new ido[9]

  53.         new datum[64]

  54.         new ping,loss,id

  55.         new map [52]

  56.         new kovmap[32]

  57.         new playerek

  58.        

  59.        

  60.         get_time("%H:%M:%S",ido,8)

  61.         get_time("%d.%m.%Y", datum, 63)

  62.         get_mapname(map, 51)

  63.         get_cvar_string("amx_nextmap",kovmap,31)

  64.        

  65.         for(new i=1;i<=g_maxclients;i++)

  66.         {

  67.                 if(!is_user_connected(i) || is_user_bot(i))

  68.                        

  69.                 continue;

  70.                 get_user_ping(i,ping,loss)

  71.                

  72.                 playerek++     

  73.         }

  74.        

  75.         set_hudmessage(100, 100, 100, 0.0, 0.11 , 0, 6.0, 4.0)

  76.         show_hudmessage(id, "%s^n%s^n%s^nKor: %d^nJelenlegi palya: %s^nKovetkezo map: %s^nAdmins: %d^nJatekosok : %d/%s^nPing: %iping^n%s",fejlec,datum, ido,g_round,map,kovmap,g_admins,playerek,serverslot,ping,fb)

  77. }

  78.  
Teszteld...:D[/spoiler]

Szerző:  VirTuaL ~` [2012.07.30. 09:17 ]
Hozzászólás témája:  Re: Szerver Info

Offok törölve...

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