On the matter of the player falling out of the ship. The gravity generator has a set range that it can effect. So once the player's gravity (on your UI) hits 0 or < 0.5 or so, it could disconnect the player from the ship and return them to normal free floating space. Which would make sense because the player is still within the ships gravity well, so it should still effect the player.
Well.. I don't know. It's true the range of the generator is limited, and I've come across that problem before - with large enough ship, the generator may not be able to affect the whole ship (and you'll need multiple generators to fully cover it). In the first place you can't exactly assume that every ship has gravity generator - or that it's turned on at all times. Technically any vector change the ship makes, should have in impact on player - relative to the ship. You can assume ship has inertial dampeners, and it would make sense to assume that's another function of the gravity generator (otherwise the whole gravity generator would be obsolete). That would mean if you disconnect from chair in moving ship - and the generator isn't on, or you move outside it's area.. you'll be likely to go splat in a very spectacular way. Whether that's a good idea, I'm not sure... and trying to fully implement it would be complicated. You'd need to hit the player with force of the vector change of the ship, and basically make the player "fall" against the walls of the ship - simply falling into space through the walls of the ship would make no sense. On the other hand I guess the jet pack should work relatively normally within the area of the dampening effect - since the effect would simply apply the force equal to relative changes in the ship's own inertia.
If the player attempts to leave a passenger seat or cockpit and there is no gravity generator currently affecting that area of the ship, don't allow the player to leave the seat while the ship is in motion (so same as it works now) until a better method could be programmed. And add gravity generators to SVs!
In response to both your comments. HVs are meant to work on a planet, in which case the planets gravity would be the force pulling the player down. So there is no need to add a gravity generator to HVs. I know some people who build medium sized SVs, where you can walk around on them, so a gravity generator for them would be cool.
I am pretty excited for this and I can't wait to see if it is implemented soon! Thanks for the great work, I hope more modders pitch in and can add features like you did, bc that would make the development process a hell of a lot faster
I'm wondering if using this same type of code where the player is tied to the ship would also allow us to logout on a ship and log back in on the ship even if it has been moved by another player.
Much better to necro than to have a duplicate thread opened. At least this way newer players can review what was previously said on the subject and make comments that take that history into account.
The feature would be nice however you necro-ed the thread to discuss a subject (remembering the logout location when on a ship) that is not mentioned by the OP or others. This might be a good canidate for a new post. All are great, awesome topics but why drag a seven month old dead post to discuss it?
I will add that there were other lengthy discussions about this "walk on moving ship" where more aspects were included than the simplistic model described here. The OP assumed that there is just a ship's "down" movement in space but actually there is a "down" vector in space relative to the "ecliptic plane" of the planet (its equator "plane"). So a player getting out of the influence of the gravity gen of a CV would then flip (or not?) and fall in the "space down" vector. The model also implies that a "ship" is one object, while we don't know how eleon treats a voxel built "in motion". We know that collisions have problems and that players just fly through walls when not sitting in a passenger/ pilot seat (the "parenting" but static) and the model here only takes a floor has having such "gravity" and "collision" detection. I have no doubt that Eleon is able to "align a player with a ship floor" even if the ship moves, but that's now the main problem: if they decide to give this feature a try, it will just open a neverending can of worms regarding network sync and collisions. Like the OP mentioned, this would work best with only 2 CVs and not 10 vs 10, and this points towards the same problems that were discussed in the other lengthy discussion. In other threads there were concerns about the possibility of massive amounts of check for collisions and movement adjustment. I would have to go through the video another time but from one view I see a very simplistic model made on assumptions of simple collision and gravity vectors, with movements really differing from the slow paced motion of the platform. A ship is not a platform moving on a set path, and we know that rotating a ship with fuzzy collision might pass through a player before a check has been made to define its precise position. Add server-client delays and even with some parenting done allowing movement for a player, there would most probably be some serious wobbling and back-and-forth player/ objects movements.
(The rest of your post is quite relevant, but I'd just like to drop a comment on this part): I'd take rubber-banding anyday, over falling through moving ships
lol... We're not the ones getting the flames and pitchfork anyways... that may be the main problem, not the "coding" as such.
Totally On a side-comment, I would personally split the ship into 'two', if I were to approach it: -One being the actual ship in space, with a 'fake camera' -Other being a 'fictive ship', where anyone inside, is actually at, that is static, but the surroundings is 'moved' (showing the 'fake camera's viewpoint). That would pretty much nullify rubber-banding, and syncing issues for the reletive movement of two objects
If I was in charge of deciding in what order things would be done, I would fix the ship's motion first (rotation & acceleration speed limits to "human"), I would make some "block merging" feature to some extent, I would change the weapon systems with "spinal weapons" being the main weapons and make turrets take a second role (defense against little bugger SVs & such), I would work on the colliders (simplify everything) and after all is neat and smooth in MP I would give the "walk on moving ship" a try. Doing this now is a sure way to stall everything else and to give the devs headaches trying to strap this feature on things that make no sense.
I did not vote on this issue. It's not that I don't care, because I do, I really do. I just don't understand why walking on a moving ship has been such as issue. At no point do we spend much time moving our ships around. If we launched off world and intended to fly to the moon, by the time we got all aimed at the point we want, got up, ran back to the constructors, did anything, it would be time to race back and sit down and try to land. Distances are still very small, and there is no auto pilot of any kind. A ship without a pilot is in serious trouble. Even passengers would still find it easier to do things using the control panel than by being up wandering around. So just when would ever use that ability? This has never made any sense to me. (Ballard now ducks and dives under a desk, hands over his head, fetal position, as he expect flame and stone to fall upon his punkin head.)
This was asked precisely bu Hummel-o-War in this other lengthy thread. And along what you mention, most players did not give much as an answer that couldn't be achieved already with the control panel. Watching the stars fly by... managing inventory and constructors... In fact the only "reasons" were combat related, and only applied in multiplayer (PvP - boarding ships) = the worst case scenarios... With the solution proposed in this present thread, I can already see problems with two different ships having their gravity generators intersecting with each other and geometry changing place rapidly, while the "detect closest ship" function switches from one to the other and back... At the speed ships can move (rotate) this is bound to generate errors. The actual state of multiplayer needs a lot of work to get smoother, and this kind of feature can only worsen things.