Plugin Cerut: Plugin cel
mai bun jucator la sfarsit de runda runda
Descriere (adica ce face el mai exact): Doresc un plugin cu cel mai bun jucator la sfarsit de runda si sa apara si in chat colorat
Ai cautat pluginul?(daca da, precizeaza cum): pe google dar nu este
Serverul impune conditii strict HLDS/REHLDS?: HLDS/REHLDS
Necesita mod special?: Nu
Versiune AMXX Server: 1.8.2 sau 1.8.3
[Cerere Plugin] Cel mai bun jucator
Moderators: Moderatori ajutatori, Moderatori, Echipa eXtreamCS.com
Forum rules
Accesează link-ul pentru a putea vedea regulile forumului
Daca doriti sa vi se modifice un plugin, va rugam postati aici .
Accesează link-ul pentru a putea vedea regulile forumului
Daca doriti sa vi se modifice un plugin, va rugam postati aici .
-
- Membru, skill 0
- Posts: 76
- Joined: 22 Feb 2019, 18:40
- Detinator Steam: Nu
- CS Status: Citesc forumul eXtreamCS.com...!
- Fond eXtream: 0
- Location: Harlau
- Contact:
- Mananc Drujbe
- Membru, skill 0
- Posts: 24
- Joined: 22 Dec 2022, 21:01
- Detinator Steam: Da
- CS Status: Average cs enjoyer
- Fond eXtream: 0
- Location: Romania, Vrancea
- Discord: szCristi#0105
- Been thanked: 1 time
-
- Membru, skill 0
- Posts: 12
- Joined: 11 Feb 2023, 14:34
- Detinator Steam: Nu
- CS Status: Citesc forumul eXtreamCS.com...!
- Fond eXtream: 0
Nu ti-ar placea sa arate un mesaj pe centrul ecaranului cu cel mai bun jucator al rundei?
ai aici sursa
ai aici sursa
Code: Select all
#include <amxmodx>
#include <amxmisc>
#include <hamsandwich>
#include <fakemeta>
enum _:score
{
frags,
Float:dmg,
hs
}
new niceP[33][score]
new hudsync
public plugin_init()
{
register_plugin( "best_gamer", "1.0", "Got Milk?")
RegisterHam(Ham_TakeDamage, "player", "hook_TakeDamage")
register_event("DeathMsg", "Event_DeathMessage", "a")
register_logevent("event_round_end", 2, "1=Round_End")
register_event("HLTV", "event_round_start", "a", "1=0", "2=0");
hudsync = CreateHudSyncObj()
}
public event_round_end ()
{
new Players[32], num, tmpf, Float:tmpd, tmpid
get_players( Players, num )
for( new i; i < 32; i++)
{
if ( niceP[i][frags] > tmpf )
{
tmpid = i
tmpf = niceP[i][frags]
tmpd = niceP[i][dmg]
}
else if ( niceP[i][frags] == tmpf && niceP[i][dmg] > tmpd)
{
tmpid = i
tmpf = niceP[i][frags]
tmpd = niceP[i][dmg]
}
}
if ( tmpf > 0 )
{
new name[32], msg[1024];
get_user_name(tmpid, name, 31);
format( msg, charsmax(msg), "The best shooter of this round was ^n!!! %s !!!^nHaving done %d kill(s) and %d damage", name, tmpf, floatround(tmpd, floatround_round) )
set_hudmessage(255, 0, 0, -1.0, 0.17, 0, 5.0)
ShowSyncHudMsg(0, hudsync, msg)
}
}
public hook_TakeDamage(Victim, inflictor, Attacker, Float:damage, damagebits)
{
if( inflictor == Attacker )
niceP[Attacker][dmg] += damage
else
{
static classname[32]
pev (inflictor, pev_classname, classname, 31)
if( equal (classname, "grenade") )
niceP[Attacker][dmg] += damage
}
if ( get_pdata_int(Victim, 75, 5) == HIT_HEAD )
niceP[Attacker][hs]++
return HAM_IGNORED
}
public Event_DeathMessage()
niceP[read_data(1)][frags]++
public event_round_start ( )
for (new i; i < 32; i++)
for ( new j; j < 3; j++)
niceP[i][j] = 0
public client_disconnect(id)
for ( new j; j < 3; j++)
niceP[id][j] = 0
-
- Membru, skill 0
- Posts: 76
- Joined: 22 Feb 2019, 18:40
- Detinator Steam: Nu
- CS Status: Citesc forumul eXtreamCS.com...!
- Fond eXtream: 0
- Location: Harlau
- Contact:
da este ok dar sa fie si cu cate hs a facut