r/Tf2Scripts • • Mar 15 '12

Archived Swapping m1 and m2 between weapons

I had this idea the other day to swap M1 and M2 on my Pyro so that I airblast with M1. My thinking was that after all my years of playing shooters, drawing, and picking my nose, my pointer finger has got to have much thicker 'cables' in my brain.

So I tried to make this script that would swap Mouse1 and Mouse2 on my flamethrower but then swap them back to normal when using my secondary or melee so I can use the detonator and axtinguisher like normal. The issue is that when I swap between them, because each weapon rebinds these buttons, it forces one of them to get stuck down if I swap while airblasting or flaming and I end up wasting my ammo a bit until I double click a few times.

The fix I came up with was to put a -attack, -attack2, on the weapons aswell so that I'm forced to stop firing between weapons but the issue with that is that if I hold down my weapon swap key a second too long I'm going to be preventing myself from firing which has been making me miss with my axtinguishing and shotgun much more because I can't start shooting the very second I swap.

Here's an example of the script that gets stuck:

Bind shift "+axe"

Alias +axe "slot3;bind mouse1 +attack; bind mouse2 +attack2"

Alias -axe "slot1;bind mouse1 +attack2; bind mouse2 +attack"

Here's an example of the script that doesn't get stuck but prevents me from firing

Bind shift "+axe"

Alias +axe "-attack;-attack2;slot3;bind mouse1 +attack; bind mouse2 +attack2"

Alias -axe "-attack;-attack2;slot1;bind mouse1 +attack2; bind mouse2 +attack"

7 Upvotes

0 comments sorted by