this is for the actual mod not the lite version I will work on tomorrow. I think that the first one will create the hotkeys, the second one will make a flag, and the third one will read the flag and give the order to the appropriate wing
with this one I would just add more to it for each hotkey
Code: Select all
setup.qw.register
001 $blue = get global variable: name='qw.blue'
002 if not $blue ...
003 $blue= register hotkey 'Select Blue wing' to call script qw.blue
004 set global vairiable: name='wc.baction' value=$blue
005 end
i'll need one of these for each wing
Code: Select all
qw.blue
001 set global variable: name= 'qw_flag' value='blue'
002 end
Code: Select all
qw.action
001 $target = get player tracking aim
002 $wing = get global variable 'qw_flag'
003 if $wing = 'blue'
004 $Wing = get predefined wing: wing=[Wing.Blue]
005 $Wing.Ships = get flight wing ship array: wing=$Wing
006 $Ship = $Wing.Ships[0]
(at this point I could add several 'else if' for each additional wing, right?)
007 end
008 If $target = ship or station and enemy
009 $ship -> call script 'attack my target'
010
011 Else if $target = ship or station and not enemy
012 $ship -> call script 'protect my target'
013
014 Else
015 $ship -> call script 'protect me'
016 end