Skip to content

Switch checked property cannot be reliably set externally #16

@0kibob

Description

@0kibob

Body:
Setting a Switch checked value using set("checked", value) or constructor properties is unreliable. The value may be ignored or not reflected in the UI depending on initialization timing.

Expected behavior:
switch:set("checked", true)
or
main:addSwitch({ checked = true })

should always update the visual state.

Actual behavior:

  • Constructor checked is sometimes ignored
  • set("checked", value) may not update the UI
  • Click interaction works correctly, but external updates do not

Impact:
Prevents using Switch as an externally controlled UI element (for example redstone or system state binding).

Note:
Likely related to PropertySystem initialization timing and _values not being fully ready during construction or early updates.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions