Forum
Need Help - TF2 Script
Created 17th April 2009 @ 15:08
Add A Reply Pages: 1
Helluu..
I’m in need of some help.. Im terrible at scripting, so I am turning to you guys :D
I want to have r_drawviewmodel 0 as a scout, aswell as custom crosshair nr7.
And r_drawviewmodel 1, and standard crosshair as a sniper.
Is there anyone capable of making a script for this?
Big thanks in advance
m00n
X:/Steam/Steamapps/Username/Team Fortress 2/tf/cfg
X is the hdd where you installed Steam.
Open the scout.cfg with notepad and type:
cl_crosshair_file crosshair7
r_drawviewmodel 0
Open every other class.cfg with notepad and type:
cl_crosshair_file “”
r_drawviewmodel 1
You can add additional commands if you want (eg cl_crosshair_scale, cl_crosshair_blue/red/green etc.).
Thats not really a script btw :P
Would suggest making a cfg called “defaultclass.cfg” and putting basic commands for each class like “r_drawviewmodel 1” etc in it, and then put “exec defaultclass.cfg” at the top of the class cfgs.
Then you can put custom settings for each class underneath – for example as scout if you wish to set mouse2 to +reload, put “bind mouse2 +reload” into scout cfg, then put “bind mouse2 +attack2” into defaultclass.cfg to save you having to go into every class cfg each time you make a change to the default keys.
Saves a lot of time if you cba setting it up at the start – just have to remember that commands coming after the exec will overwrite it, so you can have bind “mouse2” “+attack2” in defaultclass, but then in scout.cfg you can change it and the later command will be the one that is used :x
Sorry for my poor explainin’ skills, im Scottish (that’s apparently an excuse now)
Thanks a bunch guys, works perfectly <3 <3
From my own experience, cl_crosshair_file “” doesn’t quite work, only worked when I made a separate .cfg file with “cl_crosshair_file “” then on the class cfg I simply added exec defaultcross and it worked wonders after that :>
It should work with my method, without the need of an other cfg.
http://etf2l.org/forum/general/topic-1888/page-1/?recent=22409#post-21983
I change it manually when i want to see or to not see the viewmodel with only a key, it’s really usefull.
Here’s the script:
//Drawviewmodel
alias drawviewmodeloff “r_drawviewmodel 0;bind key drawviewmodelon”
alias drawviewmodelon “r_drawviewmodel 1;bind key drawviewmodeloff”
bind “key” “drawviewmodeloff”
Psyche, it only doesnt work if you have cl_crosshair_file “” in an alias (because the “” from the command interfere with the “” from the alias).
So it works just fine.
Add A Reply Pages: 1