Installed book plugin, fixed compiler errors
This commit is contained in:
34
Assets/External/Book-Page Curl Pro/Examples/scripts/BotAnimationControl.cs
vendored
Normal file
34
Assets/External/Book-Page Curl Pro/Examples/scripts/BotAnimationControl.cs
vendored
Normal file
@@ -0,0 +1,34 @@
|
||||
using UnityEngine;
|
||||
using System.Collections;
|
||||
|
||||
namespace BookCurlPro.Examples
|
||||
{
|
||||
public class BotAnimationControl : MonoBehaviour
|
||||
{
|
||||
|
||||
public Animator anim;
|
||||
// Use this for initialization
|
||||
void Start()
|
||||
{
|
||||
if (!anim)
|
||||
anim = GetComponent<Animator>();
|
||||
}
|
||||
public void Close()
|
||||
{
|
||||
anim.ResetTrigger("Open");
|
||||
anim.ResetTrigger("Close");
|
||||
anim.SetTrigger("Close");
|
||||
}
|
||||
public void Open()
|
||||
{
|
||||
anim.ResetTrigger("Close");
|
||||
anim.ResetTrigger("Open");
|
||||
anim.SetTrigger("Open");
|
||||
}
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user