Docking Tunnel Length

Discussion and information relevant to creating special missions, new ships, skins etc.

Moderators: winston, another_commander

User avatar
Killer Wolf
---- E L I T E ----
---- E L I T E ----
Posts: 2278
Joined: Tue Jan 02, 2007 12:38 pm

Docking Tunnel Length

Post by Killer Wolf »

Was just thinking about the Hathor and related stuff - is there a point where the dock tunnel is too long? i.e.: When a ship launches, is that noted as when the ship leaves the dock model itself, and if so, how far doe sit travel in a straight line before considering a manoeuvre? Is there a change a ship might be halfway along the Hathor tunnel and decide it wants to turn left through a wall?
Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Re: Docking Tunnel Length

Post by Switeck »

Killer Wolf wrote: Wed Sep 13, 2023 12:43 pm
Is there a change a ship might be halfway along the Hathor tunnel and decide it wants to turn left through a wall?
That's not a change I recommend making, but I'm wanting to say I've seen a ship exit a Hathor station.
User avatar
Griff
Oolite 2 Art Director
Oolite 2 Art Director
Posts: 2483
Joined: Fri Jul 14, 2006 12:29 pm
Location: Probably hugging his Air Fryer

Re: Docking Tunnel Length

Post by Griff »

i don't think launching ships make any AI choices until they've gone a certain distance away from the dock towards the docking beacon, so i think if they had a really long tunnel to travel, they'd just go down it in a straight line until they've cleared the tunnel and its parent station by a certain distance before thinking what to do next,I remember EricW pointing out the prongs on the front of the blackmonk monestary causing the AI to delay making any choices until the ship was much further from the station than it would if the ship launched from a regular station but i can't remember what that distance was now, i'll see if i can find his post
User avatar
Killer Wolf
---- E L I T E ----
---- E L I T E ----
Posts: 2278
Joined: Tue Jan 02, 2007 12:38 pm

Re: Docking Tunnel Length

Post by Killer Wolf »

ta for the replies.
that was a typo, by the way, "is there a CHANCE" a ship would try and turn through a wall it was meant to say, lol.

cheers Griff - i had a look at a couple AIs but couldn't see anything relating to launching so i'm not sure at what point, eg, a Viper gets the Route1Patrol AI assigned/activated after it clears the station.
Also, given the Hathor/my new thing doesn't have a buoy/beacon i'm wondering if that will be a prob :-/

cheers
User avatar
Griff
Oolite 2 Art Director
Oolite 2 Art Director
Posts: 2483
Joined: Fri Jul 14, 2006 12:29 pm
Location: Probably hugging his Air Fryer

Re: Docking Tunnel Length

Post by Griff »

no i don't think it not having a beacon will make a difference, the ship just needs to fly directly out the docking bay for a certain distance before it starts thinking about its role and what it should do next
User avatar
Redspear
---- E L I T E ----
---- E L I T E ----
Posts: 2685
Joined: Thu Jun 20, 2013 10:22 pm
Location: On the moon Thought, orbiting the planet Ignorance.

Re: Docking Tunnel Length

Post by Redspear »

Observed many a ship launch from a main station while testing traffic for the rescaling experiment or beinng held in a queue.
My habit was always to observe from the side, letting traffic pass through my sights so I could ID each ship.

Don't think I've ever seen a vessel that didn't travel several times the length of the docking port away from the station prior to turning (often quite sharply). Would be surprised if you couldn't make it at least three times longer (my guess would be four).
Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Re: Docking Tunnel Length

Post by Switeck »

Griff wrote: Wed Sep 13, 2023 4:06 pm
no i don't think it not having a beacon will make a difference, the ship just needs to fly directly out the docking bay for a certain distance before it starts thinking about its role and what it should do next
If the buoy is really close to the docking port it might be a problem, such as within 5 times the length of the docking tunnel.

In earlier versions of Oolite, I've seen ships leave the main station and run into the buoy...but that problem's probably been solved since v1.77!
Alnivel
Dangerous
Dangerous
Posts: 100
Joined: Fri Jun 10, 2022 7:05 pm

Re: Docking Tunnel Length

Post by Alnivel »

