made an action be owned by a contact instead of actor; made another example action

This commit is contained in:
2026-02-02 17:51:12 -05:00
parent 7095a140a0
commit 36b934b200
6 changed files with 39 additions and 9 deletions

View File

@@ -22,8 +22,11 @@ public partial class Phone : Sprite2D
_phoneButtons[i]._phone = this;
}
_phoneButtons[0]._contact._action = new Example1();
_phoneButtons[0]._contact._action._owner = _player;
_phoneButtons[0]._contact.PassOwner(_player);
_phoneButtons[0]._contact.SetTimer(1.5f);
_phoneButtons[1]._contact._action = new Example2();
_phoneButtons[1]._contact.PassOwner(_player);
_phoneButtons[1]._contact.SetCooldown(15f);
}
public override void _Process(double DELTA_)