spinners and gems

This commit is contained in:
2026-06-21 18:27:45 -05:00
parent 9b53552f4a
commit d4b9278838
17 changed files with 626 additions and 56 deletions
+6
View File
@@ -49,6 +49,11 @@ pub struct ObjectDef {
/// Whether the object can be shoved by a mover. Unused for now (no push
/// mechanic yet); defaults to `false`.
pub pushable: bool,
/// Whether walking into this object **grabs** it: the player moves onto the
/// cell and the object's `grab()` hook fires (the object is expected to
/// remove itself via `die()`). Set when a grab archetype (e.g. a gem) is
/// expanded into an object. Defaults to `false`.
pub grab: bool,
/// Name of the Rhai script in [`Board::scripts`] that drives this object.
/// `None` means this object has no script yet.
pub script_name: Option<String>,
@@ -93,6 +98,7 @@ impl ObjectDef {
solid: true,
opaque: true,
pushable: false,
grab: false,
script_name: None,
builtin_script: None,
tags: HashSet::new(),