Ships with subentities and collision detection bug fixed

For test results, bug reports, announcements of new builds etc.

Moderators: winston, another_commander, Getafix

User avatar
DaddyHoggy
Intergalactic Spam Assassin
Intergalactic Spam Assassin
Posts: 8515
Joined: Tue Dec 05, 2006 9:43 pm
Location: Newbury, UK
Contact:

Post by DaddyHoggy »

Thargoid wrote:
I'm not sure quite how easy that will actually be to do.

The current NPC ship AI (and indeed the whole NPC use of fuel stations) is Eric's update to my original, and from my neophyte AI skills it would be a less than trivial issue to detect when the station actually has a ship inside it before the AI tells the NPC ship to go in itself.
Shouldn't normal ship-to-ship collision detection kick in? Or is this suspended because you're effectively colliding with something that doesn't have a centre to collide with?
Selezen wrote:
Apparently I was having a DaddyHoggy moment.
Oolite Life is now revealed here
User avatar
Eric Walch
Slightly Grand Rear Admiral
Slightly Grand Rear Admiral
Posts: 5536
Joined: Sat Jun 16, 2007 3:48 pm
Location: Netherlands

Post by Eric Walch »

DaddyHoggy wrote:
Thargoid wrote:
I'm not sure quite how easy that will actually be to do.
Shouldn't normal ship-to-ship collision detection kick in? Or is this suspended because you're effectively colliding with something that doesn't have a centre to collide with?
It won't be too difficult. Now it heads for the fuel station. When close it enters the "ENTER_RING" state. Just stick a state in between that checks if the station is free (distance player<->target more than XX). And stay in that loop until free.

It needs an extra script being attached to the shipscript. But there is already one attached, so it just means copy&paste (and alter the copy)
User avatar
Commander McLane
---- E L I T E ----
---- E L I T E ----
Posts: 9520
Joined: Thu Dec 14, 2006 9:08 am
Location: a Hacker Outpost in a moderately remote area
Contact:

Post by Commander McLane »

Alternatively, couldn't the fuel station send a message as long as a customer is being served? The check for distance to the player would only work fo prevent collisions with, well, the player. What about two NPCs wanting to enter the fuel station at the same time?
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

Commander McLane wrote:
What about two NPCs wanting to enter the fuel station at the same time?
That was the scenario I was considering, not particularly the player & NPC one (which wouldn't be too difficult, as Eric describes).

But I guess that situation would be quite rare (as not many station-using traders are added), and it's only really the player situation that matters.
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

Sadly I'm not sure this bug is actually fixed. I've updated Fuel Station to 1.2 for compatibility with Oolite 1.73, and as has been reported am now seeing the caddy-splat bug again.

So to check I reverted the OXP back to 1.11 (prior to Eric's addition of NPC users in 1.12). The first time I tried to fuel a caddy it worked, but I've just tried it again a few times and even with the old version of my OXP it failed.

I [seem to recall seeing the 1.2 version work at least once, so I'm wondering if it's something not working in the game after the first time of fuelling?

Editted to add - OK, now it's getting even more weird. I've got one Caddy save game that bounces off the station, and another that docks and fuels without a problem. They're both variants on the same save-game (used for testing Aquatics) and so are reasonably similar. No idea what the hell's going on here :evil:
another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 6632
Joined: Wed Feb 28, 2007 7:54 am

Post by another_commander »

@Thargoid: Can you please upload the two savegames somewhere for getting them to test?
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

another_commander wrote:
@Thargoid: Can you please upload the two savegames somewhere for getting them to test?
Files are here. Cmdr Aquatics goes splat for me, Aquatics2 works fine. Normal test is to jump between Aqualina and Biraira (or however it's spelt) and head to the nearest fuel station.

Both are old test commanders from making Aquatics (hence the names), and are flying original Caddy's (the old first version, not the newer one).
another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 6632
Joined: Wed Feb 28, 2007 7:54 am

Post by another_commander »

I've tried Thargoid's saved games a substantial amount of times each and can confirm that collisions with the station can still sometimes occur. Using Fuel Staton v1.2. I have not been able to discover a pattern, it seems to happen almost randomly (but not often). I had successful passages through the station with both games and collisions with both, so it is not that one game is good and the other is not. I also had multiple successful passages on the same station, so it is not a question of succeeding in the first pass and failing in subsequent ones either. Very puzzling.
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

I'm getting similar patterns with Fuel Station 1.11, 1.12 and 1.2, so I don't think it's the OXP broken something. That said I would be surprised if it was, the station model and AI are the same between the lot of them, it's only the scripting/AI for NPCs plus a couple of small generic changes to make 1.73 compatibility anyway.

I'll give the two save games some more running, as I haven't given it a thorough test, but you're quite probably right that it's something more random and annoying. As I said I couldn't really understand why it would be one and not the other, as the save games aren't too different.
Post Reply