1
0
forked from cgvr/DeltaVR

NPCs move quest marker around to next objectives

This commit is contained in:
2026-02-12 15:54:01 +02:00
parent 3d804dfdaf
commit cf709f4dc9
5 changed files with 29 additions and 3 deletions

View File

@@ -7,11 +7,13 @@ using System.Threading.Tasks;
public class ArcheryRangeNPC : NPCController
{
[Header("Archery Range Config")]
public QuestMarker questMarker;
public MicrophoneStand microphoneStand;
public PushableButton imageGenerationButton;
public PushableButton modelGenerationButton;
public Image imageDisplay;
public ModelDisplay modelDisplay;
public Transform startTarget;
private Texture2D GeneratedTexture;
private EventInstance printingSound;
@@ -44,11 +46,14 @@ public class ArcheryRangeNPC : NPCController
{
if (state == 0)
{
questMarker.gameObject.SetActive(false);
SpeakVoiceLine(0);
await Task.Delay(2000);
SpeakVoiceLine(1);
await Task.Delay(6500);
SpeakVoiceLine(2);
questMarker.gameObject.SetActive(true);
questMarker.MoveTo(microphoneStand.transform);
await Task.Delay(3000);
state = 1;
@@ -65,6 +70,7 @@ public class ArcheryRangeNPC : NPCController
if (state == 1)
{
SpeakVoiceLine(3);
questMarker.MoveTo(imageGenerationButton.transform);
state = 2;
}
}
@@ -87,6 +93,7 @@ public class ArcheryRangeNPC : NPCController
{
modelGenerationButton.Deactivate();
SpeakVoiceLine(4);
questMarker.MoveTo(modelGenerationButton.transform);
}
}
@@ -109,6 +116,7 @@ public class ArcheryRangeNPC : NPCController
if (state == 4)
{
SpeakVoiceLine(5);
questMarker.MoveTo(startTarget);
state = 5;
}