[SCR] Docking Lockup Fix + Upgrade (v6 - 13.06.09)

The place to discuss scripting and game modifications for X³: Terran Conflict and X³: Albion Prelude.

Moderators: Moderators for English X Forum, Scripting / Modding Moderators

7ate9tin11s
Posts: 813
Joined: Fri, 11. Nov 05, 23:18
x4

Post by 7ate9tin11s » Mon, 8. Jun 09, 10:46

Very nice, was just about to toss something like this together myself. I prefer carrier fleets and the stuck 1km away and will not fly in problem was getting on my nerves. Plus this has the bonus of letting everyone dock quicker after combat :D

User avatar
Gazz
Posts: 13244
Joined: Fri, 13. Jan 06, 16:39
x4

Post by Gazz » Sat, 13. Jun 09, 13:22

Version 6 released.

Corrected a typo. (rather an oddity of the script editor)

Since noone noticed so far, it didn't have any noticable effect anyway. =)
My complete script download page. . . . . . I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.

Scoob
Posts: 9921
Joined: Thu, 27. Feb 03, 22:28
x4

Post by Scoob » Sun, 2. Aug 09, 02:37

Hi Gazz,

I'm using this script along with the Transcend II mod and while it generally works great in certain situations it gets confused. I'll try to explain...

The Trancend mod gives some ships both internal and external docking bays - the external intended for TS and larger ships. However with the docking fix running these externally docking ships elect to dock internally.

If the ship in question only has external docks then it works fine.

I know you wrote your script for vanilla TC but is this something fixable so it works with Transcend II and other mods which allow larger ships to dock externally?

Cheers,

Scoob.

User avatar
Gazz
Posts: 13244
Joined: Fri, 13. Jan 06, 16:39
x4

Post by Gazz » Sun, 2. Aug 09, 03:27

Try removing the docking computer from your big ships.

And what is the problem anyway?
You said that the ships dock. Internally, externally - docked is docked.
You're not describing a problem.
My complete script download page. . . . . . I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.

User avatar
ThomasAH
Posts: 147
Joined: Wed, 3. Sep 08, 10:46
x4

Post by ThomasAH » Sun, 2. Aug 09, 09:41

Gazz wrote:Try removing the docking computer from your big ships.

And what is the problem anyway?
You said that the ships dock. Internally, externally - docked is docked.
You're not describing a problem.
Hmm, maybe this explains the problems with the Hangarmod I experienced:
The TS docked internally at the TL where it should have docked externally. When jumping into the TS I got effects as known for beamdock and LV's Dock TS, i.e. being lost somewhere between the stars.
(maybe it was caused by something completely different, but I'm no longer using Hangarmod and I'm happy enough with beamdock to not miss it :))

Scoob
Posts: 9921
Joined: Thu, 27. Feb 03, 22:28
x4

Post by Scoob » Sun, 2. Aug 09, 11:15

Hi,

Yes, removing the docking computer would fix the issue of course. I just found it odd that the ship will insist on docking internally but with vanilla it will dock externally correctly. I guess there must be some extra check or something in vanilla so the docking ship choses an appropriate docking point.

Like you say docked is docked, however undocking = boom for these large internal dockers...sorta like trying to pass a whole watermelon I'd imagine...ouch.

Cheers,

Scoob.

bennyg
Posts: 38
Joined: Wed, 13. Sep 06, 12:55

Post by bennyg » Tue, 18. Aug 09, 07:31

Nice one mate, this bug has (well... had !! :) ) led to multiple ship losses, mostly in X3R:XTM (where it was horrible) but have also seen it happen in TC.

Hope egosoft paid you to do their work for them. Great game + rubbish QC = :evil: :evil: :evil: :evil:

User avatar
Gazz
Posts: 13244
Joined: Fri, 13. Jan 06, 16:39
x4

Post by Gazz » Tue, 18. Aug 09, 09:32

Scoob wrote:Like you say docked is docked, however undocking = boom for these large internal dockers...sorta like trying to pass a whole watermelon I'd imagine...ouch.
Well, noone mentioned any ships getting destroyed. Only that there would be some vague "problem".

