IcePack

Slient Day

14 posts in this topic

Giving credit to MrBam about thinking about new day ideas, Silent day is  you can not use your mic or type in chat. If you do you are Kos. If you see the little  🔈  Plus there name, once you see them they will be KOS. It makes the game hard and there is no Blood hound. There is no working together (Unless on TS) This could be a good advantage for CT's on a free-day although T's already have a lot of advantages. During the Silent day you can't tell your friend to come with you or tell them where you are or "I have armory open!" [Haven't decided yet but should CT's not be allowed to talk to if they do talk they slay themselves? Might make it more fair post replies if you like idea but more special days they better experience and more fun!]

Thanks

-IcePack

0

Share this post


Link to post
Share on other sites

+rep 

this stop the mic spamming for 1 round good idea if you ask me

0

Share this post


Link to post
Share on other sites

+rep my only problem itd be hard for ppl to be like wait hey idk what im doing or can u help me

0

Share this post


Link to post
Share on other sites

Would you still be able to use team chat, or is ALL working together prohibited? And if so, how do you tell if the Ts' are working together?

I do like new ideas for fun, or different event days.

0

Share this post


Link to post
Share on other sites
46 minutes ago, MarthaTheWatermelon said:

Would you still be able to use team chat, or is ALL working together prohibited? And if so, how do you tell if the Ts' are working together?

I do like new ideas for fun, or different event days.

Well I guess T's can type in team chat yet if you see them stop then its kind of a "hint" but theres always, ways around

0

Share this post


Link to post
Share on other sites

If there is someway to add where  T's literally cant type somehow like a plugin or something or if they are typing in chat it tells the CT's and then we can kos them

1

Share this post


Link to post
Share on other sites

Posted (edited)

I'm bored so I made a plugin for this.

 

#pragma semicolon 1

#define DEBUG

#include <sourcemod>
#include <cstrike>
#include <sdktools>

bool IsSilentDay;
char g_PlayerName[MAX_NAME_LENGTH];

public Plugin myinfo =
{
	name = "Phire's Silentday",
	author = "Phire",
	description = "Allows the use of the custom day silentday.",
	version = "1.0.0",
	url = "Sulphox.com"
};

public void OnPluginStart()
{
	RegAdminCmd("sm_silentday", Phire_SilentDay, ADMFLAG_GENERIC, "Enable the silent day.");
	
	AddCommandListener(Phire_HookSay, "say");
	AddCommandListener(Phire_HookSayTeam, "say_team");
}

public void OnRoundStart(int client)
{
	IsSilentDay = false;
}

public Action Phire_SilentDay(int client, int args)
{
	GetClientName(client, g_PlayerName, sizeof(g_PlayerName));
	
	if (IsSilentDay == true)
	{
		PrintToChat(client, "[SM] You \x07disabled\x01 silent day.");
		PrintToChatAll("[SM] %s has disabled silent day, prisoners can now use chat.", g_PlayerName);
		IsSilentDay = false;
        return Plugin_Handled;
	}
	else if (IsSilentDay == false)
	{
		PrintToChat(client, "[SM] You \x04enabled\x01 silent day.");
		PrintToChatAll("[SM] %s has enabled silent day, any prisoners that type are now KOS.", g_PlayerName);
		IsSilentDay = true;
        return Plugin_Handled;
	}
  
    return Plugin_Handled;
}

public Action Phire_HookSay(int client, const char[] command, int argc)
{
	GetClientName(client, g_PlayerName, sizeof(g_PlayerName));

	if (GetClientTeam(client) == CS_TEAM_T)
	{
		if (IsSilentDay)
		{
			if (!IsChatTrigger())
			{
				PrintToChatAll("[ALERT] %s has used chat on a silent day!", g_PlayerName);
				PrintToChat(client, "[SM] You are now KOS because you used chat on a silent day.");
				return Plugin_Handled;
			}
		}
	}
	
	return Plugin_Handled;
}


public Action Phire_HookSayTeam(int client, const char[] command, int argc)
{
	GetClientName(client, g_PlayerName, sizeof(g_PlayerName));

	if (GetClientTeam(client) == CS_TEAM_T)
	{
		if (IsSilentDay)
		{
			if (!IsChatTrigger())
			{
				PrintToChatAll("[ALERT] %s has used team chat on a silent day! They are KOS.", g_PlayerName);
				PrintToChat(client, "[SM] You are now KOS because you used team chat on a silent day.");
				return Plugin_Handled;
			}
		}
	}
	
	return Plugin_Handled;
}

