Properties roomColor and gridColor in GameRoom.gd use setget functions (onRoomChangeColor() and onGridChangeColor())
that are not called in setRoomColor() and setRoomGridColor() respectively.
These setget functions are only automatically called when another script accesses the property directly
such as myRoom.roomColor = someColor
The result is setRoomColor() and setRoomGridColor() update their respective properties
but do not update their nodes self_modulate properties.
In the case of setRoomColor(), the room's color will be updated when setHighlighted(false) is called
such as when the player walks onto and then off of a room.
The gridColor property set by setRoomGridColor() does not have a path that sets self_modulate to it.
Reproductions:
setRoomColor()
- Call the
setRoomColor() function on a room to set it to a different color
- Observe the room did not change color
- Walk into the room to highlight it (it should turn purple)
- Walk out of the room to un-highlight it
--> The room only now updates to the requested color
setRoomGridColor()
- Call the
setRoomGridColor() function on a room to set the room's grid to a different color
--> The room's grid color does not change, and will never change to the requested color
The current behavior of setRoomColor() could be desirable in some circumstances
such as a visual indicator of where the player has been in some form of exploration based region
I request this be preserved in a separate function perhaps named setRoomColorLate()
Properties
roomColorandgridColorinGameRoom.gdusesetgetfunctions (onRoomChangeColor()andonGridChangeColor())that are not called in
setRoomColor()andsetRoomGridColor()respectively.These
setgetfunctions are only automatically called when another script accesses the property directlysuch as
myRoom.roomColor = someColorThe result is
setRoomColor()andsetRoomGridColor()update their respective propertiesbut do not update their nodes
self_modulateproperties.In the case of
setRoomColor(), the room's color will be updated whensetHighlighted(false)is calledsuch as when the player walks onto and then off of a room.
The
gridColorproperty set bysetRoomGridColor()does not have a path that setsself_modulateto it.Reproductions:
setRoomColor()setRoomColor()function on a room to set it to a different color--> The room only now updates to the requested color
setRoomGridColor()setRoomGridColor()function on a room to set the room's grid to a different color--> The room's grid color does not change, and will never change to the requested color
The current behavior of
setRoomColor()could be desirable in some circumstancessuch as a visual indicator of where the player has been in some form of exploration based region
I request this be preserved in a separate function perhaps named
setRoomColorLate()