Jump to content

Realistic Water physics and Semi-destructible Ground


Recommended Posts

When a part fall to the water at a very high speed it disappears and you can't find it. Is this realistic? No, I would like the part to be not destroyed,but sink to the seafloor or float to the ocean surface if the fuel tank is empty. It will float, its annoying to see a part just destroyed and you can't find it. The Semi-destructible ground is when a object hit the ground at a very high speed from reentry or past 15 M/s. There will be different types of crater: A little dent(low speed impact),Medium Crater(Medium speed impact), Large Crater(high speed impact). The crater size will also depend on how big is the object. The object will also have a damage bar which shows how much damage it takes(a dent,holes, and beyond repair).The appearance of the Crater is black then it will regenerate into regular ground in 5-6 Mins. I also want the electrical parts(Batteries) and Fuel tanks(If its empty it doesn't produce fire) and RCS tanks and anything that Contains fuel or Energy will produce a flame when damaged or crash into the ground. You can recover this parts and repair them.

I hope you like my suggestion and post any problems with this.:D

Link to comment
Share on other sites

It is realistic.

The part impacts with the water just as it impacts with the ground, just no explosions. So it shatters into billions of carefully crafted pieces so you never have to see an oil spillage from the fuel you'd be carrying, or the extremely volatile pieces of broken batteries.

Link to comment
Share on other sites

Not sure how easy deformable terrain would be, but realistic water physics on a planetary scale would take a supercomputer. What you're suggesting isn't so much "realistic" water, so much as it is having the game take into account the current mass of the part to determine buoyancy.

Link to comment
Share on other sites

Too resource intensive, in my opinion. That's always the trouble with "realistic" physics and deforming things. The calculations required are ridiculously complicated -- that's why KSP doesn't do N-body physics calculations; they're too complex to simulate on time warp. Deforming terrain or parts, and making water act like real water is excessively difficult for computers to do, especially in realtime.

Link to comment
Share on other sites

Too resource intensive, in my opinion. That's always the trouble with "realistic" physics and deforming things. The calculations required are ridiculously complicated -- that's why KSP doesn't do N-body physics calculations; they're too complex to simulate on time warp. Deforming terrain or parts, and making water act like real water is excessively difficult for computers to do, especially in realtime.

A simplified version could probably work though - I've seen javascript in websites which calculates crater diameter and depth for various surfaces, impactor types, and angles so we could probably have a similar calculation in the game. Whether they're persistent or not is another matter.

Also, does the game actually support buoyancy? I've never checked to see if anything splashed down, then sank, and I've never had any lighter-than-air parts. So to me it seems like there's constant buoyancy in water, and none in air.

Link to comment
Share on other sites

It shouldn't be too hard to implement ships causing craters.

All you need to store is the crater depth, width, location and maybe radial deformation. Procedural terrain generation can take care of the rest. Since you only need 1 crater per crash this shouldn't be too resource intensive.

But, to be honest. Squad has bigger fish to fry than frivolities like this. I'd much rather see more career mode than craters.

Link to comment
Share on other sites

All you need to store is the crater depth, width, location and maybe radial deformation. Procedural terrain generation can take care of the rest. Since you only need 1 crater per crash this shouldn't be too resource intensive.

Procedural terrain is the idea of generating terrain based on a number of rules, which isn't applicable here. For example, the craters on the Mun were procedurally generated, but they are not done so in realtime. As Captain Sierra said, to get craters you would need soft body physics, rather than the current solid body that the planet is. Whilst it's everyone's dream to drill a hole through Kerbin using nothing but solid boosters, the deformation calculations, in real time, on a planetary scale, are beyond the realms of possibility at the moment.

Link to comment
Share on other sites

Rather then deformable terrain, just a sprite representing an impact could easily be used. It can be saved similar to how flags are.

For water, parts of rockets will float if you follow them down and they don't hit extremely hard. However, I did have a fuel tank explode on impact with water even though it was under 10 m/sec on parachutes. This seems to vary, especially with Career mode, on tier zero flights where they have survived water landings but explode on land impact.

Space Engine does very realistic water that has none of the moire pattern of KSP. It also has realistic moving clouds of various densities at various altitudes. How that would affect frame rates in KSP if it could be done in Unity is unknown.

Link to comment
Share on other sites

By "under 10m/s", do you mean just under? Even structural parts like the Science Lab only have a tolerance of 8m/s. Off the top of my head, I think fuel tanks only have around 6m/s... 10m/s is actually quite fast, if you think about it. Try crossing a ten metre-gap in a single second... it just won't happen. It's a small number, but it's pretty darn fast just the same.

Link to comment
Share on other sites

Rather then deformable terrain, just a sprite representing an impact could easily be used. It can be saved similar to how flags are.

A sprite is a 2D object, whereas the flags are 3D physical objects. Even if you placed a default 'crater' object whereever a crash was, you'd end up with some physical crater that would have to be interactable with, and you could then, in theory, crash multiple craft into the same point and end up with a 'hill' made up of holes stacked on top of each other. The only way craters work is with real physics, but as previously mentioned, that doesn't work. Look at bullet holes in older games - they just stack on top of each other when you fire at the same piece of wall - it doesn't look good, nor is it realistic, nor does it add much value to the game. The real benefit comes when those bullets start destroying cover, Matrix style, and you see an output for an input

For water, parts of rockets will float if you follow them down and they don't hit extremely hard. However, I did have a fuel tank explode on impact with water even though it was under 10 m/sec on parachutes. This seems to vary, especially with Career mode, on tier zero flights where they have survived water landings but explode on land impact.

Absolutely, they will float if it's soft enough. However, bear in mind that 9.8m/s is still the equivalent of hitting the water after free falling for a second, so it's not exactly a 'soft' landing. Each part also has a different impact resistance, so a structural girder is more likely to survive than a fuel tank, for example.

Space Engine does very realistic water that has none of the moire pattern of KSP. It also has realistic moving clouds of various densities at various altitudes. How that would affect frame rates in KSP if it could be done in Unity is unknown.

With all due respect, Space Engine is a completely different game - it's like asking if my toaster makes a good aeroplane. The engine, and the code that KSP is written for, is optimised for rocket dynamics, and lots of physics delta steps to give a good approximation. Space Engine is written to contain a lot of objects in high detail, but without any physical perturbations (as far as I know? I've not actually played it so forgive me if this is wrong). They're both designed to be completely different things and as such, they're not really comparable, past that they both deal with space and planets.