This can be toggled with the command sm_silentday (!silentday or /silentday) and can be toggled by staff members with the Sourcemod flag A (Generic)

 

Players can use chat commands like !slay phire and they will not be made KOS for that.

 

It will automatically be removed when the round starts.

Edited by Phire
1

Share this post


Link to post
Share on other sites

Posted (edited)

If you guys want I can update it so that it warns a person first which would be good for new players like first they would type and get a warning not to do it and if they type again then they become KOS. Obviously you guys don't need to use this, just that I like making plugins :)

 

IF you are going to use it, don't use the version up there I'm making a better one

 

New version:

 

#pragma semicolon 1

#define DEBUG

#include <sourcemod>
#include <cstrike>
#include <sdktools>

bool IsSilentDay;
int g_Warnings[MAX_NAME_LENGTH+1] = 0;
int g_MessagesSent[MAX_NAME_LENGTH+1] = 0;
char g_PlayerName[MAX_NAME_LENGTH];
ConVar g_UseWarningSys;

#define EMPTY_MESSAGE 0

public Plugin myinfo =
{
	name = "Phire's Silentday",
	author = "Phire",
	description = "Allows the use of the custom day silentday.",
	version = "1.0.0",
	url = "Sulphox.com"
};

public void OnPluginStart()
{
	RegAdminCmd("sm_silentday", Phire_SilentDay, ADMFLAG_GENERIC, "Enable the silent day.");
	
	g_UseWarningSys = CreateConVar("phire_sd_warnings", "1", "Sets whether you want to use warnings or not.", _, true, 0.1, true, 1.0);
	
	AddCommandListener(Phire_HookSay, "say");
	AddCommandListener(Phire_HookSay, "say_team");
}

public void OnRoundStart(int client)
{
	IsSilentDay = false;
	g_Warnings[client] = 0;
	g_MessagesSent[client] = 0;
}

public Action Phire_SilentDay(int client, int args)
{
	GetClientName(client, g_PlayerName, sizeof(g_PlayerName));
	
	if (IsSilentDay == true)
	{
		PrintToChat(client, "[SM] You \x07disabled\x01 silent day.");
		PrintToChatAll("[SM] %s has disabled silent day, prisoners can now use chat.", g_PlayerName);
		IsSilentDay = false;
	}
	else if (IsSilentDay == false)
	{
		PrintToChat(client, "[SM] You \x04enabled\x01 silent day.");
		PrintToChatAll("[SM] %s has enabled silent day, any prisoners that type are now KOS.", g_PlayerName);
		IsSilentDay = true;
	}
}

public Action Phire_HookSay(int client, const char[] command, int argc)
{
	GetClientName(client, g_PlayerName, sizeof(g_PlayerName));
	
	char Chat[256]; 
	GetCmdArgString(Chat, sizeof(Chat));
	StripQuotes(Chat);
	
	if ((Chat[1] == EMPTY_MESSAGE) || (Chat[0] == EMPTY_MESSAGE))
	{
		return Plugin_Handled;
	}

	if (IsPlayerAlive(client))
	{
		if (GetClientTeam(client) == CS_TEAM_T)
		{
			if (IsSilentDay)
			{
				if (!IsChatTrigger())
				{
					if (GetConVarInt(g_UseWarningSys) == 1)
					{
						if (g_Warnings[client] == 0)
						{
							PrintToChat(client, "\x01[\x07ALERT\x01] Psst.. It's a \x07silent\x01 day, \x07don't\x01 use \x10chat\x01!");
							PrintToChat(client, "\x01[\x07ALERT\x01] You will be \x07KOS\x01 if you do it again!");
							g_Warnings[client] = 1;
							return Plugin_Handled;
						}
					
						else if (g_Warnings[client] >= 1)
						{
							if (g_MessagesSent[client] == 0)
							{
								PrintToChatAll("\x01[\x07ALERT\x01] \x10%s\x01 has used chat on a silent day! They are \x07KOS.", g_PlayerName);
								PrintToChat(client, "\x01[\x07ALERT\x01] You are now \x07KOS\x01 because you used chat on a silent day.");
								g_MessagesSent[client] = 1;
								return Plugin_Handled;
							}
							else
							{
								PrintToChat(client, "\x01[\x07ALERT\x01] You are now KOS because you used chat on a silent day.");
								return Plugin_Handled;
							}
						}	
					}
					else
					{
						if (g_MessagesSent[client] == 0)
						{
							PrintToChatAll("\x01[\x07ALERT\x01] \x10%s\x01 has used chat on a silent day! They are \x07KOS.", g_PlayerName);
							PrintToChat(client, "\x01[\x07ALERT\x01] You are now \x07KOS\x01 because you used chat on a silent day.");
							g_MessagesSent[client] = 1;
							return Plugin_Handled;
						}
						else
						{
							PrintToChat(client, "\x01[\x07ALERT\x01] You are now \x07KOS\x01 because you used chat on a silent day.");
							return Plugin_Handled;
						}
					}
				}
			}
		}
	}
	
	return Plugin_Handled;
}

 

