Jump to content

Edit History

Please note that revisions older than 365 days are pruned and will no longer show here
meganoth

meganoth

3 hours ago, FramFramson said:

 

Eh, it could be a general vehicle property. I don't think TFP would have had cause to change Unity's basic physics engine settings too dramatically, unless maybe something about the voxel physics required it? It seems unlikely though I guess not impossible.

 

I mean, sure, you how never know how spaghetti someone's code is until you actually look at it, but I have no reason the think the 7D2D code is particularly bad in this regard. 7D2D bugs always seem to be mostly traceable cause-and-effect, not a bunch of wildly unrelated things breaking.

 

Anyway this is all just speculation.

 

 

I interpreted Faatals message above that Unity's code is basically not handling the physics of 2 wheel driving at all. As he said, the vehicle would simply fall if the application programmer did not add code to handle the situation:

 

On 9/21/2023 at 1:19 AM, faatal said:

Two wheeled Unity vehicles fall right over as soon as you turn

 

So Faatal must have added code and this code probably uses a feedback system where for example the stronger you lean to one side (when driving straight) the stronger an opposing force pushes back. Such systems tend to generate oscillation such as we see in the game.

 

Now you can make the formula which calculates the opposing force (from some variables lile leaning, speed and turn radius) arbitrarily complicated. You could even make a complete physics simulation but that would probably cost too many cpu cycles for just the driving. So you need to find a simpler formula that still works well. And that searching and testing those formulas probably takes a lot of time.

 

This is not about cleaning sphagetti code.

 

meganoth

meganoth

3 hours ago, FramFramson said:

 

Eh, it could be a general vehicle property. I don't think TFP would have had cause to change Unity's basic physics engine settings too dramatically, unless maybe something about the voxel physics required it? It seems unlikely though I guess not impossible.

 

I mean, sure, you how never know how spaghetti someone's code is until you actually look at it, but I have no reason the think the 7D2D code is particularly bad in this regard. 7D2D bugs always seem to be mostly traceable cause-and-effect, not a bunch of wildly unrelated things breaking.

 

Anyway this is all just speculation.

 

 

I interpreted Faatals message above that Unity's code is basically not handling the physics of 2 wheel driving at all. As he said, the vehicle would simply fall if the application programmer did not add code to handle the situation:

 

On 9/21/2023 at 1:19 AM, faatal said:

Two wheeled Unity vehicles fall right over as soon as you turn

 

So Faatal must have added code and this code probably uses a feedback system where for example the stronger you lean to one side (when driving straight) the stronger an opposing force pushes back. Such systems tend to generate oscillation such as we see in the game.

 

Now you can make the formula which calculates the opposing force (from some variables lile leaning, speed and turn radius) arbitrarily complicated. You could even make a complete physics simulation but that would probably cost too many cpu cycles for just the driving. So you need to find a simpler formula that still works well. And that searching and testing for that formula probably takes a lot of time.

 

This is not about cleaning sphagetti code.

 

meganoth

meganoth

3 hours ago, FramFramson said:

 

Eh, it could be a general vehicle property. I don't think TFP would have had cause to change Unity's basic physics engine settings too dramatically, unless maybe something about the voxel physics required it? It seems unlikely though I guess not impossible.

 

I mean, sure, you how never know how spaghetti someone's code is until you actually look at it, but I have no reason the think the 7D2D code is particularly bad in this regard. 7D2D bugs always seem to be mostly traceable cause-and-effect, not a bunch of wildly unrelated things breaking.

 

Anyway this is all just speculation.

 

 

I interpreted Faatals message above that Unity's code is basically not handling the physics of 2 wheel driving at all. As he said, the vehicle would simply fall if the application programmer did not add code to handle the situation:

 

On 9/21/2023 at 1:19 AM, faatal said:

Two wheeled Unity vehicles fall right over as soon as you turn

 

So Faatal must have added code and this code probably uses a feedback system where for example the stronger you lean to one side (when driving straight) the stronger an opposing force pushes back. Such systems tend to generate oscillation such as we see in the game. Now you can make the formula which calculates the opposing force (from some variables lile leaning, speed and turn radius) arbitrarily complicated. You could even make a complete physics simulation but that would probably cost too many cpu cycles for just the driving. So you need to find a simpler formula that still works well. And that searching and testing probably takes a lot of time.

 

This is not about cleaning sphagetti code.

 

meganoth

meganoth

2 hours ago, FramFramson said:

 

Eh, it could be a general vehicle property. I don't think TFP would have had cause to change Unity's basic physics engine settings too dramatically, unless maybe something about the voxel physics required it? It seems unlikely though I guess not impossible.

 

I mean, sure, you how never know how spaghetti someone's code is until you actually look at it, but I have no reason the think the 7D2D code is particularly bad in this regard. 7D2D bugs always seem to be mostly traceable cause-and-effect, not a bunch of wildly unrelated things breaking.

 

Anyway this is all just speculation.

 

I interpreted Faatals message above that Unity's code is basically not handling 2 wheel driving at all. As he said, the vehicle would simply fall if the application programmer did not add code to handle the situation:

On 9/21/2023 at 1:19 AM, faatal said:

Two wheeled Unity vehicles fall right over as soon as you turn

 

So Faatal must have added code and this code probably uses a feedback system where for example the stronger you lean to one side (when driving straight) the stronger an opposing force pushes back. Such systems tend to generate oscillation such as we see in the game. Now you can make the formula which calculates the opposing force (from some variables lile leaning, speed and turn radius) arbitrarily complicated. You could even make a complete physics simulation but that would probably cost too many cpu cycles for just the driving. So you need to find a simpler formula that still works well. And that searching and testing probably takes a lot of time.

 

This is not about cleaning sphagetti code.

 

×
×
  • Create New...