-
-
Notifications
You must be signed in to change notification settings - Fork 464
Closed
Labels
Buggeneral bugs; can be anythinggeneral bugs; can be anythingDocumentationa change only towards documentationa change only towards documentationGood First IssueIssues that are suitable for first-time contributors.Issues that are suitable for first-time contributors.
Description
Help us help you
- I have checked that my issue doesn't exist yet.
- I have tried my absolute best to reduce the problem-space and have provided the absolute smallest test-case possible.
- I can always reproduce the issue with the provided description below.
Environment
- Operating System version: Windows
- Game/AppID (with version if applicable): 232330 (Counter-Strike: Source Dedicated Server)
- Current SourceMod version: 1.10.0.6492
- Current SourceMod snapshot: 1.11.0.6633
- Current Metamod: Source snapshot: 971:6c8495f
- I have updated SourceMod to the latest version and it still happens.
- I have updated SourceMod to the latest snapshot and it still happens.
- I have updated SourceMM to the latest snapshot and it still happens.
Description
The documentation for the CommandListener callback says
Returning Plugin_Handled or Plugin_Stop will prevent the original, baseline code from running.
In my test code it seems to only block when returning Plugin_Stop.
I think the check is here
Is this a documentation issue or an implementation issue?
Problematic Code (or Steps to Reproduce)
#include <sourcemod>
public void OnPluginStart()
{
AddCommandListener(CommandListener_Noclip, "sm_noclip");
}
Action CommandListener_Noclip(int client, const char[] command, int argc)
{
if (IsPlayerAlive(client) && argc < 1) {
ReplyToCommand(client, "[SM] aaaa");
return Plugin_Handled;
}
return Plugin_Continue;
}With the funcommands plugin loaded, run sm_noclip
Logs
Console output is:
] sm_noclip
[SM] aaaa
[SM] Usage: sm_noclip <#userid|name>
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Buggeneral bugs; can be anythinggeneral bugs; can be anythingDocumentationa change only towards documentationa change only towards documentationGood First IssueIssues that are suitable for first-time contributors.Issues that are suitable for first-time contributors.