Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hyperjump exit point is sometimes too close to White Dwarf #4479

Open
robothauler opened this issue Oct 20, 2018 · 11 comments

Comments

Projects
None yet
5 participants
@robothauler
Copy link
Contributor

commented Oct 20, 2018

Observed behaviour

The hyperjump exit point is sometimes too close to a White Dwarf.
There is no chance of escape. The ship gets destroyed within seconds.

Expected behaviour

Have a chance to survive.

Steps to reproduce

Jump to a White Dwarf e.g. Van Maanen's Star (0, -2, 0)

My pioneer version (and OS):
current master

@fluffyfreak

This comment has been minimized.

Copy link
Contributor

commented Oct 20, 2018

I dunno @robothauler that's quite a high expectation ;)

@WKFO

This comment has been minimized.

Copy link
Contributor

commented Oct 21, 2018

Van Maanen's Star has a surface gravity of 207186.972g. (for reference, Sun only has about 25-30g)
Exiting somewhere close to that star is rather unsettling.

Maybe we could take both the star's radius AND the mass into consideration to calculate the exit point.

Also, this problem does not happen every time I jump to Van Maanen's Star, but it is not a single time occurance.

@fluffyfreak

This comment has been minimized.

Copy link
Contributor

commented Oct 23, 2018

Erm, what stars did you jump from when testing, because I've had a variety of things happen.

Sometimes I miss the star and get flung out.
Sometimes I smash into it.

There's some randomness involved in exiting but it also depends on where you came from a bit.

@fluffyfreak

This comment has been minimized.

Copy link
Contributor

commented Oct 23, 2018

Also the calculation does take into account the mass of the target star when determining what your "orbital" velocity will need to be... though as you've noticed (by dying) it isn't always that reliable a calculation 😀

@WKFO

This comment has been minimized.

Copy link
Contributor

commented Oct 23, 2018

I never really looked at the code, but I know that the orbital speed formula requires the mass of the star. That's how physics (should) work.

I've jumped to Van Maanen's Star system from Sol and Epsilon Eridani a few times, and that's it.

I've also jumped between lots of other star systems, but the worst case was the orbital velocity was a little too high and I got suborbital trajectories. (At least that's what the orbit display told me.)

So Van Maanen's Star is the only one that required me to panic immediately.

@impaktor

This comment has been minimized.

Copy link
Member

commented Oct 24, 2018

One could spitt out an ordered list of the surface gravity of all stars pioneer has parsed, in some region, when starting the game, assuming star gravity is exposed to LuaAPI, if not it aught to be.

...then fly to the one with strongest gravity.

@fluffyfreak

This comment has been minimized.

Copy link
Contributor

commented Oct 24, 2018

@impaktor it works ok for Sagittarius A* ... which should have plenty of gravity mass. I think it's the exit angle calculation which is suspect and that could fail even with relatively low mass stars.

@fluffyfreak

This comment has been minimized.

Copy link
Contributor

commented Oct 24, 2018

If you look at the line starting here: https://github.com/pioneerspacesim/pioneer/blob/master/src/Game.cpp#L523

You'll see that I'm not 100% certain of my calculations in this area 😁

EDIT: line 539 is also self explanatory: https://github.com/pioneerspacesim/pioneer/blob/master/src/Game.cpp#L539

@quickdudley

This comment has been minimized.

Copy link
Contributor

commented Oct 27, 2018

This might have also caused me to crash into Barnard's Star; but that might also have been caused by putting too much trust in the autopilot.

@robothauler

This comment has been minimized.

Copy link
Contributor Author

commented Jan 1, 2019

I think this is solved since #4495. The only thing is that I'm approx. 400000AU away if I jump to Sagitarius A*. But I think this is a separate issue ;-)

@impaktor

This comment has been minimized.

Copy link
Member

commented Jan 1, 2019

Well, if you arrive > 100 AU from the targeted body, it sounds like it still needs fixing to me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.