Raised This Month: $68 Target: $400
 17% 

[CSGO] Info after death


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
trzmielu
Member
Join Date: Aug 2016
Old 08-16-2017 , 08:39   [CSGO] Info after death
Reply With Quote #1

Hello,

Is possible to make a plugin that will work like this: After player die, he'll have 10 seconds to tell info and after this time, player will can only talk to dead players (LIKE IN ESEA)

Hope you understand me, haha

Regards

Last edited by trzmielu; 08-16-2017 at 08:39. Reason: +=-=+
trzmielu is offline
alexr153
AlliedModders Donor
Join Date: Jul 2015
Location: In a house
Old 08-16-2017 , 12:10   Re: [CSGO] Info after death
Reply With Quote #2

Quote:
Originally Posted by trzmielu View Post
Hello,

Is possible to make a plugin that will work like this: After player die, he'll have 10 seconds to tell info and after this time, player will can only talk to dead players (LIKE IN ESEA)

Hope you understand me, haha

Regards
I will make this when I get home.
alexr153 is offline
Wacci
AlliedModders Donor
Join Date: May 2017
Location: Hungary
Old 08-16-2017 , 12:35   Re: [CSGO] Info after death
Reply With Quote #3

It's a very good idea!
Wacci is offline
alexr153
AlliedModders Donor
Join Date: Jul 2015
Location: In a house
Old 08-16-2017 , 15:04   Re: [CSGO] Info after death
Reply With Quote #4

I havenít got a chance to test it but here

PHP Code:
#include <sourcemod>
#include <sdktools>

#pragma semicolon 1
#pragma newdecls required

ConVar vc_enable;
ConVar vc_time;

public 
Plugin myinfo = {
    
name        "[Voice controller] Mute dead players time",
    
author      "hAlexr",
    
description "Adds so when player dieswill set a timer to mute him/herself from alive players",
    
version     "1.0.0",
    
url         "www.crypto-gaming.tk"
};

public 
void OnPluginStart()
{
    
vc_enable CreateConVar("vc_enable""1""Enables or disables the plugin"_true0.0true1.0);
    
vc_time CreateConVar("vc_time""10.0""Time until player is muted"_true0.1true20.0);
    
AutoExecConfig(true"plugin.MuteDeadPlayers");
    
    
HookEvent("player_death"playerDeath);
    
HookEvent("round_end"roundEnd);
}

public 
Action playerDeath(Event event, const char[] namebool dontBroadcast)
{
    if(!
GetConVarBool(vc_enable))
    return;
    
    
int client GetClientOfUserId(GetEventInt(event"userid"));
    
    
CreateTimer(GetConVarFloat(vc_time), muteTimerclient);
}

public 
Action muteTimer(Handle timerint client)
{
    if(!
GetConVarBool(vc_enable))
    return;
    
    for(
int i 1i<=MaxClients;i++)
    {
        if(
IsClientConnected(client) && IsClientInGame(client) && != client && !IsPlayerAlive(client))
        {
            
int clientTeam GetClientTeam(client);
            
            if(
IsClientConnected(i) && IsClientInGame(i) && != client && IsPlayerAlive(i))
             {
                 
int iTeam GetClientTeam(i);
                 
                 if(
clientTeam == iTeam)
                 {
                     
SetListenOverride(iclientListen_No);
                 }
             }
        }
    }
}

public 
Action roundEnd(Event event, const char[] namebool dontBroadcast)
{
    for(
int i 1<= MaxClientsi++)
    {
        if(
IsClientConnected(i) && IsClientInGame(i) && IsPlayerAlive(i))
         {
             
int clientTeam GetClientTeam(i);
             
unmuteClients(iclientTeam);
         }
    }
}

public 
void unmuteClients(int clientint clientTeam)
{
    for(
int i 1<= MaxClientsi++)
    {
        if(
IsClientConnected(i) && IsClientInGame(i) && IsPlayerAlive(i))
         {
             
int iTeam GetClientTeam(client);
             if(
iTeam == clientTeam)
             {
                 
SetListenOverride(iclientListen_Yes);
                 
SetListenOverride(clientiListen_Yes);
             }
         }
    }

alexr153 is offline
Wacci
AlliedModders Donor
Join Date: May 2017
Location: Hungary
Old 08-16-2017 , 18:30   Re: [CSGO] Info after death
Reply With Quote #5

Can you create message for dead., You can speak with dead..
Maybe with language file.
Wacci is offline
alexr153
AlliedModders Donor
Join Date: Jul 2015
Location: In a house
Old 08-16-2017 , 20:15   Re: [CSGO] Info after death
Reply With Quote #6

Quote:
Originally Posted by Wacci View Post
Can you create message for dead., You can speak with dead..
Maybe with language file.
Will be added. Also did the plugin work?
alexr153 is offline
Wacci
AlliedModders Donor
Join Date: May 2017
Location: Hungary
Old 08-17-2017 , 14:29   Re: [CSGO] Info after death
Reply With Quote #7

Players with flag hearing enemy flagged players in alive too.

But I will testing at night to perfect report.

Last edited by Wacci; 08-17-2017 at 14:40.
Wacci is offline
alexr153
AlliedModders Donor
Join Date: Jul 2015
Location: In a house
Old 08-17-2017 , 20:36   Re: [CSGO] Info after death
Reply With Quote #8

Quote:
Originally Posted by Wacci View Post
Players with flag hearing enemy flagged players in alive too.

But I will testing at night to perfect report.
Sorry, but I don't get what you're trying to say here. (Red text)
alexr153 is offline
waylander3
Senior Member
Join Date: Sep 2015
Location: Russia, Norilsk
Old 08-18-2017 , 03:31   Re: [CSGO] Info after death
Reply With Quote #9

I looking for this plugin too
Will test at night.
Also will be better with chat message, when dead player can't talk with alive, plugin may say "[Dead info] Now you cant talk with alive players"
waylander3 is offline
alexr153
AlliedModders Donor
Join Date: Jul 2015
Location: In a house
Old 08-18-2017 , 11:47   Re: [CSGO] Info after death
Reply With Quote #10

Ye I will do that just haven’t had the time to do this yet.
alexr153 is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 20:05.


Powered by vBulletin®
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Theme made by Freecode