tsunamayo / Starship-EVO

Welcome to Starship EVO bug tracking repo !
117 stars 17 forks source link

[Discussion] Gravity Generator #1818

Open ZachZent opened 4 years ago

Xerma commented 4 years ago

This is just what I posted in the previous thread:

Space Engineers as far as I know only uses gravity generators and they only affect an area sort of like how we currently have but their setting can also be tweaked. Most people end up modding this because it's just clunky to work around for proper gravity on ships. Starmade just uses a single block with no power consumption for global gravity on the entire ship. A good work around could be a mix of what we have with global gravity. What could work is have draggable gravity systems like how reactors or shields work, they require power, give off heat, etc but as you get a bigger system the area gets larger and requires more power, heat, etc. This could have a max amount of lets say 6 x 6 x 6 (just an example) and maybe that gravity generators range is 32 meters from each face of the system.

Something like that would really fit the feel of the game in my opinion and is a compromise between a global gravity setting vs numerous gravity generators which can get very tedious very fast. Especially for ships larger than 100m - also depending on their total volume.


That being said though, with current gravity generators it would take over 3,000 to establish gravity everywhere on the sphere ship I've been working on. That's just purely based on math and doesn't include gaps for hull, interior gaps, etc. It was purely based on the volume of the ship divided by 4,096 (16x16x16). Sure the sphere ship can be seen as a more extreme example but if you slice my ship into pieces and refit it to the current proposed max build limits then it would be the equivalent of about 500 x 250 x 125 - ish (rough estimate). Still quite large so lets use a smaller ship as an example. Strictly going off volume, lets use a ship that is roughly 200m x 100m x 50m. Their volume would be roughly 1 million meters cubed, divided by 4,096 (max size for current gravity) it would take approximately 244 gravity units to get gravity everywhere in that ship. That would take a long time to setup. Even if we said 100 gravity generators that would still take a very long time to setup.

ZachZent commented 4 years ago

It may be lazy to have it for the entire ship, but as the saying goes keep it simple stupid, Gravity doesn't need to be some super intricate feature. Just something that makes it easier to walk around your ship. Having to go around to set up multiple grav gens around your ship is not fun to do. Even if you the size was larger or the way to make the boundaries was more user friendly it would still be rather tedious for the players when most will just want the ship to have the floor be down.

This is also more of an assumption, but wouldn't adding areas with different gravity directions be difficult for the future NPC's path finding? I believe you said a prefab elevator will have to be added, or the current ladders can be used. How would it know a gravity elevator?

tsunamayo commented 4 years ago

Oh yes that would be a nightmare for Pathfinding. Or not, but it likely would. But there is too much with gravity, I wanted to give player my little ball and box I used to debug, and maybe with some detector you could create some cool mini-game. So what about a mega gravity block, a larger gravity area, and an option to automatically resize the gravity so they dont add more than 1g (so you can overlap). and of course debugging better the bounding box. There is quite a few option to improve that.

ZachZent commented 4 years ago

I'm not sure. With the larger size it will still take a long time to place many in larger ships. Plus there is the chance the gravity field will bleed though the ship into space meaning you will have to use the small ones to fill in any gaps. Same problem, different day. And of course placing random balls of gravity in space. Don't want people to find a way to make gravity into a weapon like SE. Please...

I am still on the side of a shipwide gravity field BUT for now to solve the problem with the interface, how about instead of putting in values into the grav gen, you drag the sides on its axis to where you want it to be. No more putting in a number and hoping it will work then going back in.

tsunamayo commented 4 years ago

What are gravity weapon? Also in the current implementation it wont bleed beyond ship bounding box, for what its worth. Doing the dragging side things seems like a lot of work... A ship wide block would be much easier to implement.

Xerma commented 4 years ago

Oh for sure a ship wide block would be much easier, I was just suggesting a compromise between the two. Granted the ship wide gravity generator could even base it's power consumption/heat/etc on the ship's volume or mass - if you wanted to go that route with gravity

tsunamayo commented 4 years ago

Oh yes it have to use power, so that once you run out of power everybody goes flying out in the air... Or blasting the grav block of an enemy ship for a more efficient boarding might be a valid strategy. It is all about emerging possibilities.

ZachZent commented 4 years ago

The gravity block should defiantly have a connection with power and other aspects of the game play. There is a lot that can be done there even with a single shipwide gravity block.

tsunamayo commented 4 years ago

what do you mean by defiantly?

ZachZent commented 4 years ago

Sorry. Definitely, not defiantly

tsunamayo commented 4 years ago

oh okay, yes we are on the same page.

SabreMania commented 4 years ago

So I noticed that nobody responded to your question, namely

What are gravity weapon?

So i'll explain. A gravity weapon is something that's most common in Space Engineers, and it involves using the gravity-generating blocks together with logic, in order to accelerate a physical projectile, made out of blocks or anything that the player can pick up/place down, at a speed that allows said projectile to cause a tremendous amount of physical damage, far more than any traditional weapon can achieve.

The easy answer to this kind of weapon, for a game dev, is to not implement collision-damage, but with modern games that seems to be less and less of an answer. Even Starmade had collision damage. (Though it was very wonky and hardly worked.)

Starmade however did have it's own dedicated explosive block, which allowed things like stick-ships to ram enemy ships, explode the block, and cause a tremendous amount of damage, since it went straight through shields like a hot knife through butter.

tsunamayo commented 4 years ago

@SabreMania okay thanks a lot. That seems like a fun thing to try out, but I can see how it could mess things up if abused... I also want to add collision damage, but it wont be a full ship simulation like SE, more some block will broke at higher speed impact.

SabreMania commented 4 years ago

Honestly it's not nessecearely a bad kind of weapon. The danger comes when there are stationary targets in play. Something like a base on a planet or a station in space. If these weapons are too strong, they can quickly ruin the fun for everyone else. By strong I don't nessecearely mean the damage potential they have (though that is a very big factor to keep in mind), I mean more the toughness these weapons have.

In Space Engineers, without any mods (last I played), the vanilla weapons were simply not strong enough to destroy them before impact. Even if you focused a dozen turret on a single 'warhead', they would still find their mark and blow stupidly massive holes in your ship.

Majikmonster commented 4 years ago

I support the ship-wide gravity idea, but I also think that there should be an option to make an area of effect like the current system (as of 20w18d).

The interface for the gravity block could include a 'mode selection' for which system to implement, with the defined region mode (current) taking precedence over the ship-wide gravity. This would effectively make ships able to have sections with alternate gravity directions (like a player jettison system), or the ability to retain only select regions of gravity while the rest goes weightless (ie: a cargo ship where only the cockpit and engine room have gravity, or a station where the loading docks are weightless).

On the ship-wide gravity note: It would be smart to keep the effect from bleeding "under" or "sideways" the ship (same direction or perpendicular to gravity) so that players can't accidentally get launched away from the craft, but allow the effect to bleed "up" (opposite the direction of gravity) to allow players to land and walk/jump on top of a ship.

In other words: like the shield, but tighter.