Hello, I have been having these ideas about the future versions of Marsxplr. In the current game, gravity is represented as a constant acceleration in the downwards direction. In the real world, this doesn't happen. Sure, if you are standing in the middle of a flat surface on Earth, the gravity is pointing down. However, we know that the earth is spherical. If the current physics of marsxplr was on earth, we would either need a flat Earth in order for everything to be normal. If there was a spherical Earth, you would fall off of it if you went anywhere a bit too far from the top of it.

My idea involves gravity fields, where the origin of gravity is at a point, and wherever you are, there is always a straight line to it, and that will be the direction of the gravity. This would allow people on one side of a sphere to stay on the world, and people on the other side to stay on, as well. This is exactly like the way we have on Earth! If we had this, we would have realistic worlds to an even greater extent, and, here's another cool thing... We would be able to send ourselves into orbit!

If we were to implement this, I would suggest starting out with a sphere. With that sphere, if it was perfectly spherical, you wuld set the origin of gravity at the center of the sphere, where the distance from the radius of the sphere would be zero.

Now, in the laws of gravity, we know that the strength of gravity decreases with distance, that is a well known fact. If you were to be on the surface, you would experience a stronger pull than if you were 2000 meters above the surface. If you managed to stay inside the middle of the sphere, you would just stay there. However, this is a really complicated matter, and essentially, we won't be creating planets, we will just be creating weak black holes in the game, but that's all right, as long as you make sure no object can get a certain distance to the center.

Now, the equation for determining the force between two objects is this:

F=G(m1m2)/r^2

F is the force. G is the gravitational constant which even I don't know how it was derived, but it is 6.67x10^-11. M1 could be one of the masses that you choose, since the force of gravity is actually the force between two objects. So, let's say that m1 could be the planet, and m2 could be the buggy. The distance is r, so you can say that gravity decreases proportionally with the square of the distance.

Now that you know the force, you have to figure out the acceleration. This would require the buggy to have a set mass, and the planet to have a set mass.

Once you have the masses, and you know the force, you apply it to the equation F=ma. To figure out the acceleration of the buggy, which is what we would call the gravity of the planet in m/s^2, you divide by m, and then you get the acceleration for that distance.

The reason why I ask for the limits of the size of a world is that we want this to be sort of realistic. Sort of large worlds would be nice for spheres, because you want to be able to see a bit down the road, with a horizon that is sort of far off.

Well, let's apply this.

Let's say we are able to make a world with a radius of about 5000 meters. We want it to resemble the Earth's gravity for normality, and the Earth's gravity is usually around 9.807 m/s^2 at the surface.

Now, we have to set a mass for the buggy, so let's say it is 1000 kg, just for the sake of the mathematics.

To have an acceleration of 9.807 m/s^2 for the buggy, we use the F=ma equation, and we multiply the mass of the buggy by the acceleration of gravity we want, and if we do that, we get 9807 Newton, or 9807 N. Now, let's plug that into the first equation I gave you,

F=G(m1m2)/r^2

9807=(6.67x10^-11)(m1)(1000)/(5000)^2

We know everything except for the mass of the planet. We know that is has a radius of 5000 meters, we know that the buggy has a mass of 1000 kg, we know that the gravitational constant, G, or "Big G" is 6.67x10^-11, and we know that the force needed to accelerate the buggy downwards at that rate at that altitude is 9807 N.

So, lets solve.

9807 times the square of the radius, which is 5000^2, or 25,000,000, is 245,175,000,000, or in scientific notation, 2.45175x10^11.

We now have 2.45175x10^11=G(m1)(1000)

Divide by 1000, or 10^3, and you get 2.45175x10^8=G(m1)

Divide by G, which is 6.67x10^-11, and you get that the mass of m1, or the planet world that we have created with a radius of 5000 meters is approximately 3.676x10^18 kg.

Now, I believe what we have here is a very dense planet, lol.

I think that the equation for the volume of a sphere is (4πr^2)/3, with π being pi, or 3.14159265258... and so on, with the numbers going on infinitely many times...

So, lets figure out the volume of this sphere!

4π(5000^2)/3 is approximately 1.0472x10^8, so we can say that this is that many cubic meters. (3.676x10^18 kg)/(1.0472x10^8 cubic meters) is about 3.51x10^10 kg per cubic meter, or about 35 Billion 100 million kg per cubic meter! That is very very dense, compared with the Earth's average density of 5540 kg per cubic meter!

However, all of that talk about the density of this hypothetical planet with the gravitational acceleration of 9.807 m/s^2 at the surface is irrelevant, lol :) I just thought it would be cool to figure out!

Now, one of the AWESOME implication of spherical planets with gravity fields is that we can send ourselves into ORBIT!

The speed needed to orbit a planet is given by the square root of 2Gm/r, with everything in the square root. This is what we call the escape velocity, or the velocity that you need to stay in perfect orbit. If you go slower than this velocity, then you will hit the planet, at some point in time. If you go faster than the escape velocity, then that is what you will do, escape the reigns of the gravity, and at some speed fly away from the planet. Now, that is not to say that the planet will not have a gravitational effect on you, but you won't be bound to the planet or bound into an orbit.

Now, at what speed would we have to be driving on the surface of the planet to go into orbit?

Well, we plug what we know into the equation. This means that the square root of 2(6.67x10^-11)(3.676x10^18)/5000=An escape velocity of 313.1074 m/s, or 700.4 mph! So, if we were to be driving a buggy on the surface, we would need to be going at least 700.4 mph to go in orbit! And, this is possible in Mars 3, with the I/O Settings box.

Now, I will go into further detail about how to implement this, but I have just given you world designers and game coders something to chew on... How to implement this?

I will write the idea that Flynn has told me in the comments, but I just wanted to submit this, now.