r/Tf2Scripts • u/Reunn • Dec 05 '18
Request [HELP] I require assistance please.
Ok so this might be fairly contrived and not even possible, it's 2am as of writing so I may be missing something obvious.
So I basically want this result;
- 1 - 9 is disguise as enemy class.
- SHIFT + 1 - 9 is disguise as friendly class
- Mwheel up is swap to revolver
- Mwheel down is swap to knife
- MOUSE3 is hold out sapper and +attack whilst I hold the button and then -attack and switch to last weapon when I release.
These are all fine, I'm also wanting when I shift + Mwheelup it swaps to primary and lastdisguises (to change the disguise weapon I'm holding) and then swaps to previous weapon, same for Mwheeldown and M3.
I managed to get this working for normal key presses no problem but I'm assuming the mousewheel doesn't register keydown and keyup inputs and is a single input so the method I am doing this with is kinda broken.
This is what I have so far; It works if I have my primary/melee out and want to use a primary/melee or secondary weapon disguise but it loops swapping disguises and weapons when going from primary to melee or melee to primary as my previous weapon.
////// SPY //////
//////////////////////////////////
//////////////////////////////////
//Spy Disguise
//////////////////////////////////
alias "CurrentWep"
alias "+DSlot1" "slot1; lastdisguise"
alias "+DSlot2" "slot2; lastdisguise"
alias "+DSlot3" "slot3; lastdisguise"
alias "-DSlot1" "CurrentWep"
alias "-DSlot2" "CurrentWep"
alias "-DSlot3" "CurrentWep"
alias "DScout" "disguise 1 -1"
alias "DSoldier" "disguise 3 -1"
alias "DPyro" "disguise 7 -1"
alias "DDemoman" "disguise 4 -1"
alias "DHeavy" "disguise 6 -1"
alias "DEngineer" "disguise 9 -1"
alias "DMedic" "disguise 5 -1"
alias "DSniper" "disguise 2 -1"
alias "DSpy" "disguise 8 -1"
alias "TDScout" "disguise 1 -2"
alias "TDSoldier" "disguise 3 -2"
alias "TDPyro" "disguise 7 -2"
alias "TDDemoman" "disguise 4 -2"
alias "TDHeavy" "disguise 6 -2"
alias "TDEngineer" "disguise 9 -2"
alias "TDMedic" "disguise 5 -2"
alias "TDSniper" "disguise 2 -2"
alias "TDSpy" "disguise 8 -2"
alias "DDrop" "disguise 8 -2"
alias "+DTeam" "bind MWHEELUP +DSlot1; bind MOUSE3 +DSlot2; bind MWHEELDOWN +DSlot3; bind 1 TDScout; bind 2 TDSoldier; bind 3 TDPyro; bind 4 TDDemoman; bind 5 TDHeavy; bind 6 TDEngineer; bind 7 TDMedic; bind 8 TDSniper; bind 9 TDSpy"
alias "-DTeam" "bind MWHEELUP SpyPrimary; bind MOUSE3 +SpySapper; bind MWHEELDOWN SpyMelee; bind 1 DScout; bind 2 DSoldier; bind 3 DPyro; bind 4 DDemoman; bind 5 DHeavy; bind 6 DEngineer; bind 7 DMedic; bind 8 DSniper; bind 9 DSpy"
//////////////////////////////////
//Spy Weapon Swap
//////////////////////////////////
alias "SpyPrimary" "slot1; alias CurrentWep slot1"
alias "+SpySapper" "slot2; +attack"
alias "-SpySapper" "slot2; -attack"
alias "SpyMelee" "slot3; alias CurrentWep slot3"
alias "+primatck" "+attack"
alias "-primatck" "-attack"
alias "+secatack" "+attack2"
alias "-secatack" "-attack2"
bind "MOUSE1" "+primatck"
bind "MOUSE2" "+secatack"
bind "MOUSE3" "+SpySapper"
bind "MWHEELUP" "SpyPrimary"
bind "MWHEELDOWN" "SpyMelee"
bind "SHIFT" "+DTeam"
bind "1" "DScout"
bind "2" "DSoldier"
bind "3" "DPyro"
bind "4" "DDemoman"
bind "5" "DHeavy"
bind "6" "DEngineer"
bind "7" "DMedic"
bind "8" "DSniper"
bind "9" "DSpy"
View all comments
Show parent comment
1
u/FanciestBanana Jan 23 '19
so did you try this? did it work?