Raised This Month: $32 Target: $400
 8% 

Silent footsteps -> update CS:GO


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Qes
AlliedModders Donor
Join Date: Jul 2014
Old 07-07-2018 , 06:22   Silent footsteps -> update CS:GO
Reply With Quote #1

Hello,
Someone have fix for silent footsteps?
After update this code is not working

Code:
public Action:SoundHook(clients[64], &numClients, String:sample[PLATFORM_MAX_PATH], &entity, &channel, &Float:volume, &level, &pitch, &flags)
{
	if (0 < entity <= MaxClients)
	{
		if((StrContains(sample, "physics") != -1 || StrContains(sample, "footsteps") != -1) && StrContains(sample, "suit") == -1)
		{
			if(!silent_footsteps[entity])
			{
				numClients = 0;

				for(int i = 1; i <= MaxClients; i++)
				{
					if(IsClientInGame(i) && !IsFakeClient(i))
					{
						clients[numClients++] = i;
					}
				}

				EmitSound(clients, numClients, sample, entity);

			}
			return Plugin_Stop;
		}
	}


	return Plugin_Continue;
}
Qes is offline
rogeraabbccdd
Veteran Member
Join Date: Jun 2015
Location: de_dust2
Old 07-07-2018 , 07:11   Re: Silent footsteps -> update CS:GO
Reply With Quote #2

Update sourcemod to latest version.
__________________

Please keep in mind, nobody have responsibility to help you, especially who don't try to Google first.
I only read messages in Chinese and English.

GitHub | Discord:Kento#2118
rogeraabbccdd is offline
BulgarianPL
Member
Join Date: Dec 2013
Old 07-07-2018 , 20:45   Re: Silent footsteps -> update CS:GO
Reply With Quote #3

Same problem here. Im using last sourcemod and metamod update
BulgarianPL is offline
Kxnrl
AlliedModders Donor
Join Date: May 2015
Old 07-08-2018 , 06:59   Re: Silent footsteps -> update CS:GO
Reply With Quote #4

Try 1 frame delay.

Code:
public Action SoundHook(int clients[64], int &numClients, char sample[PLATFORM_MAX_PATH], int &client, int &channel, float &volume, int &level, int &pitch, int &flags)
{
    if(0 < entity <= MaxClients)
    {
        if((StrContains(sample, "physics") != -1 || StrContains(sample, "footsteps") != -1) && StrContains(sample, "suit") == -1)
        {
            if(!silent_footsteps[entity])
            {
                DataPack pack = new DataPack();
                pack.WriteCell(entity);
                pack.WriteString(sample);
                pack.Reset();
                RequestFrame(FuckValveDelay, pack);
            }
            return Plugin_Stop;
        }
    }

    return Plugin_Continue;
}

void FuckValveDelay(DataPack pack)
{
    int entity = pack.ReadCell();

    char sample[PLATFORM_MAX_PATH];
    pack.ReadString(sample, PLATFORM_MAX_PATH);

    delete pack;

    if(!IsValidEntity(entity))
        return;

    int numClients = 0;
    int clients[64];

    for(int i = 1; i <= MaxClients; i++)
    {
        if(IsClientInGame(i) && !IsFakeClient(i))
        {
            clients[numClients++] = i;
        }
    }

    EmitSound(clients, numClients, sample, entity);
}
__________________
Kxnrl is offline
BulgarianPL
Member
Join Date: Dec 2013
Old 07-08-2018 , 07:41   Re: Silent footsteps -> update CS:GO
Reply With Quote #5

Code:
#include <cstrike>
#include <sourcemod>
#include <sdkhooks>
#include <sdktools>
#include <codmod>

new const String:nazwa[] = "Lekki Zolnierz";
new const String:opis[] = "Nie slychac twoich kroków";
new const String:bronie[] = "#weapon_galilar#weapon_p250#weapon_flashbang#weapon_flashbang";
new const inteligencja = 0;
new const zdrowie = 15;
new const obrazenia = 0;
new const wytrzymalosc = 0;
new const kondycja = 0;

new bool:ma_klase[65];

public OnPluginStart()
{
	cod_register_class(nazwa, opis, bronie, inteligencja, zdrowie, obrazenia, wytrzymalosc, kondycja);
	AddNormalSoundHook(DzwiekiGracza);
}

public OnClientPutInServer(client)
{
	if(!IsFakeClient(client))
		SendConVarValue(client, FindConVar("sv_footsteps"), "0");
}

public cod_class_enabled(client)
{
	ma_klase[client] = true;
}

public cod_class_disabled(client)
{
	ma_klase[client] = false;
}

public Action:DzwiekiGracza(clients[64], &numclients, String:sample[PLATFORM_MAX_PATH], &entity, &channel, &Float:volume, &level, &pitch, &flags)
{
	if(!IsValidClient(entity) || IsFakeClient(entity))
		return Plugin_Continue;

	if((StrContains(sample, "physics") != -1 || StrContains(sample, "footsteps") != -1) && StrContains(sample, "suit") == -1)
	{
		if(!ma_klase[entity])
			EmitSoundToAll(sample, entity);

		return Plugin_Handled;
	}

	return Plugin_Continue;
}
Im using this and its not workin since last update.
BulgarianPL 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 05:01.


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