refactor interact system

interact only after PopupItemMenu button clicked
This commit is contained in:
Vova
2023-11-16 16:11:39 +02:00
parent c2bb35a46d
commit 1774ab5b18
12 changed files with 100 additions and 61 deletions
+3 -3
View File
@@ -14,11 +14,11 @@ public class Door : BaseInteractableObject
print($"Player came from to {_scene}");
Player.Instance.SetPosition(_interactionPoint.position);
}
}
public override void Interact(Player player)
{
base.Interact(player);
protected override void InteractAction()
{
if (!string.IsNullOrEmpty(_exitName))
{
PlayerPrefs.SetString("lastExitName", _exitName.ToLower());