If I haven't missed anything, according to the code, a delay between a ship launch and an AI start is about the time needed for the ship to fly past the station's bounding box plus two or three lengths of the dock subentity, so there is theoretically no limit for tunnel length, at least for launch, a ship shouldn't be able to decide to turn into a wall while inside a tunnel.

Delay calculation can be found in the line DockEntity.m:929.
User avatar
Killer Wolf
---- E L I T E ----
---- E L I T E ----
Posts: 2278
Joined: Tue Jan 02, 2007 12:38 pm

Re: Docking Tunnel Length

Post by Killer Wolf »

much obliged, @Alnivel.
User avatar
hiran
Theorethicist
Posts: 2403
Joined: Fri Mar 26, 2021 1:39 pm
Location: a parallel world I created for myself. Some call it a singularity...

Re: Docking Tunnel Length

Post by hiran »

Alnivel wrote: Thu Sep 14, 2023 4:08 am
If I haven't missed anything, according to the code, a delay between a ship launch and an AI start is about the time needed for the ship to fly past the station's bounding box plus two or three lengths of the dock subentity, so there is theoretically no limit for tunnel length, at least for launch, a ship shouldn't be able to decide to turn into a wall while inside a tunnel.

Delay calculation can be found in the line DockEntity.m:929.
That is a really cool hint. It looks to me more important to calculating the delay is to setLaunchDelay and setNextThinkTime on the launching ship - something that the dock probably does to the launching ship. Which does not yet fix problems for incoming ships.
Sunshine - Moonlight - Good Times - Oolite
Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Re: Docking Tunnel Length

Post by Switeck »

Switeck wrote: Wed Sep 13, 2023 1:51 pm
Killer Wolf wrote: Wed Sep 13, 2023 12:43 pm
Is there a change a ship might be halfway along the Hathor tunnel and decide it wants to turn left through a wall?
That's not a change I recommend making, but I'm wanting to say I've seen a ship exit a Hathor station.
Revisiting this, in the 'inner sanctum' of a Hathor station's docking tunnel, just before the "you just docked" animation would trigger you can run into invisible walls and die even at very slow speeds.
User avatar
Killer Wolf
---- E L I T E ----
---- E L I T E ----
Posts: 2278
Joined: Tue Jan 02, 2007 12:38 pm

Re: Docking Tunnel Length

Post by Killer Wolf »

not sure how that happens, the model should have the dock box where it should be. if you CAN dock there it surely means you're in far enough for the process to register and therefore sometimes [?] hitting something before it doesn't make sense?
User avatar
hiran
Theorethicist
Posts: 2403
Joined: Fri Mar 26, 2021 1:39 pm
Location: a parallel world I created for myself. Some call it a singularity...

Re: Docking Tunnel Length

Post by hiran »

Killer Wolf wrote: Mon Jan 08, 2024 5:05 pm
not sure how that happens, the model should have the dock box where it should be. if you CAN dock there it surely means you're in far enough for the process to register and therefore sometimes [?] hitting something before it doesn't make sense?
In the dock's code to generate docking instructions I saw a lot about queues for ships going in and out. Is it possible to collide with a ship that materializes while you are in there?

Would the logs not tell proof of what the collision happened with?
Sunshine - Moonlight - Good Times - Oolite
User avatar
Killer Wolf
---- E L I T E ----
---- E L I T E ----
Posts: 2278
Joined: Tue Jan 02, 2007 12:38 pm

Re: Docking Tunnel Length

Post by Killer Wolf »

having been blatted by exiting ships on occasion i can confirm very bad timing can sometimes end if your destruction - i've been metres from approach when a Viper materialised and i blew up a microsecond later. i think we need more details about this Hathor incident.
User avatar
hiran
Theorethicist
Posts: 2403
Joined: Fri Mar 26, 2021 1:39 pm
Location: a parallel world I created for myself. Some call it a singularity...

Re: Docking Tunnel Length

Post by hiran »

Killer Wolf wrote: Mon Jan 08, 2024 8:37 pm
having been blatted by exiting ships on occasion i can confirm very bad timing can sometimes end if your destruction - i've been metres from approach when a Viper materialised and i blew up a microsecond later. i think we need more details about this Hathor incident.
We need for wait for the report from the Stellar Transportation Safety Board.
Sunshine - Moonlight - Good Times - Oolite
Post Reply