AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Suggestions / Requests (https://forums.alliedmods.net/forumdisplay.php?f=12)
-   -   Solved Enemies Left (https://forums.alliedmods.net/showthread.php?t=313198)

Alber9091 12-31-2018 07:20

Enemies Left
 
What's the name of this plugin?

10 Terrorists Left
09 Terrorists Left

08 Counter-Terrorists Left
07 Counter-Terrorists Left

Shown Only, When someone Kill !!

If it don't exist can anyone make it? [Enemies Left]

raizo11 12-31-2018 08:28

Re: What's the name of this Plugin?
 
Code:

#include <amxmodx>
#include <hamsandwich>
#include <dhudmessage>

public plugin_init()
{
    RegisterHam(Ham_Killed, "player", "PlayerKilled", 1)
}

public PlayerKilled(id)
{
    static X[32], Y[32], XNum, YNum
    get_players(X, XNum, "ae", "TERRORIST")
    get_players(Y, YNum, "ae", "CT")

    set_dhudmessage(110, 55, 110, -1.0, 0.70, 1, 0.1, 3.0, 0.1, 2.0, false)
    show_dhudmessage(0, "TERO %d  -  CT %d!", XNum, YNum)
}


E1_531G 12-31-2018 10:36

Re: What's the name of this Plugin?
 
miscstats.amxx does this.

Alber9091 12-31-2018 10:53

Re: What's the name of this Plugin?
 
Hy Thanks Alot !!!

But can you fix this? If there are Multiple Kills and Message is not disappeared. It overrides, can't it replace the number instead of changing with Override? And color bit darker? (Just bit darker not much, so noticeable)[Because in Maps like DD2, where there is part of sun shade in map, it becomes less visible !!!]

https://i.ibb.co/r77GGYS/de-dust20004.png

Alber9091 12-31-2018 13:16

Re: What's the name of this Plugin?
 
Quote:

Originally Posted by E1_531G (Post 2632016)
miscstats.amxx does this.

Thanks :D

E1_531G 01-01-2019 15:30

Re: What's the name of this Plugin?
 
Quote:

Originally Posted by Alber9091 (Post 2632022)
Hy Thanks Alot !!!

But can you fix this? If there are Multiple Kills and Message is not disappeared. It overrides, can't it replace the number instead of changing with Override? And color bit darker? (Just bit darker not much, so noticeable)[Because in Maps like DD2, where there is part of sun shade in map, it becomes less visible !!!]

https://i.ibb.co/r77GGYS/de-dust20004.png

This happens because of auto-channel option at show_hudmessage() function.
Every new message takes new channel, as result we see this overriding.
If you know how, change above mentioned function to use one static channel.

OciXCrom 01-01-2019 18:22

Re: What's the name of this Plugin?
 
Quote:

Originally Posted by E1_531G (Post 2632252)
This happens because of auto-channel option at show_hudmessage() function.
Every new message takes new channel, as result we see this overriding.
If you know how, change above mentioned function to use one static channel.

Use a hud sync object.

Alber9091 01-02-2019 10:25

Re: What's the name of this Plugin?
 
Quote:

Originally Posted by OciXCrom (Post 2632280)
Use a hud sync object.

Some What This? :D
Thanks To eat1k A.K.A w0w

ReAPI + AMXX 1.9.0 + HUD instead of DHUD

PHP Code:

/*
* Author: https://t.me/twisternick
* Request: https://dev-cs.ru/threads/4792/
*/

#include <amxmodx>
#include <amxmisc>
#include <reapi>

#pragma semicolon 1

#define PLUGIN_VERSION "1.0"

/****************************************************************************************
****************************************************************************************/

new g_iSyncMessage;

public 
plugin_init()
{
    
register_plugin("Enemies Left"PLUGIN_VERSION"w0w");

    
RegisterHookChain(RG_CBasePlayer_Killed"refwd_PlayerKilled_Post"true);
    
g_iSyncMessage CreateHudSyncObj();
}

public 
refwd_PlayerKilled_Post()
{
    new 
iTs get_playersnum_ex(GetPlayers_ExcludeDead|GetPlayers_MatchTeam"TERRORIST");
    new 
iCTs get_playersnum_ex(GetPlayers_ExcludeDead|GetPlayers_MatchTeam"CT");

    
set_hudmessage(11055110, -1.00.7010.13.00.12.0, -1);
    
ShowSyncHudMsg(0g_iSyncMessage"Terrorists %d - %d Counter-Terrorists"iTsiCTs);




All times are GMT -4. The time now is 00:49.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.