mirror of
https://github.com/frizbee19/FebGameJam.git
synced 2026-09-11 08:17:01 +00:00
did a minor tweak
This commit is contained in:
1 parent
8f2a693284
commit
11a2af2f5f
302 files changed
+1022
-167
No files matched your search
@@ -0,0 +1,32 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class TextTrigger : Trigger
|
||||
{
|
||||
public GameObject TextBox;
|
||||
// public GameObject HeadBox;
|
||||
public List<string> pages;
|
||||
public List<int> emotes;
|
||||
public RuntimeAnimatorController controller;
|
||||
public Sprite startSprite;
|
||||
public AudioManager audioManager;
|
||||
public bool isTalking;
|
||||
GameObject instance;
|
||||
// GameObject instance;
|
||||
// GameObject headInstance;
|
||||
void Instant() {
|
||||
instance = Instantiate(TextBox, TextBox.transform.position, Quaternion.identity);
|
||||
instance.SetActive(true);
|
||||
instance.GetComponent<Dialogue>().pages = pages;
|
||||
instance.GetComponent<Dialogue>().emotes = emotes;
|
||||
instance.GetComponent<Dialogue>().controller = controller;
|
||||
instance.GetComponent<Dialogue>().audioManager = audioManager;
|
||||
instance.GetComponent<Dialogue>().isOpen = true;
|
||||
instance.GetComponent<Dialogue>().isTalking = isTalking;
|
||||
}
|
||||
public override void Action()
|
||||
{
|
||||
Instant();
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user