Hello,
Got some (97%) working code now. Sorry it took a while. Lot's of other stuff I had to do at home

I still (only) have some POV-issues left, and my C is lacking the knowhow. I posted on several sites, and expect an answer soon (I hope)
Here is one site I swamped with code and question about the POV..
http://cboard.cprogramming.com/game-programming/162353-programming-t-r-g-e-t-uses-c.htmlIf any C expert(s) want to help out? Please click on the link and read the issue? I am sure there is C-code to solve the POV-issues (I got two, and one of them looks simple if you know your C ), My C logic is at flaw here... 'almosts' do not work in C, lol..
Maybe I will program the two sliders I haven't done anything with yet too soon. Not sure if they are handy in case I don't get my POV issues resolved. I guess they might ...
I will leave the code on page one here unaltered, because it explaines the following code a lot. Too much work to integrate page-1-stuff in the following. It kinda speaks for itself.
include "target.tmh"
include "Macros_test1.ttm"
alias T16001; // second T16000 handle, which will be used all mapping commands
//program startup
int main()
{
if(Init(&EventHandle)) return 1; // declare the event handler, return on error
&T16001 = GetIndexJoy (SelectUsbDevice ("VID_044F&PID_B10A"));
//right one
MapAxis(&T16000, JOYX, DX_X_AXIS, AXIS_NORMAL, MAP_ABSOLUTE);
MapAxis(&T16000, JOYY, DX_Y_AXIS, AXIS_NORMAL, MAP_ABSOLUTE);
SetCustomCurve(&T16000, JOYY, LIST (0,100, 25,75, 50,50, 75,75, 100,100)); //this little trick lets you use thrusters at both the push and the pull , cause the stick is now programmed to do this if I am correct, lol
KeyAxis(&T16000, JOYY, 0, AXMAP2 (3, USB[0x4B], 0, USB[0x4E])); //PGUP & PGDN
MapAxis(&T16000, RUDDER, DX_Z_AXIS, AXIS_NORMAL, MAP_ABSOLUTE);
KeyAxis(&T16000, RUDDER, 0, AXMAP2 (3, USB[0x52], 0, USB[0x51])); //'UARROW',0 , 'DARROW'
//left one
MapAxis(&T16001, JOYX, DX_XROT_AXIS, AXIS_NORMAL, MAP_ABSOLUTE);
KeyAxis(&T16001, JOYX, 0, AXMAP2 (3, USB[0x50], 0, USB[0x4F])); //'LARROW', 'RARROW'
MapAxis(&T16001, JOYY, DX_YROT_AXIS, AXIS_NORMAL, MAP_ABSOLUTE);
MapAxis(&T16001, RUDDER, DX_ZROT_AXIS, AXIS_NORMAL, MAP_ABSOLUTE);
// everything behind two of these is ignored by the program T.A.R.G.E.T.
//this second (right) POV is not seen at all, need to ask about it to smart people...
//MapKey(&T16000, H1U, Match_Target_Speed);
//MapKey(&T16000, H1R, Toggle_Gliding);
//MapKey(&T16000, H1D, Launch_Countermeasures);
//MapKey(&T16000, H1L, Afterburners);
MapKey(&T16000, TS1, Fire_Primary_Weapon);
MapKey(&T16000, TS2, L_SHIFT);
MapKey(&T16000, TS3, L_ALT);
MapKey(&T16000, TS4, Cycle_Forward_Primary_Weapon);
MapKey(&T16000, B5, Rearm_Me);
MapKey(&T16000, B6, Augment_Forward_Shield);
MapKey(&T16000, B7, Equalize_Energy);
MapKey(&T16000, B10, Disarm_My_Target);
MapKey(&T16000, B9, Attack_My_Target);
MapKey(&T16000, B8, Capture_My_Target);
MapKey(&T16000, B13, Ignore_My_Target);
MapKey(&T16000, B12, Communication_Menu);
MapKey(&T16000, B11, Toggle_Auto_Speed_Matching);
MapKey(&T16000, B14, Engage_the_Enemy);
MapKey(&T16000, B15, Cover_Me);
MapKey(&T16000, B16, Return_To_Base);
MapKey(&T16001, H1U, Center_View);
MapKey(&T16001, H1R, View_Right);
MapKey(&T16001, H1D, View_Rear);
MapKey(&T16001, H1L, View_Left);
MapKey(&T16001, TS1, Fire_Secondary_Weapon);
MapKey(&T16001, TS2, L_SHIFT);
MapKey(&T16001, TS3, Cycle_Secundary_Weapon_Bank);
MapKey(&T16001, TS4, Target_Next_Closest_Hostile_Ship);
MapKey(&T16001, B11, Target_Ship_In_Reticle);
MapKey(&T16001, B12, Target_subsystem_In_Reticle);
MapKey(&T16001, B13, Target_Targets_Nearest_Attacker);
MapKey(&T16001, B16, Toggle_Auto_Targeting);
MapKey(&T16001, B15, Target_Last_Ship_That_Transmitted);
MapKey(&T16001, B14, Target_Next_Live_Turret);
MapKey(&T16001, B7, Target_Next_Ship);
MapKey(&T16001, B6, Decreaee_View_Distance);
MapKey(&T16001, B5, Increase_View_Distance);
MapKey(&T16001, B8, Target_Closest_Friendly_Ship);
MapKey(&T16001, B9, Cycle_Radar_Range);
MapKey(&T16001, B10, Target_Newest_ship_In_Area);
}
//event handler
int EventHandle(int type, alias o, int x)
{
DefaultMapping(&o, x);
//add event handling code here
}
and here the Macros_test1.ttm code
//T16001 POV, left one
define Center_View '1'
//define View_Up '2'
define View_Right '3'
//define Free_Look '4'
define View_Rear '5'
//define External_View '6'
define View_Left '7'
//define Current_Target_View '8'
//even ones are in-betweens, and not seen as seperates ones yet, but as both ones neighbouring it. asked about it... no reply yet.
define Fire_Secondary_Weapon '9'
define Cycle_Secundary_Weapon_Bank 'm'
define Target_Next_Closest_Hostile_Ship 'r'
define Target_Ship_In_Reticle 'q'
define Target_subsystem_In_Reticle 'w'
define Target_Targets_Nearest_Attacker 'e'
define Toggle_Auto_Targeting 'a'
define Target_Last_Ship_That_Transmitted 's'
define Target_Next_Live_Turret 'd'
define Target_Next_Ship 't'
define Decreaee_View_Distance 'y'
define Increase_View_Distance 'u'
define Target_Closest_Friendly_Ship 'f'
define Cycle_Radar_Range 'g'
define Target_Newest_ship_In_Area 'h'
//this POV not seen at all...
//define Match_Target_Speed KP1
//define Toggle_Gliding KP3
//define Launch_Countermeasures KP5
//define Afterburners KP7
define Fire_Primary_Weapon KP9
define Cycle_Forward_Primary_Weapon '0'
define Rearm_Me 'i'
define Augment_Forward_Shield 'o'
define Equalize_Energy 'p'
define Disarm_My_Target 'z'
define Attack_My_Target 'x'
define Capture_My_Target 'c'
define Ignore_My_Target 'j'
define Communication_Menu 'k'
define Toggle_Auto_Speed_Matching 'l'
define Engage_the_Enemy 'v'
define Cover_Me 'b'
define Return_To_Base 'n'