edit: NINJA'ed!

Link to comment
Share on other sites

I distinctly remember a rather old game by the name of Hostile Waters. You could literally flatten the entire map if you wanted to spend long enough with howitzers blasting the bejeezus out of the landscape. You don't really need "physics" as it were, beyond the basic collision detection which we already have. What you would need though, is deformable terrain. Not so much soft body physics, as much as two sets of data for each celestial body: The original height values (which don't stay loaded in RAM), and a set of height values copied from the originals, which are used to actually render the landscape with. Something causes a crater? Dig the height values down a bit. Make your own Mohole on Kerbin, then go into the game settings and click "reset planetary deformations" when you're bored with it.

I'll agree it's not a massive priority compared to the rest of the planned features, but it would certainly be nice, and I don't think as hard as some people are saying. Certainly not supercomputer-hard.

Link to comment
Share on other sites

I distinctly remember a rather old game by the name of Hostile Waters. You could literally flatten the entire map if you wanted to spend long enough with howitzers blasting the bejeezus out of the landscape. You don't really need "physics" as it were, beyond the basic collision detection which we already have. What you would need though, is deformable terrain. Not so much soft body physics, as much as two sets of data for each celestial body: The original height values (which don't stay loaded in RAM), and a set of height values copied from the originals, which are used to actually render the landscape with. Something causes a crater? Dig the height values down a bit. Make your own Mohole on Kerbin, then go into the game settings and click "reset planetary deformations" when you're bored with it.

I'll agree it's not a massive priority compared to the rest of the planned features, but it would certainly be nice, and I don't think as hard as some people are saying. Certainly not supercomputer-hard.

You could flatten the world in Total Anihillation, or Worms, or whatever, of course, but imagine for a moment how KSP, and Unity works.

Each delta time, there is a set of physics calculations on the active vessel. Let's imagine a simple rocket, that's got 20 or 30 parts as part of a lander and return vehicle to the Mun, or whatever. Assuming it's coming in too fast, it hits the ground, and the first piece that hits calls CraterGenerator() as a function, which does all the whizzbang calculations and calculates what that part does as damage to the ground. Great, but you now have 29 other pieces which are now flying behind which haven't been calculated. So unity then has to do the adjustment of the planetary surface, work out a new position for the next piece to hit, do the physics calculations on that, and continually form craters for each new bit that hits. Now obviously, that's possible to do, but whether or not KSP can do it on a single-core basis whilst also maintaining the remainder of the game would probably slow down the system. Not to mention you would then need to consider whether the planet has other layers underneath, and then do they have biomes of their own (ie: is digging a viable science option via impactors?), and you end up with a number of gameplay and engine issues which, whilst interesting, probably cause more issues than they solve.

I don't know, it's something I'd like to see, but on the other hand I wouldn't be upset if it was never delivered because of technical constraints. I can imagine the game breaking very easily as Scott Manley fires a 0.1c kinetic impactor into Minmus and turning it from a Mint dessert to a hors d'ouevre, or whackjob's creation loading onto the launchpad and crushing KSC.

Link to comment
Share on other sites

Scott Manley fires a 0.1c kinetic impactor into Minmus and turning it from a Mint dessert to a hors d'ouevre, or whackjob's creation loading onto the launchpad and crushing KSC.

Or indeed, whatever mindboggling hilarity Danny2462 might come up with.

For this reason alone it's worth considering. But yes, maybe once the rest of the game is working.

Link to comment
Share on other sites

My computer would probably melt if this was implemented

What about us with our not so powerful computers?

I have a 3-and-a-bit year old Athlon II X4 640. Not exactly the speediest either, especially since there's only one main process involved.

If it can be done though, and I've a feeling it could be cheated into working (perhaps if a whole bunch of parts are set to impact in the same game tick, it counts as one impact), I'd definitely like to see it. It doesn't need to be a hyper-realistic simulation of a mass impacting a planet. It just needs to be divets getting dug into the ground with an appropriate size for the tonnage involved.

Link to comment
Share on other sites

The way that the physics is unrealistic is that it's WAY too bouncy. Also, If I build say a boat and if it's in a v shape, the enclosed parts that go underwater are still filled with water.

Your terrain idea is something I'm not sure of, maybe regenerative/destructible terrain? Still, too much work and not much use.

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...