Alas, scripts can not tell if an object has multiple types of hangars.
Only if ship A is physically able to dock at object B and if object B has a matching docking slot free. This is just an overall total of all available docking bays.
Since the script can only use put into environment to fake-dock the ship it can not tell what kind of docking slot the ship is actually put in.

So this problem is unavoidable with objects that can dock more than one ship class. There is no way for a script to detect this situation.

For 99% of vanilla X3 this script should be perfectly safe. Worst case a TS tries to undock from the internal hangar of an argon trading station or somesuch...


Hmmm. However...
What if every ship in the game were invulnerable when undocking until it had traveled 200m + it's own ship length.
It would still not be perfect in some situations but maybe...
My complete script download page. . . . . . I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.

Anticept
Posts: 143
Joined: Sat, 18. Mar 06, 04:47
x4

Post by Anticept » Wed, 19. Aug 09, 20:12

You were saying it would be silly to instantly dock across 24km of open space, I suppose you could look at it this way gazz: In eve you can dock with some stations from a HUGE unrealistic distance due to massive docking radii. However, there's a bit of RP they put in, when you dock, a message comes up saying "Your ship will be TOWED into station"

Applying this to your script could make large docking more feasible from a roleplay point of view.

By the way, is the flight paths hard coded for undocking? It would really help if the ships would dock facing OUTWARDS rather than inwards, it would allow them to launch away from the station rather into each other.
Signature.

User avatar
ThomasAH
Posts: 147
Joined: Wed, 3. Sep 08, 10:46
x4

Post by ThomasAH » Fri, 21. Aug 09, 09:01

Gazz wrote:
Scoob wrote:Like you say docked is docked, however undocking = boom for these large internal dockers...sorta like trying to pass a whole watermelon I'd imagine...ouch.
Well, noone mentioned any ships getting destroyed. Only that there would be some vague "problem".
I do not have problems with ships being destroyed, only with being sent into the void when trying to fly the docked the TS myself.
It looks like I am outside and the ship still is landed (internally). After that I can only restart TC.

But I tried replacing this script with the original script files from the DVD and for me it behaved identically, so I think it is a different script that causes this (for me).

But your idea with turning of collisions while undocking might be a good thing anyway.

User avatar
Gazz
Posts: 13244
Joined: Fri, 13. Jan 06, 16:39
x4

Post by Gazz » Fri, 21. Aug 09, 14:03

ThomasAH wrote:I do not have problems with ships being destroyed, only with being sent into the void when trying to fly the docked the TS myself.
It looks like I am outside and the ship still is landed (internally). After that I can only restart TC.
I don't think that this script is responsible because it always aborts the "auto docking" when used on the playership.

But your idea with turning of collisions while undocking might be a good thing anyway.
Yah, but it's only an idea and leads to... different issues. =)
A TS undocking from a complex needs to fly away from it. With collisions off it would not evade the complex hub but directly fly away from the docking clamps ignoring the hub structure.
So it might just as easily fly straight through the hub or another station... at which point the collision avoidance would come back on and it turns into a pretty but brief fireball.

So while the idea itself has merit, it will take a lot of brain sweat to secure it against all possible eventualities and turn it into a working concept.
My complete script download page. . . . . . I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.

paulms1980
Posts: 933
Joined: Fri, 5. Mar 04, 17:23
x3tc

Post by paulms1980 » Thu, 15. Oct 09, 10:16

hey gazz will this script stil work when using 2.5?

Mystery00
Posts: 57
Joined: Sun, 27. Dec 09, 07:41
x3tc

Post by Mystery00 » Sun, 27. Dec 09, 07:44

Unfortunately I still get the lockups when trying to dock with my Magnetar. It doesn't happen as often(maybe?) but it still happens enough to be annoying.

Also sometimes the ship will try to fly through the Magnetar while trying to get to the docking "lane", dying in the process.

Thanks for trying though.

It docks at stations just fine strangely. How difficult would it be to simply make the ship appear inside the Magnetar once it gets within 500m or so?

