33 lines
817 B
C#
33 lines
817 B
C#
using Spine.Unity;
|
|
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
using UnityEngine.UI;
|
|
|
|
public class TurretData : MonoBehaviour
|
|
{
|
|
public string turretID;
|
|
public int turretLevel;
|
|
public SitPosData setPosData;
|
|
public Button btn_AddTurretNum;
|
|
public Button btn_SubTractTurretNum;
|
|
|
|
public GameObject bulletPrefab;
|
|
public GameObject bulletPrefab_Two;
|
|
public Transform tra_BulletStartPosition;
|
|
public GameObject obj_Animation;
|
|
public string startTurret;
|
|
public void OnEnable()
|
|
{
|
|
foreach (var item in GetComponentsInChildren<SkeletonGraphic>())
|
|
{
|
|
if (item.gameObject.activeSelf)
|
|
{
|
|
item.AnimationState.SetAnimation(0, startTurret, false);
|
|
}
|
|
|
|
}
|
|
}
|
|
|
|
}
|