Author Topic: Rotating Auto-Powers Using Bind Files  (Read 2705 times)

Sky-Forge

  • Newbie
  • *
  • Posts: 3
  • Inf: +0/-0
    • View Profile
    • Awards
Rotating Auto-Powers Using Bind Files
« on: October 27, 2023, 03:46:00 pm »
This is an idea I got several years ago from a comment in the HC forums, which surprisingly did not garner a lot of responses despite how useful it is (I suspect that could also be because the post assumed some general knowledge of bindload files, and was buried within another thread), but all credit to the user "rmancu" there for this idea. I've revised the approach a little to fit my own needs, and have been using this ever since - it has made some builds SO much easier to play.

So what does this do? The idea is to essentially have two (or any number) of auto-powers that will automatically rotate. For example, you have a Shield toon, and want to have both Hasten and Active Defense auto-fire; or you have a Dominator and want to have Hasten and Domination on auto. This is something people have asked for many times in the past, and there have understandably been concerns about how it could be abused for AFK farming. That is the catch with this approach - it does NOT do anything for you if you are AFK: you have to be actively playing in order for this to work (which you'll see below).

So how does it work? This binds the toggling of your auto-powers to the movement keys (WASD) and the 1-0 keys. So as long as you're either moving around, or using the number keys, your auto-powers will continue to rotate (which is why this can't be utilized for AFK farming).

How to Setup the Bind files:
Each power you want included in the rotation will need its own bind file. These are just text files, and I like to put them into subfolders within the binds directory. In this example, we're going to set Hasten and Active Defense as our two rotating auto-powers. Here is an example of the two bind files that will be needed (you can copy these and create your own, otherwise I've attached them as well):

B1.txt
Code: [Select]
w "+forward$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
a "+left$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
s "+backward$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
d "+right$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
0 "powexecslot 10$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
1 "powexecslot 1$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
2 "powexecslot 2$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
3 "powexecslot 3$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
4 "powexecslot 4$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
5 "powexecslot 5$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
6 "powexecslot 6$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
7 "powexecslot 7$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
8 "powexecslot 8$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""
9 "powexecslot 9$$powexecauto Hasten$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B2.txt""

B2.txt
Code: [Select]
w "+forward$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
a "+left$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
s "+backward$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
d "+right$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
0 "powexecslot 10$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
1 "powexecslot 1$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
2 "powexecslot 2$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
3 "powexecslot 3$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
4 "powexecslot 4$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
5 "powexecslot 5$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
6 "powexecslot 6$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
7 "powexecslot 7$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
8 "powexecslot 8$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""
9 "powexecslot 9$$powexecauto Active Defense$$bindloadfilesilent "D:\CoH Rebirth\data\binds\Zalenia\B1.txt""

Just to explain what's happening in these files - each of the WASD and 1-0 keys are assigned with their default behavior (so beware if you have remapped those keys to do something else), then it sets the auto-power, then finishes with loading the next bind file. The next bind files does the same, except assigns a different auto-power, then loops back to loading the first file. I have mine setup so that each character has their own folder within the binds directory (the original approach from rmancu used the default binds directory, but I wanted to have subfolders for each alt to have their own setup), so in this case, "Zalenia" is the character name, and she has her own folder within the binds directory.

The file location here is important - you will need to make sure the file paths used within the bind files match the folder structure of where you are placing these files. Anywhere in these examples where you see "D:\CoH Rebirth\data\binds\Zalenia\" - that is my local file path, so you will need to update it to your own local file location.

Once you have those bind files setup with their respective folder, all you need to do is load the bind files in game. It doesn't matter which one you load, since they cycle between each other, but I typically just load the first one. In game, use this command (adjusting to use your own local file path of course) to load the bind files:
/bind_load_file "D:\CoH Rebirth\data\binds\Zalenia\B1.txt"

Then that should be it! Pressing the WASD or 1-0 keys should now be rotating between the two powers used in the bind files. This can be used for any powers that can be set to autocast, and additional bind files can be added as well. Although do note that, the more files you add, the more powers it now has to rotate between, which means they may not always fire off as soon as the power is recharged, but rather when it has a chance to cycle back to that power. I have done up to 4, but I typically try to keep it down to 2 or 3 for most characters.

Anyways, I hope this helps someone! I've been using this for years now and it has definitely increased my enjoyment of certain characters/builds. I'm sure there are additional things that could be added or improved in this method, so if you find any other cool use cases, feel free to share!

Sky-Forge

  • Newbie
  • *
  • Posts: 3
  • Inf: +0/-0
    • View Profile
    • Awards
Re: Rotating Auto-Powers Using Bind Files
« Reply #1 on: October 30, 2023, 01:03:31 pm »
I thought it might be useful to add this too. In some cases, it might not be ideal to have these running all the time. For example, maybe you're exemplaring and powers you had on rotation that would normally be 100% uptime are things you now want to use situationally. For cases like these, I made macros that allow me to turn the auto-rotating on or off with a single click.

To do this, I created another folder named "Blank" within my Binds directory. This folder just contains one bind file, which has the default mappings for the keys set in the rotating bind files. Here is an example of that file:

B1.txt
Code: [Select]
w "+forward"
a "+left"
s "+backward"
d "+right"
0 "powexecslot 10"
1 "powexecslot 1"
2 "powexecslot 2"
3 "powexecslot 3"
4 "powexecslot 4"
5 "powexecslot 5"
6 "powexecslot 6"
7 "powexecslot 7"
8 "powexecslot 8"
9 "powexecslot 9"

So then, for the macros, I would use this one to turn on the auto-rotating function:
/macro Auto bind_load_file "D:\CoH Rebirth\data\binds\Zalenia\B1.txt"

Then for the macro to turn them off, I use this:
/macro Off bind_load_file "D:\CoH Rebirth\data\binds\Blank\B1.txt"

Now you'll have macros to turn the binds on and off at will. When you turn it off, the last power that was set to auto-cast will stay that way until you remove it or switch it to a new one.