r/tf2scripthelp • • Jul 16 '20

Issue Can you help me pls with the scripts of cfg.tf

2 Upvotes

I've been messing around with scripts for a while now and everything is fine but the interp, for some reason, it just locks on 0303 like its fine for projectile but not so good for hitscan classes, and I can't change it, can u pls help me?


r/tf2scripthelp • • Jun 24 '20

Issue Weapon Sheens

2 Upvotes

Hi, not sure if this is the right place to post it but.. yeah

I downloaded the master config from a tf.tv post and it's working pretty well. However, it disables weapon sheens and I want them enabled. Every post I've viewed on this matter says you have to input -dxlevel 90 or 95~ and it'll work but I've done this and I still can't see the sheens. help?


r/tf2scripthelp • • May 26 '20

Wrong section I need your help! [Script TF2]

2 Upvotes

Hello everybody, I'm new to TF2 scripting and could use some help.

I rented a server on nitrado because I want to make a german server

[there are not many german servers in tf2] so I decided I'm making my own.

but that's easier said than actually done are they any good scripters here that could explain to me where I can script and how it works not a tutorial, just a simple explanation. Thanks.


r/tf2scripthelp • • May 25 '20

Resolved Faulty Medic Script

2 Upvotes

I've taken a line of code from General's Medic Config, which makes me switch to mouse 2 and activate uber, regardless of which weapon I'm holding. However it has not been functioning properly.

+charge "+attack2;slot2;say_team "<<<UBER ACTIVATED>>>;wait 30;-attack2"

It should should switch me immediately to my medigun and activate uber, but it doesn't work and strangely makes me taunt when I press mouse2 with the ubersaw out.

Anyone have any ideas?


r/tf2scripthelp • • May 21 '20

Issue MinMode Scripting Help.

2 Upvotes

I want a script that changes my fov to 90 when I turn minmodes on but back to 54 when I turn it off, is there anyway to do this?


r/tf2scripthelp • • May 21 '20

Question engineer mouse wheel

2 Upvotes

I need help getting the mouse wheel to only switch to slots to my weapons not my pda's


r/tf2scripthelp • • May 15 '20

Meta Should r/TF2ScriptHelp Cover SourceMod Questions?

2 Upvotes

Hey all,

I just want to preface this by saying that I'm right now I'm coming to you all not as a mod, but as just another user of this sub. (Which, to be honest, is what I generally try to be: a normal user with flairing privileges. I like a clean sub, sue me.)

Anyway, I've been rolling this idea around in my head for quite a while, and I really want to know what you guys think:

Should r/TF2ScriptHelp cover SourceMod questions?

We're all programmers here, of a sort, and I have to imagine that someone here knows SourceMod. Additionally, there currently isn't any subreddit for SourceMod questions or discussions, and SM is technically a scripting language, right? I mean, it's just PAWN, but with added Source stuff, right? It can't be that hard. (haha oh god what the heck is a callback anyway)

Obviously, this would require separate flairs and categorizations, but that's fairly easy to implement on the backend. The real question is if any of you guys actually know SourceMod, and would be willing to answer SourceMod questions.

And I just want to stress that if we take on SourceMod questions, that would wholly be a side gig. The priority of this sub is and always will be console scripting. I just know that there are a lot of very talented programmers here from all kinds of backgrounds, and I think this would be a good opportunity for us to both get more traffic and become more well-rounded coders, as well as learn a bit more about the game we spend way too much of our lives on.

So, thoughts?


r/tf2scripthelp • • May 10 '20

Resolved Toggleconsole ignored when used with hold bind

2 Upvotes

My setup is something like this:

// autoexec.cfg
alias +shift "exec modif"
bind "SHIFT" "+shift"

My class-specific cfgs follow this pattern:

// spy.cfg
exec reset
alias -shift "exec spy"

The modifier file is:

// modif.cfg
bind "e" "some-alias"
bind "\" "toggleconsole"

The reset file is:

// reset.cfg
unbind "\"
bind "e" "voicemenu 0 2"

I tried replacing toggleconsole with say test and it works correctly. I also tried to manually bind toggleconsole to \ and it worked correctly but nothing happens (with no error in console) if use a modifier bind like above


Nevermind, this command also acts weird. You have to use an alias like this to make it work

alias "-showconsole" "toggleconsole"
bind "\" "-showconsole"

r/tf2scripthelp • • Apr 21 '20

Answered Chat Message Script [Help]

2 Upvotes

I've been trying to find/make a script that I can use to toggle a loop that says something in chat, but have run into a problem.

Firstly, here's the script as of now, for context:

  • alias looptexton "alias looptext say [message]; wait 10; looptext; bind p looptextoff; looptext"

  • alias looptextoff "bind p looptexton; alias looptext [gibberish]"

  • alias looptext "say [message]; wait 100; looptext"

  • bind p looptexton

