• Please make sure you are familiar with the forum rules. You can find them here: https://forums.tripwireinteractive.com/index.php?threads/forum-rules.2334636/

Console output after using console commands

heller96

FNG / Fresh Meat
May 10, 2019
2
0
So I'm working on my custom version of Marco's Access Plus (creates new console commands to let admins control the game more). AccessPlus has a console command "admin help" which lists all the available commands for the user that entered the command. By default it uses the function ClientMessage(string) to display these commands in chat, which is nice. However after adding about 20-25 new commands, I need to scroll through chat to see all the available commands and it is becoming very annoying. I had the idea that maybe I could print all this information into the game's console, so I've been looking for a way to do this, since the game's console is so empty all the time, it's barely used for anything (sadly), so it'd be the perfect way to solve my issue. I found the function OutputText(MessageString) inside the class Console.uc, so I looked for ways to implement it into the code I already have.

This is what I have as of now:


Spoiler!


And this is how I tried to implement my function:

Spoiler!


Unfortunately it doesn't work. The compiler doesn't show any errors, but when I enter admin help ingame, nothing shows up in the console. My assumption is that LocalPlayer(Player) is not the person executing the console command, but I haven't found another way to make it work.

Maybe someone here on the forums could help me with this and point me in the right direction?