Commit Graph
100 Commits
Author SHA1 Message Date
Resxt e6bcab0960 chat_commands 1.4.3
Made it so that players can type commands and "me" (when targeting a player) any way they want. There doesn't need to be an exact match full lower case anymore for both of these
2023-10-23 22:09:12 +02:00
Resxt 5f9a46c511 mapvote 1.1.5
Small change with no impact to match an update that fixed a bug on the T6 version. This bug didn't exist on the IW5 version.
https://github.com/Resxt/Plutonium-T6-Scripts/commit/525d50dfc0d05a46632274e5625d71cc223c1fba
2023-10-09 20:38:14 +02:00
ResxtandGitHub 0ab00948ba Merge pull request #3 from Chenterito/patch-1
Improve the "FindPlayerByName" function by letting players type the beginning of a name instead of always having to type the player's full name
2023-10-09 06:43:28 +02:00
Resxt dc948d2f5c Update README.md 2023-10-09 06:40:08 +02:00
Resxt 2efa784709 chat_commands 1.4.2
Added the ability to find players by typing a part of their name (starting from the beginning of their names) instead of having to type their full names all the time.

For example to kill Resxt you can now just type !kill res
If there is a player named Resxt and another named Resxtola then typing !kill resxt will kill Resxt because we got an exact match. If you type !kill Resx it won't kill anyone because there are two potential players found so we can't be sure who the command should be run on. If you type !kill Resxto it will kill Resxtola
2023-10-09 06:33:17 +02:00
Resxt 87486829b9 mapvote 1.1.4
Added logic to hide the map when there is only one map players can vote, just like how modes work (forgot to implement maps as well)
2023-08-21 16:46:03 +02:00
Resxt e80fed04a9 all_or_nothing 1.0.3 2023-08-10 17:57:47 +02:00
Resxt 9e8ec809f9 mapvote 1.1.3
The mapvote is now enabled by default (mapvote_enable set to 1 by default instead of 0)

The default rotation system now has an additional dvar dedicated to enabling/disabling it, it no longer relies on the player count dvar to be enabled or disabled which allows it to work with the min and max dvars set to 0 (only rotate the default rotation if there's no human player)
2023-08-06 21:51:28 +02:00
Resxt 168f8b0c16 Update README.md 2023-07-28 12:55:43 +02:00
Resxt 7a3e2e2490 chat_command_balance_teams 1.0.0 2023-07-28 12:53:42 +02:00
Resxt 48bf8b8a0b chat_commands 1.4.1
Push changes that should have been pushed with 1.4.0
Fix permission issues with aliases causing the script to return that a command doesn't exist when you don't have access to the alias instead of saying you don't have the permission as expected

[Refactor] Change ExecuteCommand and TryExecuteCommand function names to reflect changes made in the T6 script that fixed an issue. The change here is only made to keep a logic between the scripts but that bug didn't exist in the IW5 version due to how IW5 works
2023-06-18 15:56:20 +02:00
Resxt b8b1e7c17e chat_command_wallhack 1.0.2
Added alias
2023-06-17 11:14:00 +02:00
Resxt 84648e3457 chat_command_unlimited_ammo 1.0.2
Added alias
2023-06-17 11:13:47 +02:00
Resxt 2dc232b65a chat_command_unfair_aimbot 1.0.2
Added alias
2023-06-17 11:13:18 +02:00
Resxt 18382c8f16 chat_command_teleport 1.0.2
Added alias
2023-06-17 11:12:30 +02:00
Resxt fe42a9e142 chat_command_suicide 1.0.2
Added alias
2023-06-17 11:10:02 +02:00
Resxt 9b637ffa91 chat_command_permissions 1.0.1
Only enable permissions command if the permission system is enabled

Added help message for getpermission

Added aliases
2023-06-17 11:09:38 +02:00
Resxt a13533c855 chat_command_norecoil 1.0.2
Added alias
2023-06-17 11:08:33 +02:00
Resxt 2ad3b0c022 chat_command_map_mode 1.0.3
Added alias
2023-06-17 11:08:15 +02:00
Resxt 2d8bbd2a9c chat_command_kick 1.0.1
Added alias
2023-06-17 11:07:56 +02:00
Resxt 9fc19a57a0 chat_command_god_mode 1.0.3
Renamed the command from god to godmode
Added aliases
2023-06-17 11:07:41 +02:00
Resxt d5c9dfab59 chat_command_dvars 1.0.2
Added alias
2023-06-17 11:07:11 +02:00
Resxt d94d8f928e chat_command_change_team 1.0.2
Added alias
2023-06-17 11:06:31 +02:00
Resxt 57053b38a8 chat_commands 1.4.0
Added an alias system so that a command can be called with different names.
The alias commands respects the permission system and can be used seemingly with the help and alias command.
The commands command still only lists the original/full command name, it doesn't list aliases
CreateCommand now has an addition argument commands can use: commandAliases

Added a new !alias or !aliases command
With these commands you can get the available alias(es) of a command by its original name or one of its alias
For example !alias god or !alias godmode

Some refactor to make the ChatListener function easier to read along with some comments to separate each command logic (built-in commands and "any other command")

Added CommandAliasesDoesNotExistError

Added GetCommandNameFromAlias util function
2023-06-17 11:06:03 +02:00
Resxt 4b25be67f8 chat_commands 1.3.3
Only create variables for the port currently in-use
For example: there's no need to create level.chat_commands["27017"] if the currently used port is 27016. This simply adds a bunch of variables and child variables for no reason, this was a flawed implementation that create an array per port on every server. Now it will only create an array for its own port as expected

Removed 27018 from the default ports
This is to make the default experience more generic across other chat_commands projects. One port for default private games and another port the expected/most used port for dedicated servers
2023-06-15 14:04:57 +02:00
Resxt 375dceea87 remove_heavy_weapon_slow 1.0.1
An additional OnPlayerWeaponSwitch function was threaded on every spawn. Now it will stop when the player dies and thread a new one as expected
2023-04-15 14:32:58 +02:00
Resxt fd0d8f3df0 chat_command_kick 1.0.0 2023-03-24 23:39:05 +01:00
ResxtandGitHub 657ff040be Update README.md 2023-03-24 01:22:19 +01:00
ResxtandGitHub b2f1f7fda1 Update README.md 2023-03-23 18:03:57 +01:00
Resxt 21b9498baa chat_command_text_help 1.0.2
Fix warnings in the console
2023-03-21 22:14:20 +01:00
Resxt 9deeecc41e chat_command_map_mode 1.0.2
Fix warnings in the console
2023-03-21 22:13:54 +01:00
Resxt 63ce9a008d chat_command_god_mode 1.0.2
Give dead silence pro to avoid dying when falling from a high height.

This only gives it if the player doesn't have it already and it only takes it away if it was granted by the god mode in the first time
2023-03-21 22:04:46 +01:00
ResxtandGitHub 28679c87d7 Update README.md 2023-03-21 03:10:24 +01:00
Resxt de875ce204 Update README.md 2023-03-21 02:54:58 +01:00
Resxt 439aefd37a Update README.md 2023-03-21 02:13:34 +01:00
Resxt ba1322b933 chat_commands 1.3.2
Changed the prefix from a level scoped variable to a dvar.
Updated IW4MAdmin instructions, including the prefix conflict

Added cc_prefix dvar
2023-03-21 01:36:36 +01:00
Resxt 32686b90d3 chat_commands 1.3.1
Add support for arguments with spaces (for example names containing spaces such as "The Moonlight")
2023-03-21 01:10:44 +01:00
ResxtandGitHub 457416ad66 Update README.md 2023-03-19 14:07:31 +01:00
ResxtandGitHub c43d955ce2 Update README.md 2023-03-19 13:41:39 +01:00
ResxtandGitHub 91ef56daa2 Update README.md 2023-03-18 02:05:52 +01:00
Resxt 5aa2ea361a chat_command_permissions 1.0.0 2023-03-18 02:01:18 +01:00
ResxtandGitHub 6cbd03f492 Update README.md
Permission level on each command
2023-03-18 01:55:00 +01:00
Resxt 09c2503c00 chat_command_wallhack 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:44:46 +01:00
Resxt 1e780b24c3 chat_command_unlimited_ammo 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:44:31 +01:00
Resxt 494eb0eba9 chat_command_unfair_aimbot 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:44:05 +01:00
Resxt 10b5b39b44 chat_command_text_rules 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update
2023-03-18 01:43:46 +01:00
Resxt 6fcdc1e3c8 chat_command_text_help 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable and prefix variable following chat_commands 1.3.0 update
2023-03-18 01:43:14 +01:00
Resxt fd6ff8805f chat_command_teleport 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:42:39 +01:00
Resxt a6ca69944e chat_command_suicide 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:42:24 +01:00
Resxt 8451c5b118 chat_command_norecoil 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:41:58 +01:00
Resxt 05b1c867ff chat_command_map_mode 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable and prefix variable following chat_commands 1.3.0 update
2023-03-18 01:41:38 +01:00
Resxt 100c1441c5 chat_command_kill 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:40:51 +01:00
Resxt 5a09bd989c chat_command_invisible 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:40:25 +01:00
Resxt d85f19944c chat_command_god_mode 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:39:54 +01:00
Resxt a26a893fae chat_command_give 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:39:31 +01:00
Resxt 998d2ca5b0 chat_command_freeze 1.0.2
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:38:45 +01:00
Resxt 93be9ab104 chat_command_dvars 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:37:10 +01:00
Resxt 36ced8fd0a chat_command_change_team 1.0.1
Added permission level to CreateCommand following chat_commands 1.3.0 update

[Refactor] changed level scoped ports variable following chat_commands 1.3.0 update
2023-03-18 01:36:20 +01:00
Resxt b0b66dcfbc chat_commands 1.3.0
This update adds an optional permission system that commands can use to determine what the minimum permission level is to be able to access that specific command

This update forces changes on the other commands scripts. If you download this version make sure to download the updated version of your individual chat command(s) script as well

Added cc_debug dvar
Added cc_permission_enabled
Added cc_commands_mode dvar
Added cc_permission_mode dvar
Added cc_permission_default dvar
Added cc_permission_max dvar
Added cc_permission_0, cc_permission_1, cc_permission_2, cc_permission_3 & cc_permission_4 dvars

Added InsufficientPermissionError error
Added InvalidPermissionLevelError error
Added GetPlayerPermissionLevelFromDvar util function
Added GetPlayerPermissionLevel util function
Added SetPlayerPermissionLevel util function
Added PlayerHasSufficientPermissions util function
Added SetDvarIfNotInitialized util function
Added IsBot util function
Added DebugIsOn util function
Added PermissionIsEnabled util function

[Refactor]
Replaced player.chat_commands with player.pers["chat_commands"]
This is to make sure the variables are kept between rounds

Replaced level scoped variables with a single level scoped array variable <level.chat_commands> holding all properties (prefix, ports etc.)
2023-03-18 01:27:20 +01:00
ResxtandGitHub 945bc04e3c Update README.md 2023-02-23 02:24:05 +01:00
ResxtandGitHub b7d1a9ab41 Update README.md 2023-02-23 02:22:55 +01:00
Resxt b57234fb09 chat_command_give 1.0.0 2023-02-23 02:22:09 +01:00
Resxt 53dc47157e chat_commands 1.2.3
Added CamoDoesNotExistError error
Added GetWeaponNameWithoutCamo util function
Added GetCamoNameFromNameOrIndex util function
2023-02-21 19:29:38 +01:00
Resxt d6bf08092b chat_command_kill 1.0.0 2023-02-19 15:09:32 +01:00
Resxt 0c20175902 chat_commands 1.2.2
Added TargetIsMyself util function
2023-02-19 15:01:14 +01:00
Resxt bf1ccc2c1f chat_command_unfair_aimbot 1.0.0 2023-02-19 14:39:44 +01:00
ResxtandGitHub 30d9bca914 Update README.md 2023-02-18 15:48:22 +01:00
Resxt e120fd102a chat_command_dvars 1.0.0 2023-02-16 16:34:23 +01:00
Resxt 994e69632e chat_commands 1.2.1
Added DvarDoesNotExistError error
Added DvarIsInitialized util function
2023-02-16 16:27:49 +01:00
Resxt e866fd5b26 chat_command_unlimited_ammo 1.0.0 2023-02-16 06:00:07 +01:00
Resxt b308c84758 chat_command_god_mode 1.0.0 2023-02-16 05:33:07 +01:00
Resxt 1c2222443e chat_command_freeze 1.0.1
Fix the bug that was not targeting the player but was targeting the player calling the command instead
2023-02-16 05:25:21 +01:00
ResxtandGitHub ba97483c5d Update README.md 2023-02-16 04:37:53 +01:00
Resxt 9f9ecf7f50 chat_command_text_help 1.0.0 2023-02-16 04:37:19 +01:00
Resxt 5fe50e216f Update README.md 2023-02-16 04:31:44 +01:00
Resxt 34f3535769 Update README.md 2023-02-16 04:30:00 +01:00
Resxt 760db1a2eb chat_command_freeze 1.0.0 2023-02-16 04:20:19 +01:00
Resxt 108b06962a chat_command_wallhack 1.0.0 2023-02-16 04:18:06 +01:00
Resxt 18938c2487 chat_command_invisible 1.0.0 2023-02-16 04:17:23 +01:00
Resxt 1a4c6a3cee chat_command_norecoil 1.0.0 2023-02-16 04:15:15 +01:00
Resxt 3384aef34f chat_command_teleport 1.0.0 2023-02-16 04:13:07 +01:00
Resxt 505b676e43 chat_command_change_team 1.0.0 2023-02-16 04:07:00 +01:00
Resxt 1ac9e89578 chat_command_map_mode 1.0.0 2023-02-16 04:03:33 +01:00
Resxt da52be9cc7 chat_command_text_rules 1.0.0 2023-02-16 03:47:54 +01:00
Resxt f1d6ce7c20 chat_command_suicide 1.0.0 2023-02-16 03:46:11 +01:00
Resxt 113424553d chat_commands 1.2.0
This is a refactor/dev that changes how the commands work but the usage stays the same for the end user. The only difference is that you now have to install each command as a separate file

[Refactor]
Moved all the commands to their respective file, just like a plugin system to easily allow the user to add/remove commands

If the server has no commands it will display a message when trying to run any command with the prefix

[Dev]
Added args comment for the CreateCommand function (commandValue and commandHelp)
2023-02-16 03:42:39 +01:00
Resxt ec7f90c134 Delete chat_commands
Deleting chat_commands to prepare for a refactor (moving to the chat_commands folder)
2023-02-16 03:24:32 +01:00
ResxtandGitHub c5d5a6b6f3 Update README.md 2023-02-15 22:36:04 +01:00
Resxt 149fb65b57 jump_monitor 1.0.0 2023-02-15 22:34:22 +01:00
ResxtandGitHub fdf1a9adba Update README.md 2023-02-15 20:27:02 +01:00
ResxtandGitHub 006078000e Update README.md 2023-02-15 20:26:44 +01:00
Resxt 716cb66aa6 kamikaze 1.0.0 2023-02-15 20:13:43 +01:00
Resxt 623d177551 welcome_message 1.0.0 2023-02-15 16:46:55 +01:00
Resxt 6096379e3e autoassign_team 1.0.0 2023-02-15 16:11:18 +01:00
Resxt c994eb4756 chaos 1.0.0 2023-02-15 15:55:46 +01:00
Resxt 59bfdc19fe chat_commands 1.1.9
[Refactor]
Fix wrong type error during help message comparison.
Change default strings to array of one string
2023-02-06 04:38:18 +01:00
Resxt a51165558c chat_commands 1.1.8
Added wallhack command to grant or remove access to a wallhack (red boxes) to a player (toggle)

[DEV]
This showcases how to implement a status/toggle command with a non permanent logic (implementing OnPlayerSpawned())
2023-02-06 04:14:53 +01:00
Resxt 6bf08da690 chat_commands 1.1.7
Added invisible command to grant or remove the invisible state to a player (toggle)
Note that this does not make you invisible to bots in the sense that even if they can't see you they will still know your position and shoot you on sight
2023-02-06 03:51:17 +01:00
Resxt 7766d9ecb9 chat_commands 1.1.6
[Dev]
Added default strings the dev can pass to automatically generate an help message for the commands with one or two player(s) as arg
2023-02-06 03:36:59 +01:00
Resxt 8ee3ca5bc7 chat_commands 1.1.5
All commands that require a player name to be passed now work both with a player name or with "me" to target yourself

[Dev]
All commands that use FindPlayerByName will now work with "me" passed as the player out of the box since FindPlayerByName now returns self if the name param is "me"

[Refactor]
Fix undefined errors when calling a status command for the first time on a player
2023-02-06 03:22:40 +01:00