Raised This Month: $12 Target: $400
 3% 

[CS GO] How to print content of a file in the console


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Kuhlimuh
New Member
Join Date: Feb 2018
Old 02-28-2018 , 19:14   [CS GO] How to print content of a file in the console
Reply With Quote #1

Hey,

I wanted to create a help.txt file for users on my server that all admins can access while being in game.

I had the idea that they can write ".help" in the console and the possible commands (from the .txt or whatever) will be displayed in the console. Since all of them are admins it's also possible to write "rcon exec help.cfg".

I tried it with a .cfg file that only had "say "message"" in it but since there are like 20 lines the console is just messy.

Is there an elegant way to do it?

Last edited by Kuhlimuh; 02-28-2018 at 19:15.
Kuhlimuh is offline
Squallkins
AlliedModders Donor
Join Date: Mar 2005
Old 03-01-2018 , 00:08   Re: [CS GO] How to print content of a file in the console
Reply With Quote #2

You could just create a web page and use something like Web Shortcuts to open it ingame.

There is also a client side limit on the length of text that can be displayed in the console
Squallkins is offline
OSWO
Senior Member
Join Date: Jul 2015
Location: United Kingdom, London
Old 03-01-2018 , 02:07   Re: [CS GO] How to print content of a file in the console
Reply With Quote #3

Well you should first start look at: https://sm.alliedmods.net/new-api/files/File

You can create a "File" file with the method, OpenFile(...
__________________
SourceTimer | WeaponSkins++ | BasePlugins++ https://github.com/OSCAR-WOS
OSWO is offline
8guawong
AlliedModders Donor
Join Date: Dec 2013
Location: BlackMarke7
Old 03-01-2018 , 03:11   Re: [CS GO] How to print content of a file in the console
Reply With Quote #4

https://forums.alliedmods.net/showthread.php?p=1130659
__________________
8guawong is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 19:34.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode