hlmod.hu
https://hlmod.hu/

Frag
https://hlmod.hu/viewtopic.php?f=10&t=9805
Oldal: 1 / 1

Szerző:  Gatshow [ 2013.08.01. 16:38 ]
Hozzászólás témája:  Frag

2 dolgot szeretnék kérdezni

1. hogyan tudom lekérni a játékos eddigi összes fragjét?
2. hogyan tudom lekérni a játékos eddigi összes fragjét amit szerzett a mapon (maponként nullázódik és ha nulázza a statját akkor megmarad a lekérésben)

előre is köszi :D

Szerző:  Vinnice [ 2013.08.01. 18:57 ]
Hozzászólás témája:  Re: Frag

/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <amxmisc>
#include <csstats>
#include <fun>

#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "author"

new g_olesek[33]

public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)

register_clcmd("say /osszes_oles","oles")
register_clcmd("say /mapolesek","mpoles")
register_event("DeathMsg","DeathMsg","a")

}
// 1.
public oles(id)
{
static stats[8],body[8]
get_user_stats(id, stats, body);

client_print(id, print_chat,"Osszes Olesed: %i",stats[0])
}
//2.
public mpoles(id)
{
client_print(id, print_chat, "Osszesen a Mapon : %i-t oltel.",g_olesek)
}

public client_connect(id) g_olesek[id] = 0;

public DeathMsg()
{
new killer = read_data(1)

g_olesek[killer]++
}

Szerző:  Gatshow [ 2013.08.01. 18:59 ]
Hozzászólás témája:  Re: Frag

Vinnice írta:
SMA Forráskód: [ Mindet kijelol ]
  1. /* Plugin generated by AMXX-Studio */
  2.  
  3. #include <amxmodx>
  4. #include <amxmisc>
  5. #include <csstats>
  6. #include <fun>
  7.  
  8. #define PLUGIN "New Plug-In"
  9. #define VERSION "1.0"
  10. #define AUTHOR "author"
  11.  
  12. new g_olesek[33]
  13.  
  14. public plugin_init() {
  15. register_plugin(PLUGIN, VERSION, AUTHOR)
  16.  
  17. register_clcmd("say /osszes_oles","oles")
  18. register_clcmd("say /mapolesek","mpoles")
  19. register_event("DeathMsg","DeathMsg","a")
  20.  
  21. }
  22. // 1.
  23. public oles(id)
  24. {
  25. static stats[8],body[8]
  26. get_user_stats(id, stats, body);
  27.  
  28. client_print(id, print_chat,"Osszes Olesed: %i",stats[0])
  29. }
  30. //2.
  31. public mpoles(id)
  32. {
  33. client_print(id, print_chat, "Osszesen a Mapon : %i-t oltel.",g_olesek)
  34. }
  35.  
  36. public client_connect(id) g_olesek[id] = 0;
  37.  
  38. public DeathMsg()
  39. {
  40. new killer = read_data(1)
  41.  
  42. g_olesek[killer]++
  43. }


Tesztelni kell vagy biztos jó??
[off]sma-ba rakhattad volna[/off]

Szerző:  Vinnice [ 2013.08.01. 19:02 ]
Hozzászólás témája:  Re: Frag

Tesztelni kell.
[off] Elb.-tam, bocs nem lehet szerkeszteni. [/off]

Szerző:  Gatshow [ 2013.08.01. 19:12 ]
Hozzászólás témája:  Re: Frag

Vinnice írta:
Tesztelni kell.


oké

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