Now, in the first line I want to make an alias that creates an alias that has multiple commands within it, but also executing other commands. The problem, which is also in that first line, is that I'm pretty sure it would need another set of " " to separate the alias with the normal commands. Right now all that command does is says the message once, then binds p to looptext off. What I'm aiming for is aliasing looptext correctly, looping looptext, then making p looptextoff which will toggle the command by making looptext not a command anymore. Any help is much appreciated.

Also, this script is a slightly modified version of the script from a comment made by u/unhandybirch656 I found in this post from two years ago.


r/tf2scripthelp • • Apr 06 '20

Answered Loadout Configs?

2 Upvotes

Is it possible for me to make a .cfg file that is executed specifically when I am using a specific weapon/loadout? Thanks in advance.


r/tf2scripthelp • • Feb 29 '20

Resolved help with sandvich

2 Upvotes

I recently found this script the concept is interesting but it doesn't work I would appreciate some help on this

Heavy Exclusive Script

This heavy script lets you throw the sandvich with one click and eat the sandvich.
WARNING: If you do the "eat sandvich" while your minigun is revving down, you will taunt with the minigun.

SCRIPT:
//SANDVICH DROP AND EAT SCRIPT

//Quick Sandvich toss
alias "+sandvichtoss" ";slot2;wait 50;+attack2;wait 50;-attack2"
alias "-sandvichtoss" "-attack2"
bind "mouse4" "+sandvichtoss"

alias +sandvichtoss "slot2; +attack2
alias "-sandvich2" "voicemenu 0 1"
bind MOUSE4 +sandvich1
bind MOUSE3 +sandvich2


r/tf2scripthelp • • Feb 10 '20

Resolved 'medic.cfg' not present; not executing

2 Upvotes

I have a medic cfg that only changes 1 command from my normal config:

bind "MOUSE2" "+attack2;say_team -==UBER Used==-" whereas my normal cfg is just +attack2

but every time I switch, it comes up in the console with what is in the title. I have the config saved in:

C:\Program Files (x86)\Steam\steamapps\common\Team Fortress 2\tf\custom\myscripts and it is with its accompanying .txt file both of which are called "medic.cfg"

Is there anything that i'm doing wrong?


r/tf2scripthelp • • Feb 08 '20

Answered Are there any in-game commands that would make flame particles less obstructing of vision, or would I need a mod?

2 Upvotes


r/tf2scripthelp • • Dec 17 '19

Answered Binding multiple functions within an alias

2 Upvotes

Hi, right now im trying to make a script so that pressing mouse1 will fire your weapon, then execute a command, then bind the key to a different command.

bind mouse1 "+attack; dumb1"
alias dumb1 "say words1; bind mouse1 "+attack; dumb2"
alias dumb2 "say words2; bind mouse1 "+attack; dumb3"
alias dumb3 "say words3; bind mouse1 "+attack; dumb4"

the words1 stuff is placeholder text. The problem im running into is when the alias is made, it interprets every subcommand in the bind as its own command, IE: bind mouse1 "+attack; dumb2" is being read as bind mouse1 "+attack" and dumb2

how do i use an alias to bind a key to multiple functions without the alias reading them all as separate commands?


r/tf2scripthelp • • Dec 11 '19

Answered Help with medic Ubercharge broadcast script

2 Upvotes

Ok so currently I have a medic script that tells my team I used ubercharge In the team chat whenever I press mouse2 that looks like this:
alias "popMediG" "say_team > POPPED UBERCHARGE (MEDI GUN)"

alias "popKritz" "say_team > POPPED UBERCHARGE (KRITZKRIEG)"

alias "popQuick" "say_team > POPPED UBERCHARGE (QUICK-FIX)"

alias "popVacci" "say_team > POPPED UBERCHARGE (VACCINATOR)"

alias "pop" "popMediG"

alias "+uber" "spec_prev; maskVoice; +attack2; pop"

alias "-uber" "maskVoice; -attack2"

bind "MOUSE2" +uber

but right now it's only able to say the first message. I don't want my team to think I popped stock uber when I'm actually using the vaccinator. Is there a way for me to be able to press a button in-game that switches which message it broadcasts when I use Uber?


r/tf2scripthelp • • Oct 31 '19

Answered how do you have weapon specific viewmodels

2 Upvotes

like you have your secondary viewmodels off but you want to have viewmodels on for like the jarate


r/tf2scripthelp • • Aug 06 '19

Resolved Ran into a snag trying to setup multiple random killsounds.

2 Upvotes

