// ***********************************************************************
// Assembly : Game
// Author : Kimch
// Created : 2020-09-02
// Description :
// Last Modified By :
// Last Modified On :
// ***********************************************************************
//
//
// ***********************************************************************
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace G
{
public class UI_Ingame : MonoBehaviour
{
public int chamaxhp
{
get;
private set;
}
public int chahp
{
get;
private set;
}
public float chasp
{
get;
private set;
}
public float chamaxsp
{
get;
private set;
}
private bool chargeon;
private bool infinitymode;
public Transform[] cut_extreme = new Transform[2];
private int damagecount;
private float playtime;
private bool general;
private bool generaldead;
private int cur_general = -1;
public bool angelOn;
private float _charge;
private Transform _cha1;
private EntityMainPlayer _scriptCha;
public Joystick joystick
{
get;
set;
}
public Vector2 joystickDirection => joystick.direction;
#region Method
public void GainEquipment(EntityItemEquipment equipment)
{
if (equipment.quality >= 3)
UI.ToastBox.ShowEquipment(equipment.propName, equipment.quality, equipment.propIcon);
UI.QuickBox.ShowEquipment(equipment);
}
public void GainMoney(int id, int amount)
{
var propItem = ItemProxy.Instance.GetStaticItem(id);
if (propItem != null)
{
if (propItem.id ==1)
{
UI.ToastBox.ShowText(F.Utils.Text.Format("获得{0}: {1}", propItem.name, amount.ToString()), 9);
}
else
{
GlobalNotifier.PostNotification(GlobalDefine.EVENT_SHOW_TOAST, F.Utils.Text.Format("获得{0}: {1}", propItem.name, amount.ToString()));
}
}
}
#endregion
#region Unity
public static UI_Ingame Instance;
private void Awake()
{
Instance = this;
}
private void Start()
{
var canvas = GetComponent