Movecraft icon indicating copy to clipboard operation
Movecraft copied to clipboard

Make CraftType values a default value instead of a static value.

Open goodroach opened this issue 7 months ago • 0 comments

Is your feature request related to a problem? Please describe. Currently, the CraftType class acts as a shared configuration for all crafts of that type. This means that values like maxHeight or other numeric settings are static across all crafts of the same type. However, in more dynamic systems or gameplay scenarios, it would be beneficial to allow per-craft customization of certain parameters, using the values defined in the CraftType as defaults rather than enforced constants.

Describe the solution you'd like

  • Refactor CraftType to support per-craft instances, or alternatively, allow an override layer for individual crafts.
  • Add set methods to modify parameters (e.g., maxHeight, speed, acceleration) to the CraftType object as it will now be copied instead of being the singular instance in each craft.
  • Restrict mutability to only numerical parameters (double, float, int) for now, to avoid breaking changes or inconsistent behavior.
  • Keep immutable properties like the name or other identity-critical values unchanged per craft.

goodroach avatar Jun 02 '25 12:06 goodroach