Added names to objects

This commit is contained in:
2026-06-08 19:50:43 -05:00
parent 04415211c3
commit f5ed8f2edf
7 changed files with 149 additions and 3 deletions
+5
View File
@@ -51,6 +51,10 @@ pub struct ObjectDef {
/// not subject to any rate limit — mutations take effect immediately after
/// the frame's action queue is drained.
pub tags: HashSet<String>,
/// Optional unique human-readable name for this object. `None` if unnamed.
/// Names are validated for uniqueness at map-load time; a duplicate name is
/// cleared to `None` (the object survives but becomes anonymous).
pub name: Option<String>,
}
impl ObjectDef {
@@ -80,6 +84,7 @@ impl ObjectDef {
pushable: false,
script_name: None,
tags: HashSet::new(),
name: None,
}
}
}