To do this, I m listening SIGNAL_CHANGESECTOR.
As I experiment, this signal is also fired when ship undock from a station. So I listen to the SIGNAL_DOCKED to keep track of my ship "docking state" to sort out between station undocking and actual move from a sector to another.
But, I m also looking to sort out jumpgate uses from jumpdrive use and that the point where I m stuck. Does any one of you ever experiment with this?
Is the jumpdrive use (shif+J) basicaly a short cut to the navigation command "jump to sector"? I try to experiment with it but it didn't show anything. What I tried is :
Code: Select all
$targetShip->remove secondary signal: signal={COMMAND_JUMP_SECTOR}, name='onJumping'
$targetShip->add secondary signal: signal={COMMAND_JUMP_SECTOR}, script='plugin.crew.signal.ship.jumping', prio=5, name='onJumping'
Code: Select all
$objectName = [THIS]->get name
$scriptName = get script name
$msg = $objectName + ' calling ' + $scriptName
write to player logbook $msg
Some idea?