Information:

 

Silent day can be toggled with the command sm_silentday (!silentday or /silentday)

The warning system can be toggled via the Cvar "phire_sd_warnings", default enabled, disable by setting it to 0 in the server.cfg

Cvar settings: 1 for enabled, 0 for disabled.

 

By default the command (sm_silentday) is set to ADMFLAG_GENERIC which is flag b (not a like I said above)

 

Reply if you have any questions, if you decide to use this then thanks :)

 

There is only one bug, sending messages that only contain one character will not be counted. Of course you could remove my name from the plugin but I'd really appreciate it if you would keep it there. If you don't know how to compile it then copy and paste the code to https://www.sourcemod.net/compiler.php

Edited by Phire
0

Share this post


Link to post
Share on other sites
1 hour ago, Phire said:

If you guys want I can update it so that it warns a person first which would be good for new players like first they would type and get a warning not to do it and if they type again then they become KOS. Obviously you guys don't need to use this, just that I like making plugins :)

 

IF you are going to use it, don't use the version up there I'm making a better one

 

New version:

 


#pragma semicolon 1

#define DEBUG

#include <sourcemod>
#include <cstrike>
#include <sdktools>

bool IsSilentDay;
int g_Warnings[MAX_NAME_LENGTH+1] = 0;
int g_MessagesSent[MAX_NAME_LENGTH+1] = 0;
char g_PlayerName[MAX_NAME_LENGTH];
ConVar g_UseWarningSys;

#define EMPTY_MESSAGE 0

public Plugin myinfo =
{
	name = "Phire's Silentday",
	author = "Phire",
	description = "Allows the use of the custom day silentday.",
	version = "1.0.0",
	url = "Sulphox.com"
};

public void OnPluginStart()
{
	RegAdminCmd("sm_silentday", Phire_SilentDay, ADMFLAG_GENERIC, "Enable the silent day.");
	
	g_UseWarningSys = CreateConVar("phire_sd_warnings", "1", "Sets whether you want to use warnings or not.", _, true, 0.1, true, 1.0);
	
	AddCommandListener(Phire_HookSay, "say");
	AddCommandListener(Phire_HookSay, "say_team");
}

public void OnRoundStart(int client)
{
	IsSilentDay = false;
	g_Warnings[client] = 0;
	g_MessagesSent[client] = 0;
}

public Action Phire_SilentDay(int client, int args)
{
	GetClientName(client, g_PlayerName, sizeof(g_PlayerName));
	
	if (IsSilentDay == true)
	{
		PrintToChat(client, "[SM] You \x07disabled\x01 silent day.");
		PrintToChatAll("[SM] %s has disabled silent day, prisoners can now use chat.", g_PlayerName);
		IsSilentDay = false;
	}
	else if (IsSilentDay == false)
	{
		PrintToChat(client, "[SM] You \x04enabled\x01 silent day.");
		PrintToChatAll("[SM] %s has enabled silent day, any prisoners that type are now KOS.", g_PlayerName);
		IsSilentDay = true;
	}
}

