FAQ  •  Register  •  Login

Virtual Keymaps and Press/Release

Moderator: MiRai

<<

mo_ron

Posts: 22

Joined: Thu Apr 28, 2011 6:12 pm

Post Fri Apr 29, 2011 3:41 pm

Virtual Keymaps and Press/Release

Let me explain how a subset of my keymaps are setup and then I'll get into what I'm having trouble doing. This is in the context of playing LOTRO. My main is a champ and for this example we'll say I have 3 RK's healing my main.

I have a group of keymaps assigned with to various keys which represent the main skills I use on my champ to do DPS. Along with passing the key along to my champ, I also have all of these keymaps call another keymap. I call it my "Main Pass Through". For example:

Code:
KeymapName: 1
Hotkey: 1
Step 1:
Send keystroke 1 -> self
Do keymap Main Pass Through -> self


My Main Pass Through keymap looks like:

Code:
KeymapName: Main Pass Through
Step 1:
Do keymap DPS Melee Rotation -> DPS - Melee (all)
Do keymap DPS Range Rotation -> DPS - Range (all)
Do keymap Heal Round Robin -> self


The 2 dps keymaps are just virtual keymaps that the individual toons define however they may. The Heal Round Robin keymap looks like ->

Code:
KeymapName: Heal Round Robin
Do keymap Heal Rotation -> Healing (all) round-robin


The keymap Heal Rotation is a virtual keymap like the dps keymaps. What I end up with is every DPS class executes a skill everytime my champ executes a skill. My healers, on the otherhand, rotate amongst each other while performing their own rotations.

Up to this point, everything works great and just as I had hoped it would when I made it.

In examining my healing skills on my RKs, I came to the conclusion that for some steps, I would like each healer to execute two skills each time it is their turn to heal. I've never played other MMO's so I don't know how the skill queueing works but for LOTRO you can hit two skills, say you hit the keys 1 and then 2 right after it right away. The skill for slot 1 will go through its normal induction and the skill for 2 will stay queued up and will fire when 1 is done. You can't queue up anything more than just one ahead of whatever is being executed currently.

So the first thing I tried is putting both skills as different actions on the same step. This works with a number of things in regards to Innerspace and LOTRO (like movement), but it doesn't work when it comes to the skill queue. Only one action will actually execute and the 2nd is not queued up.

So in browsing through this forum, I came upon a post where the hotkey press and release were used to execute two separate actions with one keystroke. I modified my RK healing rotation keymap so that they were broken up into pairs. I ended up with 10 steps, each with one action. I changed my RK keymap to execute on both hotkey press and release. My goal was to have steps 1 and 2 execute with keypress 1(press and release); Steps 3 and 4 with keypress 2 (press and release), etc.

I was still only getting one action per keypress. So I tried to debug my script. I put only one RK in my Healers target group. I ended up adding a bunch of toggle buttons to a new bar and assigning text to them as the different steps were executed so I could see what the script was doing. All 10 steps were getting executed everytime I pressed a button.

So I changed all the keymaps (1, Main Pass Through, Healing Round Robin, Healing Rotation (virtual)) to:

Code:
Hold any Keystroke Actions while Hotkey is held -> off


This made it so only two steps were executed for every keypress (what I wanted), BUT, both steps were executing on the release of the hotkey so LOTRO only queued up one skill. Back to my original problem . . .

I tried making the virtual keymap above my RK healing rotation keymap to also work on both press and release but that made 4 steps execute on every keypress. I'm not sure what to. It seems like that press and release functionality only works if it's set on the keymap that also has the hotkey assisgned to it. If the keymap with the hotkey calls a virtual keymap, the press and release doesn't work in the virtual keymap. It works in that you get two steps executed. But they aren't timed with the press and release of the original keymap hotkey.

Any ideas? Maybe I'm approaching this entirely incorrectly. Thanks for your time!
<<

lax

User avatar

Site Admin

Posts: 7301

Joined: Tue Nov 17, 2009 9:32 pm

Post Sun May 01, 2011 8:13 am

Re: Virtual Keymaps and Press/Release

You want Hold on the mapped key with the Hotkey (outermost), and on the one it executes for your healer, you want "Pressed OR Released" with 2 steps. When Do Mapped Key Action is used from a mappped key with the Hold option enabled, the press/release events are preserved and honored so that the "Pressed OR Released" should execute exactly as if the Hotkey was actually on THAT key. Additionally, you may need to change some intermediate hotkeys to also use Hold.

If there's multiple layers of Do Mapped Key Actions, it will follow the Hold/Press/Release options for each one along the chain. So if you had:
1. Hotkey with Hold does..
2. Mapped Key set to Press does..
3. Mapped Key set to Pressed OR Released
.. then #3 is going to execute 2 steps (could be the same one twice, depending on the mapped key), when you PRESS the hotkey. NOTHING will happen when you RELEASE the hotkey, because the mapped key #2 has filtered it to ONLY do anything on Press (effectively filtering out the original Release event!). Likewise, if #2 was set to Release, #3 would execute 2 steps when you RELEASE the hotkey. And

Now this one
1. Hotkey with Hold does..
2. Mapped Key set to Pressed OR Released does..
3. Mapped Key set to Pressed OR Released
.. now #3 is going to execute 4 steps. Two when I press, and two when I release. That's because with the Hold option disabled, any press or release has to activate BOTH the press AND release of anything it does. So I press, #1 tells #2 to press, #2 tells #3 to press and release executing two steps. I release, #1 tells #2 to release, #2 tells #3 to press and release executing two steps.

But consider:
1. Hotkey with Hold does..
2. Mapped Key set to Hold does..
3. Mapped Key set to Pressed OR Released
.. Mapped Key 3 executes 1 step when Hotkey is pressed, and 1 step when Hotkey is released, because the middle Hold preserves the press/release events.

So as far as why it would execute multiple times, it's either something along those lines, or you're doing an Action twice and including the same Target in both.

Hope that helps. :)

Note: Virtualization does not affect any of the above, the same rules are applied -- the virtualization just switches which Mapped Key is in use, does not affect any press/hold. The hold/press options on the Mapped Key that gets virtualized does not even get checked, it's only the final Mapped Key in the virtualization that matters. (i.e. "Do My Virtual -> all" where My Virtual is "Some Spell" instead because of virtualization, the press/release option on "My Virtual" is irrelevant because the character will be using "Some Spell" mapped key in its place)

Return to Key Maps

Who is online

Users browsing this forum: No registered users and 0 guests