Previous Thread
Next Thread
Print Thread
Rate This Thread
Hop To
#3123368 - 10/25/10 04:42 PM Is there a T.A.R.G.E.T. equivalent to Foxy's "RPT"?  
Joined: Apr 2002
Posts: 17,733
Joe Offline
Veteran
Joe  Offline
Veteran

Joined: Apr 2002
Posts: 17,733
Bridgewater, NJ
Note: sorry for what this post does to browser width...

The "RPT" (repeat) command in Foxy was good for telling the controller to peform an action or series of actions multiple times in quick succession. For example, for Jane's F-18 I had my TG1 button programmed as follows:

Code:
BTN TG1 /U /I Guns_Select
           /O /H DX1
        /M /I Guns_Select 
           /O /H DX1
        /D /I Master_Arm_toggle DLY(60) AWACS_Go_Tactical DLY(60) Gun_Rate_toggle DLY(60) Zoom_RMDI DLY(60) Right_MDI_PB_18 DLY(60) Right_MDI_PB_4 DLY(60) Right_MDI_PB_16 DLY(60) Radar_Silent_toggle DLY(60) TAB DLY(60) 4 DLY(60) 2 DLY(60 ) Zoom_MPCD DLY(60) MPCD_PB_6 DLY(60) MPCD_PB_8 DLY(60) MPCD_PB_15 DLY(60) MPCD_PB_17 DLY(60) MPCD_PB_20 DLY(60) Zoom_UFC DLY(60) UFC_CNI DLY(60) BARO/RDR_ALT DLY(60)  UFC_AP DLY(60) UFC_AP_CPL DLY(1000) DLY(60) View_Forward  DLY(60) RPT (8) ( BINGO- DLY (120)) Select_Center_Station RPT(3) ( Rotate_Jett_Select_Knob DLY(120))   Wheel_Brakes DLY(3000) UFC_CNI
           /O NAVFLIR_Mode


There are two RPT statements in there; the first sends the BINGO- command 8 times, and the other sends the Rotate_Jett_Select_Knob command 3 times. To do this in T.A.R.G.E.T. I have to write each one out, which makes the already-long line much longer:

Code:
MapKeyIOUMD(&Joystick, TG1,
	PULSE+Guns_Select,
	DX1,
	PULSE+Guns_Select,
	DX1,
	CHAIN(Master_Arm_toggle, D(60), AWACS_Go_Tactical, D(60), Gun_Rate_toggle, D(60), Zoom_RMDI, D(60), Right_MDI_PB_18, D(60), Right_MDI_PB_4, D(60), Right_MDI_PB_16, D(60), Radar_Silent_toggle, D(60), TAB, D(60), 4, D(60), 2, D(60), Zoom_MPCD, D(60), MPCD_PB_6, D(60), MPCD_PB_8, D(60), MPCD_PB_15, D(60), MPCD_PB_17, D(60), MPCD_PB_20, D(60), Zoom_UFC, D(60), UFC_CNI, D(60), BARO_RDR_ALT, D(60), UFC_AP, D(60), UFC_AP_CPL, D(1000), View_Forward, D(60), BINGO_minus, D(120), BINGO_minus, D(120), BINGO_minus, D(120), BINGO_minus, D(120), BINGO_minus, D(120), BINGO_minus, D(120), BINGO_minus, D(120), BINGO_minus, D(120), Select_Center_Station, Rotate_Jett_Select_Knob, D(120), Rotate_Jett_Select_Knob, D(120), Rotate_Jett_Select_Knob, D(120), Wheel_Brakes, D(3000), UFC_CNI), // pre-flight checklist
	NAVFLIR_Mode);


So, can T.A.R.G.E.T. mimic Foxy's "RPT"?

Inline advert (2nd and 3rd post)

#3123422 - 10/25/10 06:00 PM Re: Is there a T.A.R.G.E.T. equivalent to Foxy's "RPT"? [Re: Joe]  
Joined: Sep 2010
Posts: 104
Dimebug Offline
Member
Dimebug  Offline
Member

Joined: Sep 2010
Posts: 104
France
First with Target, you can jump to the next line between each event, it makes reading much more comfortable :-)

This could be done several ways, but the good one really depends of what you really want to achieve or how the virtual button is controlled.

Theres no simple way to reproduce this repeat, at least yet. As a repeat function already exist, TM could modify it and add a number of repeat parameter.

But yet with Target, you have the opportunity to create functions.

Functions can be complicated stuff or simples keystrokes.

Some solutions:

Create 2 functions that contains the multiple repeated order, then call those functions inside my CHAIN. The function act like a shortcut to a sub CHAIN. This can makes reading easier.
This is interesting if you use that chain several times in the file.

Create a function that repeat linked to a counter, the counter order the stop. Harder to write but possible.

Create a function that index each position of the virtual rotary button, or create a function per position.

that's just some possible solutions, but i think TM can simply add an optional counter to the REXEC statement




Last edited by Dimebug; 10/25/10 06:02 PM.

Guillaume "Dimebug" Leleve

Moderated by  RacerGT 

Quick Search
Recent Articles
Support SimHQ

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


Recent Topics
Actors portraying US Presidents
by PanzerMeyer. 04/19/24 12:19 PM
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
Copyright 1997-2016, SimHQ Inc. All Rights Reserved.

Powered by UBB.threads™ PHP Forum Software 7.6.0