r/tf2scripthelp • u/Samotage820 • May 23 '16
Resolved Bhop/Surf Toggle Script Problem
I found this simple toggle script to switch the mouse wheel from weapon switching to jumping. This script works fine for me.
bind alt bhop
alias bhop "bind mwheeldown +jump; bind mwheelup +jump; bind alt norm"
alias norm "bind mwheeldown invnext; bind mwheelup invprev; bind alt bhop"I have recently started surfing again and wanted the bhop bind to also change my mouse buttons from "Thanks!" and "Spy!" to turning left and right at default cl_yawspeed. I attempted this by editing the code as follows:
bind alt bhop
alias bhop "bind mwheeldown +jump; bind mwheelup +jump; bind mouse5 +left; bind mouse4 +right; bind alt norm"
alias norm "bind mwheeldown invnext; bind mwheelup invprev; bind mouse5 "voicemenu 1 1"; bind mouse4 "voicemenu 0 1"; bind alt bhop"When I hit "alt" the "bhop" alias works fine, but when I hit it again to switch back to alias "norm" only the mousewheel resets, and the mouse buttons remain on "+left" and "+right". I have tested switching the mouse buttons to other commands in alias "norm" but they are all permanently overridden by the turning commands.
Any help is greatly appreciated!
View all comments
Show parent comment
1
u/Samotage820 May 24 '16
You're correct, removing the nested quotes didn't change anything, but the additional aliases worked beautifully. Thanks for your help!