You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Pretty self explanatory, attempting to use SendToConsole(string) via script_client or script_execute_client gives the following error: [vscript] AN ERROR HAS OCCURED [the index 'SendToConsole' does not exist] [vscript] CALLSTACK [vscript] *FUNCTION [main()] unnamed line [1] [vscript] LOCALS [vscript] [this] TABLE
The expected behavior would be to run the command on only the client executing the script, but it fails instead. This makes it difficult to make client side utility functions that change convars or client side configurations (like keybinds) dynamically.
While it can be worked around by running on the server, that will affect all connected players, or require further workarounds like spawning entities and abusing I/O, which could potentially disrupt map logic by mistake. It also prevents access to client side StorageScopes from the Storage api, meaning saved configuration data would be tied to the server for all players, instead of being stored locally on the client.
Issue Map
This can be tested on any map with console commands.
To Reproduce
load any map to enable VScript
run this command: script_client SendToConsole("say hello world!")
read the output.
Operating System
No response
The text was updated successfully, but these errors were encountered:
Describe the bug
Pretty self explanatory, attempting to use SendToConsole(string) via script_client or script_execute_client gives the following error:
[vscript] AN ERROR HAS OCCURED [the index 'SendToConsole' does not exist] [vscript] CALLSTACK [vscript] *FUNCTION [main()] unnamed line [1] [vscript] LOCALS [vscript] [this] TABLE
The expected behavior would be to run the command on only the client executing the script, but it fails instead. This makes it difficult to make client side utility functions that change convars or client side configurations (like keybinds) dynamically.
While it can be worked around by running on the server, that will affect all connected players, or require further workarounds like spawning entities and abusing I/O, which could potentially disrupt map logic by mistake. It also prevents access to client side StorageScopes from the Storage api, meaning saved configuration data would be tied to the server for all players, instead of being stored locally on the client.
Issue Map
This can be tested on any map with console commands.
To Reproduce
script_client SendToConsole("say hello world!")
Operating System
No response
The text was updated successfully, but these errors were encountered: