Rigs-of-rods: Issues with defining node mass

Created on 15 Feb 2019  路  12Comments  路  Source: RigsOfRods/rigs-of-rods

I'm currently working on a project that makes use of lifter's Flexbodywheels section, one quirk of this section is that the wheel rim nodes are not included in the defined wheel mass, rather their mass is controlled directly by the minimass setting. Whether this is intentional or not, I'm not sure, but it has proved useful for tuning, so perhaps it's an expected behavior.

However I'm running into an issue where I need to make nodes within the body structure lighter than those defined by the minimass, but since the minimass is a global setting, the node masses are reset on spawn.

Possible solutions would be allowing "L" defined node masses to be lighter than the minimass, or making minimass a non-global setting like set_beam_defaults, where the settings are only applied until the next tag is reached.

request

Most helpful comment

What about adding a "is global" option to minimass and have it default to true?

;mass, is_global
1.0, 1

All 12 comments

Fully agree with allowing multiple minimass sections. Would make weight tuning easier.

allowing "L" defined node masses to be lighter than the minimass

multiple minimass sections

How would we solve possible backwards compatibility issues?

Suggestion:

; global, can be overriden with set_node_defaults
minimass

; to reset minimass to global, use minimass=-1
set_node_defaults -1,-1,-1,-1, minimass=1.23

I already coded the parser extension which supports these NAME=VALUE optional parameters, it's a part of https://github.com/RigsOfRods/rigs-of-rods/pull/1415/commits/fd4763ea1ddf3c5a4fdb5fc386acc0490063f30f EDIT: Uhh, that code stinks, I'll write new one

allowing "L" defined node masses to be lighter than the minimass

multiple minimass sections

How would we solve possible backwards compatibility issues?

Any previous mods wouldn't be affected, since what we're talking about was never allowed.

Also, I wouldn't include a new minimass tag in set_node_defaults, because that section already has a node mass setting. Better to just edit the current minimass tag, imo.

  • _"L nodes" lighter than minimass_ should be backwards compatible, eventually just breaking mods which had accidentally already set lighter "L" and relied on the auto-clamping. We could add a new parameter allow_lighter: true/false to minimass.
  • _multiple minimass sections_ is not possible since minimass is position-independent, it could be defined at the end of truckfile and still affect everything (my parser rewrite silently lifted all the "must be defined before/after, or else!" rules). We could introduce a new directive like set_node_default_minimass

How about minimass2? Simple solution for all backwards compatibility issues.

  • _multiple minimass sections_ is not possible since minimass is position-independent, it could be defined at the end of truckfile and still affect everything (my parser rewrite silently lifted all the "must be defined before/after, or else!" rules). We could introduce a new directive like set_node_default_minimass

True, that is the current functionality. But is it not possible to rework the current section to be hierarchical in the same way as set_beam_defaults and set_node defaults? The standard use for minimass is placing it above the nodes section anyway, @CuriousMike56 and myself don't know of any mods which place minimass after the nodes section either. So theoretically even with a position-dependent version of minimass, the functionality should be identical on current content.

How about minimass2? Simple solution for all backwards compatibility issues.

Eh, the current plethora of "2" sections we have are generally looked down upon. From the outside it looks like a low effort bandaid rather than taking the time to properly update existing features. I agree it's the simplest solution, but it also continues a trend that has lead to a lot of truck file clutter and confusion for inexperienced modders.

What about adding a "is global" option to minimass and have it default to true?

;mass, is_global
1.0, 1

This should do it: #2276

Thanks, though I'm curious about the final functionality that was implemented. The way I interpreted Mike's suggestion was that the "is_global" option toggles the ability of other node mass settings, such as the l option to overwrite the default node mass. With the current update it renders the l option and minimass tag functionally equivalent, which could be confusing for new users who have to decide which method to use for setting node masses. If the minimass toggle simply allowed loadweights to override the default, the method of weight tuning that has been used for years could remain relatively unchanged, with minimass tag determining the default, and l tag/load weights determining any variation in node mass.

I realize my previous comment stated otherwise, but in hindsight it might not have been the best solution in trying to streamline RoR's modding workflow.

@ulteq It's true, my rewritten parser worked differently than the original. However, the 'multi-minimass' patch already reverts it to the original behavior, see the test load.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

only-a-ptr picture only-a-ptr  路  6Comments

CuriousMike56 picture CuriousMike56  路  6Comments

DirtGamer301 picture DirtGamer301  路  11Comments

tgp1994 picture tgp1994  路  4Comments

Speciesx picture Speciesx  路  8Comments