Problem
The shared maps/python/Common.py::obj_assign_attribs() helper performs generic numeric coercion with int(value), which accepts decimal input only. The same helper is present on both maintained content lines:
On 1.x, this makes the natural DM command fail:
/create torch light_color ff0000
ff0000 remains a Python string, then the typed light_color setter rejects it with TypeError: Illegal value for light_color field. The decimal workaround (16711680) is inconsistent with archetypes, maps, the authored schema, and editor-facing syntax. The same helper is also used by /patch.
This is a command-adapter gap, not a colored-light renderer defect. The engine and authored loader intentionally use an integer internally and exact six-digit, unprefixed hexadecimal at the authored boundary; the command helper needs to bridge those representations deliberately.
Outcome
Make user-facing object-attribute commands accept canonical color input consistently on both release lines, while preserving each line's ownership and runtime contracts.
main does not currently carry Classic's complete colored-light runtime contract. Do not use this issue to merge 1.x wholesale, import Classic implementation, or relax the replacement/provenance boundary; make a branch-appropriate helper/test change.
Delivery and validation
Use separate, linked pull requests targeting 1.x and main, as required for post-fork cross-line work. For each line:
- add focused coverage for valid lower/uppercase RGB and malformed values;
- run
python3 tools/validate.py;
- run
git diff --check.
Related implementation: #64 and atrinik/classic#77. The broader authored-source color audit in #65 is separate from this command parsing bug.
Problem
The shared
maps/python/Common.py::obj_assign_attribs()helper performs generic numeric coercion withint(value), which accepts decimal input only. The same helper is present on both maintained content lines:1.x, which now owns Classic's authoredlight_color RRGGBBfield after feat(lighting): author colored light sources #64main, which retains the forward copy of the embedded command/helper codeOn
1.x, this makes the natural DM command fail:ff0000remains a Python string, then the typedlight_colorsetter rejects it withTypeError: Illegal value for light_color field.The decimal workaround (16711680) is inconsistent with archetypes, maps, the authored schema, and editor-facing syntax. The same helper is also used by/patch.This is a command-adapter gap, not a colored-light renderer defect. The engine and authored loader intentionally use an integer internally and exact six-digit, unprefixed hexadecimal at the authored boundary; the command helper needs to bridge those representations deliberately.
Outcome
Make user-facing object-attribute commands accept canonical color input consistently on both release lines, while preserving each line's ownership and runtime contracts.
1.x,/create torch light_color ff0000assigns integer0xff0000; lighting/applying the torch emits red light.1.x,/patchfollows the samelight_colorparsing behavior.main, so the forward line does not retain the known decimal-only coercion defect.RRGGBBcontract.Load()behavior for unrelated attributes.maindoes not currently carry Classic's complete colored-light runtime contract. Do not use this issue to merge1.xwholesale, import Classic implementation, or relax the replacement/provenance boundary; make a branch-appropriate helper/test change.Delivery and validation
Use separate, linked pull requests targeting
1.xandmain, as required for post-fork cross-line work. For each line:python3 tools/validate.py;git diff --check.Related implementation: #64 and atrinik/classic#77. The broader authored-source color audit in #65 is separate from this command parsing bug.