Space Engineers - Prototype Gravity Confinement Tractor Beam

Channel:
Subscribers:
96
Published on ● Video Link: https://www.youtube.com/watch?v=bEcRSTKDC04



Space Engineers
Game:
Duration: 0:31
3,451 views
57


Workshop link: https://steamcommunity.com/sharedfiles/filedetails/?id=2755058905
Vanilla. This was a headache to make.

A working gravity-confinement prototype, allowing an object to be safely held in place relative to a ship (even during acceleration) using artificial gravity generators.
This may seem like a trivial issue, but much programming had to be used to allow the prototype to dampen the contained object's velocity. This was a difficult problem to solve, as you cannot directly find an unconnected ship's velocity without telemetry. I have created a workaround for this problem.
With the first hurdle out of the way of "how do we get this to work in the first place?", I now can move on to implementing this technology in something else; perhaps friggin' lagless space trains.

More info:
The difficulty in designing a gravitational containment field in Space Engineers is that gravity generators affect an object's speed instead of their position.
Consider a spaceball entering a repulsive gravity field at 1 m/s relative to the gravgenerator. The spaceball will slow to 0 m/s, but this is not helpful considering the object is still in the gravity field.
In this scenario, the spaceball will bounce off the gravity field like a mirror reflects light.

To compensate for this, we might try a different approach: utilizing the fact that gravity generators have their own range, and can overlap. By creating a strong, short-ranged repulsive gravity generator and a weak, long-ranged attractive spherical gravity generator, we can confine objects to a certain position. At least, that's what you'd think, until you realize you've basically created a box of mirrors now. If the spaceball is moving relative to the gravity generators, it won't stop moving -- it will just keep reflecting off "the walls of mirrors" you've just created.
And the object, for some reason, will continue to move more erratically until it breaks your ship.
This *CAN* work for large numbers of objects; but in order for it to work correctly, each object must collide with each other object, which can be damaging for regular ships.

So the question is: Can you implement a gravitational confinement method where 1. the confined object's method of being confined is simple (e.g. no moving parts on confined object for it to be confined), and 2. there is no physical contact between the container and the confined object?


I can think of four ways to solve this issue:

-Stupid but quick solution: Spawning rocks and having them drop into the containment field will cause the rocks to average some kinetic energy with the confined object.
This can slow down not only the confined object, but also your game. And it takes a constant supply of stone.

-"Metamaterial" solution: By creating hundreds of overlapping fields (alternating attraction and repulsion to create a repeating pattern of strongly attractive-weakly repulsive parts), you can slow objects relative to a ship. Of course, this slowdown is in exchange for the object moving around your confinement zone when accelerating. So you basically have a max speed when using this method.

-Programmatic solution: If we can sense how fast our contained object is moving, we can dynamically enable and disable gravity generators to dampen the object's momentum relative to the ship. However, this can be a problem if confining more than one object.

-Too many spaceballs solution: Using a massive number of spaceballs (36 or more), the effects of gravity are localized on each object. This means that the effects of gravity on the contained object approximate a smooth and continuous effect; this allows the object itself to exchange linear momentum for rotational momentum. But for this to work properly, your ship has to basically consist of entirely spaceballs -- no, you cannot get away with just making a few really heavy ones. It has to be continuous.

The programmatic solution seems to be the way to go for simple designs, and it's the one I went with in this demo -- although I dislike this for a few reasons (harder to implement on servers where programming blocks are disabled.)

For designs where two or more objects have to be contained per containment unit, at the moment, we have to use the too many spaceballs solution.

If there was such thing as a "dampening field", this entire problem would be nullified. However, there is currently no way I know of to dampen an object's velocity relative to yours automatically without having something physically touch or connect to the contained object (or through telemetry.)

Of course, humans are smart, and can themselves learn to control the objects contained within their containment field, but the goal of this design is so that it can work without player supervision.







Other Statistics

Space Engineers Statistics For Daxturus

Daxturus currently has 37,304 views spread across 3 videos for Space Engineers. Less than an hour worth of Space Engineers videos were uploaded to his channel, or 1.74% of the total watchable video on Daxturus's YouTube channel.