User avatar
Gazz
Posts: 13244
Joined: Fri, 13. Jan 06, 16:39
x4

Post by Gazz » Sun, 27. Dec 09, 13:09

That's all the "docking computer upgrade" does so if you give your ship one...

Doesn't work properly, though. Since the ship does not land, it cannot know where it would have landed. So it doesn't show up on ships with external docking like a TM.
Also, an M1 using this DC doesn't know, either. It may try to launch from small docking clamps or even an internal hangar...
My complete script download page. . . . . . I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.

Mystery00
Posts: 57
Joined: Sun, 27. Dec 09, 07:41
x3tc

Post by Mystery00 » Sun, 27. Dec 09, 13:59

Buying docking computers for all ships I want to land on my Magnetar is a bit of a silly workaround for a stupid game design decision.

From a programming point of view they should fix the bug that causes this, but from a design point of view the bug shouldn't be there in the first place because it doesn't desperately need to show that tiny landing "animation".

Also the vanilla scripts don't use the docking computer when auto-docking.

I think my point is that the best solution to the docking problem is to simply not do a complete docking simulation; magically teleporting into the docking bay when 200m from the Magnetar will not only completely fix the whole docking issue forever, but it won't even be noticeable.

User avatar
Argonaught.
Posts: 1827
Joined: Wed, 6. Nov 02, 20:31
x4

Post by Argonaught. » Sun, 27. Dec 09, 15:00

Can the script be altered to allow the playership to autodock when in range and has a docking computer installed?

Would be interested in a script that could do that while on auto pilot to a station to save all those key presses...I'm a bit lazy while flying around when not in combat.
[MOD]X3TC No Fog / [MOD]X3AP No Fog / [MD]X3TC Menagerie Shipyard / [MD]X3AP Menagerie Shipyard
<==<<Argonaught>>==>

XBTF>XT>X2TT>X3R>X3TC>X3AP>X4F

I lurk alot for the most part now
:thumb_up:

User avatar
Gazz
Posts: 13244
Joined: Fri, 13. Jan 06, 16:39
x4

Post by Gazz » Sun, 3. Jan 10, 00:46

Argonaught. wrote:Can the script be altered to allow the playership to autodock when in range and has a docking computer installed?
No.
My complete script download page. . . . . . I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.

BlitzIn4
Posts: 21
Joined: Mon, 1. Feb 10, 02:25
x3tc

Post by BlitzIn4 » Sun, 7. Mar 10, 00:10

Mystery00 wrote:Unfortunately I still get the lockups when trying to dock with my Magnetar. It doesn't happen as often(maybe?) but it still happens enough to be annoying.

Also sometimes the ship will try to fly through the Magnetar while trying to get to the docking "lane", dying in the process.

Thanks for trying though.

It docks at stations just fine strangely. How difficult would it be to simply make the ship appear inside the Magnetar once it gets within 500m or so?
I had the same issue, but not with Gazz's mod. In vanilla, if you order a ship to dock with your Magnetar that's too close to a station, that ship will either freeze right next to it, or make several fly-by's before it gives up and freezes.

User avatar
Lord Dakier
Posts: 3243
Joined: Fri, 8. Dec 06, 13:45
x4

Post by Lord Dakier » Sun, 7. Mar 10, 01:18

Gazz I hope your sending this to be signed as it really needs to be.

How does this react with 5 ships surrounding the carrier? I have some thought that it would be like the assassination missions where the larger ships appear as they have jumped out the sector.

LucidSurreality
Posts: 4
Joined: Fri, 23. Apr 10, 22:00
x3tc

Post by LucidSurreality » Wed, 19. May 10, 20:45

This script is fantastic; the lack of AI docking computer use was one of the first things I noticed, and I'm glad you found a solution. As mentioned previously, it doesn't seem to work with CLS/CAGs due to their unique travel routines. I haven't delved into editing yet, but I was wondering how difficult it would be if I wanted to enable them to utilize the docking computer. Would it be as simple as copy/pasting some code from this into those scripts?

Post Reply

Return to “X³: Terran Conflict / Albion Prelude - Scripts and Modding”