Skip to content

Commit

Permalink
feat: Partial refactoring, fixes know issues
Browse files Browse the repository at this point in the history
- Prevent players to avoid comms block issues
- Fix players considered as not verified and cant be muted/gagged
- Fix comms receive from web not applied immediatly
- Create forward when player get unpunished
- Adjust punish forward position
- Optimisation of string read speed comparaison
  • Loading branch information
Rushaway committed May 2, 2024
1 parent bf5303b commit 1db89f9
Show file tree
Hide file tree
Showing 2 changed files with 476 additions and 365 deletions.
12 changes: 11 additions & 1 deletion game/addons/sourcemod/scripting/include/sourcecomms.inc
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// *************************************************************************
// This file is part of SourceBans++.
//
// Copyright (C) 2014-2023 SourceBans++ Dev Team <https://github.com/sbpp>
// Copyright (C) 2014-2024 SourceBans++ Dev Team <https://github.com/sbpp>
//
// SourceBans++ is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -107,6 +107,16 @@ native bType SourceComms_GetClientGagType(int client);
*/
forward void SourceComms_OnBlockAdded(int client, int target, int time, int type, char[] reason);

/**
* Called when removed communication block for player.
*
* @param client The client index of the admin who is unblocking the client.
* @param target The client index of the player to blocked.
* @param type The type of unblock. See section "Int definitions for punishments types".
* @param reason The reason to unblock the player.
*/
forward void SourceComms_OnBlockRemoved(int client, int target, int type, char[] reason);

public SharedPlugin __pl_sourcecomms =
{
name = "sourcecomms++",
Expand Down

0 comments on commit 1db89f9

Please sign in to comment.