public Action Phire_HookSay(int client, const char[] command, int argc)
{
	GetClientName(client, g_PlayerName, sizeof(g_PlayerName));
	
	char Chat[256]; 
	GetCmdArgString(Chat, sizeof(Chat));
	StripQuotes(Chat);
	
	if ((Chat[1] == EMPTY_MESSAGE) || (Chat[0] == EMPTY_MESSAGE))
	{
		return Plugin_Handled;
	}

	if (IsPlayerAlive(client))
	{
		if (GetClientTeam(client) == CS_TEAM_T)
		{
			if (IsSilentDay)
			{
				if (!IsChatTrigger())
				{
					if (GetConVarInt(g_UseWarningSys) == 1)
					{
						if (g_Warnings[client] == 0)
						{
							PrintToChat(client, "\x01[\x07ALERT\x01] Psst.. It's a \x07silent\x01 day, \x07don't\x01 use \x10chat\x01!");
							PrintToChat(client, "\x01[\x07ALERT\x01] You will be \x07KOS\x01 if you do it again!");
							g_Warnings[client] = 1;
							return Plugin_Handled;
						}
					
						else if (g_Warnings[client] >= 1)
						{
							if (g_MessagesSent[client] == 0)
							{
								PrintToChatAll("\x01[\x07ALERT\x01] \x10%s\x01 has used chat on a silent day! They are \x07KOS.", g_PlayerName);
								PrintToChat(client, "\x01[\x07ALERT\x01] You are now \x07KOS\x01 because you used chat on a silent day.");
								g_MessagesSent[client] = 1;
								return Plugin_Handled;
							}
							else
							{
								PrintToChat(client, "\x01[\x07ALERT\x01] You are now KOS because you used chat on a silent day.");
								return Plugin_Handled;
							}
						}	
					}
					else
					{
						if (g_MessagesSent[client] == 0)
						{
							PrintToChatAll("\x01[\x07ALERT\x01] \x10%s\x01 has used chat on a silent day! They are \x07KOS.", g_PlayerName);
							PrintToChat(client, "\x01[\x07ALERT\x01] You are now \x07KOS\x01 because you used chat on a silent day.");
							g_MessagesSent[client] = 1;
							return Plugin_Handled;
						}
						else
						{
							PrintToChat(client, "\x01[\x07ALERT\x01] You are now \x07KOS\x01 because you used chat on a silent day.");
							return Plugin_Handled;
						}
					}
				}
			}
		}
	}
	
	return Plugin_Handled;
}

 

Information:

 

Silent day can be toggled with the command sm_silentday (!silentday or /silentday)

The warning system can be toggled via the Cvar "phire_sd_warnings", default enabled, disable by setting it to 0 in the server.cfg

 

By default the command (sm_silentday) is set to ADMFLAG_GENERIC which is flag b (not a like I said above)

 

Reply if you have any questions, if you decide to use this then thanks :)

Thanks If we can implant this that would be great :)

0

Share this post


Link to post
Share on other sites

Posted (edited)

I can't edit it but the function called "Phire_SilentDay" should return Plugin_Handled at the bottom to prevent Sourcemod marking the command as unknown.

Fix:

#pragma semicolon 1

#define DEBUG

#include <sourcemod>
#include <cstrike>
#include <sdktools>

bool IsSilentDay;
int g_Warnings[MAX_NAME_LENGTH+1] = 0;
int g_MessagesSent[MAX_NAME_LENGTH+1] = 0;
char g_PlayerName[MAX_NAME_LENGTH];
ConVar g_UseWarningSys;

#define EMPTY_MESSAGE 0

public Plugin myinfo =
{
	name = "Phire's Silentday",
	author = "Phire",
	description = "Allows the use of the custom day silentday.",
	version = "1.0.0",
	url = "Sulphox.com"
};

public void OnPluginStart()
{
	RegAdminCmd("sm_silentday", Phire_SilentDay, ADMFLAG_GENERIC, "Enable the silent day.");
	
	g_UseWarningSys = CreateConVar("phire_sd_warnings", "1", "Sets whether you want to use warnings or not.", _, true, 0.1, true, 1.0);
	
	AddCommandListener(Phire_HookSay, "say");
	AddCommandListener(Phire_HookSay, "say_team");
}

public void OnRoundStart(int client)
{
	IsSilentDay = false;
	g_Warnings[client] = 0;
	g_MessagesSent[client] = 0;
}

