HLMOD.HU Forrás Megtekintés - www.hlmod.hu
  1. #include <amxmodx>
  2. #include <fakemeta>
  3. #include <orpheu>
  4.  
  5. #define PLUGIN "Go home hackers!"
  6. #define VERSION "1.0"
  7. #define AUTHOR "WiggPerson, vlad"
  8.  
  9. new id, i;
  10. new ip[25], hostname[64];
  11. new final[128];
  12. new g_maxplayers;
  13.  
  14. public plugin_init() {
  15. register_plugin(PLUGIN,VERSION,AUTHOR);
  16. OrpheuRegisterHook(OrpheuGetFunction("Host_Status_f"), "onStatus", OrpheuHookPre);
  17.  
  18. get_user_ip(0, ip, 24, 0); // Ziska ip server
  19. get_cvar_string("hostname", hostname, 63); // Ziska meno servera
  20. new p_playernum;
  21. p_playernum = get_playersnum(1);
  22. g_maxplayers = get_maxplayers();
  23.  
  24. formatex(final, 127, "%s (%s)", hostname, ip );
  25. }
  26.  
  27. public OrpheuHookReturn:onStatus() {
  28. id = engfunc(EngFunc_GetCurrentPlayer) + 1;
  29.  
  30.  
  31. console_print(id, "Szerver: ^n%s^n-------------------^nJatekos informaciok:", final)
  32. for(i = 0; i < 32; i++) {
  33. if(is_user_connected(i)) {
  34. static name[33];
  35. get_user_name(i, name, 32);
  36. new steamid[33];
  37. get_user_authid(id, steamid, 32);
  38. console_print(id, "#%d Nev: %s SteamID: %s",get_user_userid(i), name, steamid);
  39.  
  40. }
  41. }
  42.  
  43. //console_print(id, "Z bezbecnostnich dovodov tento prikaz bol upraveny.");
  44.  
  45. return OrpheuSupercede;
  46. }
  47.