Previous Thread
Next Thread
Print Thread
Rate This Thread
Hop To
#4069379 - 01/26/15 04:19 AM Order Key release  
Joined: Jan 2015
Posts: 2
Myoda Offline
Junior Member
Myoda  Offline
Junior Member

Joined: Jan 2015
Posts: 2
Hi guys,
In software "Target GUI", the key command release order don't match with pressed order.
when you press an key with modifier, the previous pressed keys should be released in the invert order.

For instance :

- Press Type : Pulse :
Key Press L_SHIFT (1)
Key Press L_CTL (2)
Key Press UARROW (3)
Key Release UARROW (3)
Key Release L_SHIFT (1)
Key Release L_CTL (2)


Order is : Press 1,2,3 - Release 3,1,2 (bad order)


- Press Type : Hold :
Key Press L_SHIFT (1)
Key Press L_CTL (2)
Key Press UARROW (3)
Key Release L_SHIFT (1)
Key Release L_CTL (2)
Key Release UARROW (3)

Order is : Press 1,2,3 - Release 1,2,3 (bad order)


- Press Type : Hold and Pulse : (Wanted solution)
Key Press L_SHIFT (1)
Key Press L_CTL (2)
Key Press UARROW (3)
Key Release UARROW (3)
Key Release L_CTL (2)
Key Release L_SHIFT (1)

order is : Press 1,2,3 - Release 3,2,1 (good order)

The problem is that in Falcon BMS, the Key command order is important. Otherwise in the simulator, the action key pressed are not released

How can i correct this ?
Thank you all for reading and helps.

Last edited by Myoda; 01/26/15 04:20 AM.
Inline advert (2nd and 3rd post)

#4069424 - 01/26/15 09:36 AM Re: Order Key release [Re: Myoda]  
Joined: Oct 2010
Posts: 83
Nicu Offline
Junior Member
Nicu  Offline
Junior Member

Joined: Oct 2010
Posts: 83
If the key order is important, you need to create a chain, which will preserve the order.
Code:
MapKey(&Joystick, S2, CHAIN( DOWN+L_SHIFT, DOWN+L_CTL, DOWN+UARROW, D(), UP+UARROW, UP+L_CTL, UP+L_SHIFT));

This code simulates an UARROW pulse when you press S2.
If you are using GUI, you can also create a chain of 6 events which will generate the above MapKey (you can verify by using <ViewScript> button).

For HOLD, you will create 2 chains of 3 events each, one for press and one for release.

#4069450 - 01/26/15 11:50 AM Re: Order Key release [Re: Nicu]  
Joined: Jan 2015
Posts: 2
Myoda Offline
Junior Member
Myoda  Offline
Junior Member

Joined: Jan 2015
Posts: 2
Yes you are right !
That was what i'm thinking about. But in this solution in Target GUI, you must create 6 évents. This one increase the risk to create parasitic effect !
Thank for your reply.

#4085454 - 02/28/15 04:34 PM Re: Order Key release [Re: Myoda]  
Joined: Mar 2007
Posts: 483
Aullido Offline
Member
Aullido  Offline
Member

Joined: Mar 2007
Posts: 483
You can then use LOCK for ensure the complete chain is done first or maybe use UP/DOWN to coordinate the release order.


Moderated by  RacerGT 

Quick Search
Recent Articles
Support SimHQ

If you shop on Amazon use this Amazon link to support SimHQ
.
Social


Recent Topics
Dickey Betts was 80
by Rick_Rawlings. 04/19/24 01:11 AM
Exodus
by RedOneAlpha. 04/18/24 05:46 PM
Grumman Wildcat unique landing gear
by Coot. 04/17/24 03:54 PM
Peter Higgs was 94
by Rick_Rawlings. 04/17/24 12:28 AM
Whitey Herzog was 92
by F4UDash4. 04/16/24 04:41 PM
Anyone can tell me what this is?
by NoFlyBoy. 04/16/24 04:10 PM
10 Years ago MV Sewol
by wormfood. 04/15/24 08:25 PM
Pride Of Jenni race win
by NoFlyBoy. 04/15/24 12:22 AM
It's Friday: grown up humor for the weekend.
by NoFlyBoy. 04/12/24 01:41 PM
OJ Simpson Dead at 76
by bones. 04/11/24 03:02 PM
Copyright 1997-2016, SimHQ Inc. All Rights Reserved.

Powered by UBB.threads™ PHP Forum Software 7.6.0