FirstPersonKSP / FreeIva

Work in progress mod for Kerbal Space Program which allows getting out of your seat and moving around the vessel while on IVA.
GNU General Public License v2.0
25 stars 8 forks source link

Report: planetside command cabin rear hatch EVA doesn't work #386

Closed JonnyOThan closed 7 months ago

JonnyOThan commented 8 months ago

So i’m having a bit of weird issue right now and i recall i believe @StormCircuit having something similar. Using the planetside command pod i shared yesterday, i cannot use the back hatch for to eva from freeiva. It says its obstructed. Looking through the little window in the hatch also reveals the interior hatch is not aligned with the exterior one as i can see the exterior hatch. Just eva-ing from external camera works fine though. Is this the same issue you had? If so where was the fix released/posted? I’m on the latest release version of both freeiva and planetside

The portrait and the external camera clicking on the hatch both work, freeiva does not

SofieBrink commented 8 months ago

i feel like it has something to do with this part having a subtype that effectively moves the external hatch. Freeiva seems to not realise this and my be checking the original postion of the hatch, which is now occlude by the part itself. this is also supported by the correctly positioned hatch being visible through the window of the incorrect hatch.

https://youtu.be/hSRgCnJJszk

JonnyOThan commented 8 months ago

FreeIva mostly uses the stock code to figure out if the hatch is obstructed: https://github.com/pizzaoverhead/FreeIva/blob/5488d6e1e4fb0abfe5be67955cf16cd676a0564c/FreeIva/InternalModules/Hatches/Hatch.cs#L1015

There's an adjustment there to the hatchObstructionCheckOutwardDistance which defaults to 1.0f (and I don't see anything in stock code which would be changing it - this is intended to make it LESS likely that the hatch is obstructed). But maybe B9PS or some other piece of code is modifying that behavior to allow the EVA when stock wouldn't have.

SofieBrink commented 8 months ago

Yeah that's why i said, probably something to do with B9PS and freeIVA not realising the hatch position has moved

SofieBrink commented 8 months ago

If it runs the stock check for obstruction at the original position of the hatch then it should be obstructed

JonnyOThan commented 8 months ago

If it runs the stock check for obstruction at the original position of the hatch then it should be obstructed

Shouldn't be, airlockTransform is a reference to the actual transform where the eva kerbal will be created. But if there's more than one it might be referencing the wrong one. Like maybe if B9PS switched airlocks as you say.