I wanted to have multiple killsounds and followed this guide ( https://steamcommunity.com/sharedfiles/filedetails/?id=528571728 ) perfectly, but only my first killsound plays whenever I get a kill. I know that all of them work because the other killsounds will play correctly when the command "play ui/killsound_percussion#" is typed into the console, but still only the first one will actually play after kills. If anyone could please give some insight on my problem, it would be greatly appreciated.

Here is the text for games_sound_weapons.txt...

"Player.KillSoundPercussion"

{

"channel"		"CHAN_STATIC"

"volume"		"1"

"soundlevel"  	"SNDLVL_NONE"	

"pitch"			"PITCH_NORM"
"rndwave"

{

	"wave"	")ui/killsound_percussion.wav"

	"wave"	")ui/killsound_percussion2.wav"

	"wave"	")ui/killsound_percussion3.wav"

	"wave"	")ui/killsound_percussion4.wav"

	"wave"	")ui/killsound_percussion5.wav"

	"wave"	")ui/killsound_percussion6.wav"

	"wave"	")ui/killsound_percussion7.wav"

	"wave"	")ui/killsound_percussion8.wav"

	"wave"	")ui/killsound_percussion9.wav"

	"wave"	")ui/killsound_percussion10.wav"

	"wave"	")ui/killsound_percussion11.wav"

	"wave"	")ui/killsound_percussion12.wav"

	"wave"	")ui/killsound_percussion13.wav"

}

}


r/tf2scripthelp • • Jun 24 '19

Answered (Image in post) How do I bind a key to close the taunt menu? I can't find it anywhere.

2 Upvotes

This is what I need, I think by default it's q but i'm using q for something else. I'd like to set it to MOUSE3 please.


r/tf2scripthelp • • Jun 01 '19

Answered is there a console command or a script that make you can't move forward while crouching??

2 Upvotes

r/tf2scripthelp • • May 21 '19

Resolved In tf2 my screen looks like it has baseline all over it and I don't know why. This makes it almost impossible to play.

2 Upvotes

I think it has something to do with lightning but I have tried a lot of things and none of it helps.


r/tf2scripthelp • • May 09 '19

Answered i want a key to toggle this bind on and off

2 Upvotes
alias "+quick_gun" "slot2;+attack"
alias "-quick_gun" "-attack;lastinv"
bind "MOUSE2" "+quick_gun"

ECHO Quick Shotgun-Changer Script (11.05.2009) executed

bind "MOUSE5" "attack2"

i want m5 to swap m2 from the shotty to the actual m2 use. any idea how?


r/tf2scripthelp • • Apr 09 '19

Resolved Guys, I REALLY need help with this config, lol. Pls help.

2 Upvotes

Stay with me here...

/////Pyro MLG Config

/////Trial

///

alias One_to_Last_Used "bind q lastinv; r_drawviewmodel 1; viewmodel_fov 70; Last_Used_Back_to_One";

alias Last_Used_Back_to_One "bindtoggle q "One_to_Last_Used" 0; slot1; r_drawviewmodel 0; viewmodel_fov 25; "One_to_Last_Used" 1";

bind "1" "slot1; r_drawviewmodel 0; viewmodel_fov 25; One_to_Last_Used";

///

alias Two_to_Primary "bind q "slot1; r_drawviewmodel 0; viewmodel_fov 25; Then_Back_to_Two";

alias Then_Back_to_Two "bindtoggle q "Two_to_Primary" 0; slot2; r_drawviewmodel 1; viewmodel_fov 70; "Two_to_Primary" 1"'

bind "2" "slot2; r_drawviewmodel 1; viewmodel_fov 70; Two_to_Primary";

///

alias Three_to_Primary "bind q "slot1; r_drawviewmodel 0; viewmodel_fov 25; Then_Back_to_Three";

alias Then_Back_to_Three "bindtoggle q "Three_to_Primary" 0; slot3; r_drawviewmodel 1; viewmodel_fov 70; "Three_to_Primary" 1"'

bind "3" "slot3; r_drawviewmodel 1; viewmodel_fov 70; Three_to_Primary";

///

So, Ive been trying to get this config to work and from what I can tell, the concept is simple yet the actuall procedure is VERY complex.

So far all this config has done is crash my game, but I think I'm on the right track here, kinda...

The Idea behind it is that at all times I want my pyro's primary, secondary and mele spots looking like this at all times, (respectively)

r_drawviewmodel 0; viewmodel_fov 25

r_drawviewmodel 1; viewmodel_fov 70

r_drawviewmodel 1; viewmodel_fov 70

But my problem is that I still want to use quickswitching weapons to some extent... Hence why the aliasing is nescesary.

So far its not a traditional quickswitch, as I didn't try and program in a 2nd to 3rd/ vice versa at all.

Does anyone here know how to solve my problem, or is this actually impossible to script?

Please help, lol.


r/tf2scripthelp • • Mar 28 '19

Answered How to stop aliases

2 Upvotes

I made a script that says the entire bee movie script 127 characters per 5 seconds which takes about 33 minutes to finish and I want to be able to stop it early but I'm trash at programming so I don't know how.

My script puts an alias that says every 127 character segment of the bee movie script, then groups of 10 are given aliases with wait commands in between, then those groups are again put into groups of 10 with wait commands 10x longer in between, then puts those remaining 4 groups into an alias with wait commands 100x longer in between.