Add Property Observers to GDScript #56
Ericdowney
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
When writing in a more reactive style using
setget
, I've found its cumbersome to have to write both the theget
and theset
.I'm wondering if it would be possible to add
will_set(new_value)
anddid_set(old_value)
to GDScript properties to make reactive programming easier to understand. These property observers should work in addition to the existingget
andset
structure.i.e.
This should also make things easier for beginners since it's easy to forget to set your property value in a
set(new_value)
.Beta Was this translation helpful? Give feedback.
All reactions