Code: Select all
$target = get player tracking aim
$flag = get global variable: name='qw_flag'
$Wing = get predefined wing: wing=$flag
$wing.ships = get flight wing ship array: wing=$Wing
$ship = $wing.ships[0]
if $target-> is [PLAYERSHIP] a enemy
$ship = [THIS]-> call script '!wing.ship.attack.pck' :
else if $target-> is [PLAYERSHIP] a friend
$ship = [THIS]-> call script '!ship.cmd.protect.std' : target=$target stopifleaderdocked=[FALSE]
else
$ship = [THIS]-> call script '!ship.cmd.protect.std' : target=[PLAYERSHIP] stopifleaderdocked=[FALSE]
end
return null
but nothing happens. I think the problem is in scripts i am calling (maybe). I also tried writing a script to test the protect script it was some thing like
Code: Select all
$target = get player tracking aim
$target= [THIS]-> call script '!ship.cmd.protect.std' : target=[playership] stopifleaderdocked=[FALSE]