public Action Phire_SilentDay(int client, int args)
{
	GetClientName(client, g_PlayerName, sizeof(g_PlayerName));
	
	if (IsSilentDay == true)
	{
		PrintToChat(client, "[SM] You \x07disabled\x01 silent day.");
		PrintToChatAll("[SM] %s has disabled silent day, prisoners can now use chat.", g_PlayerName);
		IsSilentDay = false;
		return Plugin_Handled;
	}
	else if (IsSilentDay == false)
	{
		PrintToChat(client, "[SM] You \x04enabled\x01 silent day.");
		PrintToChatAll("[SM] %s has enabled silent day, any prisoners that type are now KOS.", g_PlayerName);
		IsSilentDay = true;
		return Plugin_Handled;
	}
	
	return Plugin_Handled;
}

public Action Phire_HookSay(int client, const char[] command, int argc)
{
	GetClientName(client, g_PlayerName, sizeof(g_PlayerName));
	
	char Chat[256]; 
	GetCmdArgString(Chat, sizeof(Chat));
	StripQuotes(Chat);
	
	if ((Chat[1] == EMPTY_MESSAGE) || (Chat[0] == EMPTY_MESSAGE))
	{
		return Plugin_Handled;
	}

	if (IsPlayerAlive(client))
	{
		if (GetClientTeam(client) == CS_TEAM_T)
		{
			if (IsSilentDay)
			{
				if (!IsChatTrigger())
				{
					if (GetConVarInt(g_UseWarningSys) == 1)
					{
						if (g_Warnings[client] == 0)
						{
							PrintToChat(client, "\x01[\x07ALERT\x01] Psst.. It's a \x07silent\x01 day, \x07don't\x01 use \x10chat\x01!");
							PrintToChat(client, "\x01[\x07ALERT\x01] You will be \x07KOS\x01 if you do it again!");
							g_Warnings[client] = 1;
							return Plugin_Handled;
						}
					
						else if (g_Warnings[client] >= 1)
						{
							if (g_MessagesSent[client] == 0)
							{
								PrintToChatAll("\x01[\x07ALERT\x01] \x10%s\x01 has used chat on a silent day! They are \x07KOS.", g_PlayerName);
								PrintToChat(client, "\x01[\x07ALERT\x01] You are now \x07KOS\x01 because you used chat on a silent day.");
								g_MessagesSent[client] = 1;
								return Plugin_Handled;
							}
							else
							{
								PrintToChat(client, "\x01[\x07ALERT\x01] You are now KOS because you used chat on a silent day.");
								return Plugin_Handled;
							}
						}	
					}
					else
					{
						if (g_MessagesSent[client] == 0)
						{
							PrintToChatAll("\x01[\x07ALERT\x01] \x10%s\x01 has used chat on a silent day! They are \x07KOS.", g_PlayerName);
							PrintToChat(client, "\x01[\x07ALERT\x01] You are now \x07KOS\x01 because you used chat on a silent day.");
							g_MessagesSent[client] = 1;
							return Plugin_Handled;
						}
						else
						{
							PrintToChat(client, "\x01[\x07ALERT\x01] You are now \x07KOS\x01 because you used chat on a silent day.");
							return Plugin_Handled;
						}
					}
				}
			}
		}
	}
	
	return Plugin_Handled;
}

Information:

 

Silent day can be toggled with the command sm_silentday (!silentday or /silentday)

The warning system can be toggled via the Cvar "phire_sd_warnings", default enabled, disable by setting it to 0 in the server.cfg

Cvar settings: 1 for enabled, 0 for disabled.

 

By default the command (sm_silentday) is set to ADMFLAG_GENERIC which is flag b (not a like I said above)

 

Reply if you have any questions, if you decide to use this then thanks :)

 

There is only one bug, sending messages that only contain one character will not be counted. Of course you could remove my name from the plugin but I'd really appreciate it if you would keep it there. If you don't know how to compile it then copy and paste the code to https://www.sourcemod.net/compiler.php

Edited by Phire
0

Share this post


Link to post
Share on other sites

Te only problem with this is that you cannot deny a their mic. But that rule can be changed, i guess....

0

Share this post


Link to post
Share on other sites

The only bad thing that is the slay command only for this day and what if the cts abuse it ?

0

Share this post


Link to post
Share on other sites

This contradicts an already existing rule, and would definitely be abused/overused. I don't see this rule ever being added, so I'm moving it to accepted/denied 

Also this was suggest in January and was never and that is probably for a reason.

0

Share this post


Link to post
Share on other sites