Made quest usable
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
using Godot;
|
||||
using System;
|
||||
using Babushka.scripts.CSharp.Common.Quest;
|
||||
|
||||
public partial class PopUpPostIt : Control
|
||||
{
|
||||
private Label Text => GetNode<Label>("Text");
|
||||
|
||||
private AnimationPlayer Animation => GetNode<AnimationPlayer>("AnimationPlayer");
|
||||
|
||||
QuestManager QM => QuestManager.Instance!;
|
||||
public override void _EnterTree()
|
||||
{
|
||||
QM.QuestBecomesActive += NewQuestPostIt;
|
||||
}
|
||||
|
||||
private void NewQuestPostIt(QuestResource questResource)
|
||||
{
|
||||
Text.Text = questResource.title;
|
||||
Animation.Play("NewPostit");
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user