10 [Header(
"Room Flag:")]
11 [SerializeField]
private bool _editId;
15 public bool EditId {
get => _editId;
set => _editId = value; }
17 [SerializeField]
private int _id = -1;
21 public int Id {
get => _id;
set => _id = value; }
25 base.AutoAssign(room);
An object tied to the cell index of a RoomComponent.
RoomComponent Room
The containing room.
Contains methods for creating random ID's.
static int AutoAssignId(int id)
If the specified ID is greater than zero, returns the ID. Otherwise, returns a random positive intege...
A component for creating a room.
RoomState RoomState
The room state.
bool FlagIsSet()
True if the flag is set.
bool RemoveFlag()
Removes the flag. Returns true if the flag was removed.
override void AutoAssign(RoomComponent room)
Performs auto assignment on the object.
bool ToggleFlag()
Toggles the flag. Returns true if the flag is now set. Otherwise, returns false.
bool EditId
If true, the ID can be edited in the inspector.
bool SetFlag()
Sets the flag. Returns true if the flag was not already set.
int Id
The unique flag ID.