Character won't stop immediately w{WAITMS:2000}r

x64 Replacement/Alternative to Microsoft's IntelliMouse application.
Forum rules
Please read the forum rules before posting for the first time.
The more information you can provide, the quicker and more accurately someone can help.
NOTE: To reduce spam, new users can not post links, files or images until they have at least 4 posts.
Post Reply
sadiq3210
New User
Posts: 2
Joined: Thu Jun 17, 2021 12:58 am

Character won't stop immediately w{WAITMS:2000}r

Post by sadiq3210 »

XMBC Version: v2.19.2
Windows Version: windows 10 64 bit
Mouse Information (brand/model): boblen M5, Made in China
Relevant Computer Information (CPU, RAM etc): Intel, 8
Did the problem occur after an upgrade of XMBC? (If so, from what version?): no
Did the problem occur after a Windows update/upgrade? (If so, from what version?): no
How long have you used XMBC?: recently installed again
What language and keyboard layout do you use in Windows?: english, US

Clear description of the problem - try and include as much information as possible, including what button and mappings you are having problems with (if applicable).: I am trying to walk a character in a game while reloading weapon and keep walking.

here is what i want to do.
Upon mouse wheel up once, it should press W button and keep press it;
after 100 millisecond, it press R button while W is kept pressed;
upon mouse wheel up again, the W key should release and character stop walking immediately.
upon mouse scroll up again the whole sequence should be repeated.

here is what i set:
On layer 1, select mouse wheel up to Simulated keys with custom key "w{WAITMS:2000}r"
and send simulated key stroke as 9 Sticky (held down until button is pressed again)
layer 2 is untouched
in options tab ignore repeated remapped vertical scroll.

the problem is character wont stop immediately. it stops after a delay. Any suggestion or work around? by the way scroll down is unassigned.
User avatar
phil
Site Admin
Posts: 7627
Joined: Sun Apr 06, 2003 11:12 pm

Re: Character won't stop immediately w{WAITMS:2000}r

Post by phil »

The way XMBC currently works, when it sends the keystrokes (on the first press) it does so in a background thread.
If another keystroke sequence comes in (or in this case, a release key) it adds that the the queue for the background thread to process. The background thread is NOT interrupted or stopped - the wait, and any preceding keys will still be honored. There is no way around this that I can think of without a radical redesign to the way it sends keys, and that's not likely at the current time.

Regards,
Phil
--[ Phil ]--
--[ Administrator & XMBC Author ]--
Logitech G9/G604/M720/MX518, Microsoft Intellimouse, Trust 16341 BT Mouse
Windows 10 x64, AMD Ryzen 5900x, MSI x570 Tomahawk, 32GB DDR4,
nVidia RTX 2070s, Evo 970 1Tb NVME, 2x2TB WD Black (RAID1)
sadiq3210
New User
Posts: 2
Joined: Thu Jun 17, 2021 12:58 am

Re: Character won't stop immediately w{WAITMS:2000}r

Post by sadiq3210 »

phil wrote: Thu Jun 17, 2021 9:34 am The background thread is NOT interrupted or stopped - the wait, and any preceding keys will still be honored.
Thanks phil for reply.
Is it possible to stop the queue using an independent simulated key, like mouse wheel down to stop the character immediately?
User avatar
phil
Site Admin
Posts: 7627
Joined: Sun Apr 06, 2003 11:12 pm

Re: Character won't stop immediately w{WAITMS:2000}r

Post by phil »

Any other button or physical key can stop the simulated keystroke - although it probably still plays out the current sequence - I think it just clears the queue so no more queued entries will execute. If one is executing "right now" it wont stop it in its tracks, it cant stop it in its tracks because it has to leave the keyboard in the correct state, that is, if you have presses S and are waiting, you cant stop it completely, you have to release s.

I think I will need to change it to be able to cancel out of the {WAIT} commands, but even then it will still have to complete the sequences (ignoring any waits) to be sure the keyboard is left in the correct state with no stuck keys.
--[ Phil ]--
--[ Administrator & XMBC Author ]--
Logitech G9/G604/M720/MX518, Microsoft Intellimouse, Trust 16341 BT Mouse
Windows 10 x64, AMD Ryzen 5900x, MSI x570 Tomahawk, 32GB DDR4,
nVidia RTX 2070s, Evo 970 1Tb NVME, 2x2TB WD Black (RAID1)
Post Reply