summaryrefslogtreecommitdiff
path: root/Client/Assets/Scripts/XTerritoryOpenUI.cs
blob: 2ed8db2ec927854a0c272c829948a1fc0dd58c8a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
using UnityEngine;
using System.Collections;
using XUtliPoolLib;

public class XTerritoryOpenUI : MonoBehaviour
{
    private IXPlayerAction _uiOperation;

    public int index = 0;

    void OnTriggerEnter(Collider c)
    {
        ///if (c.gameObject.CompareTag("Player"))
        if (c.gameObject.layer == LayerMask.NameToLayer("Player"))
        {
            if (_uiOperation == null || _uiOperation.Deprecated)
                _uiOperation = XInterfaceMgr.singleton.GetInterface<IXPlayerAction>(1);

            if (_uiOperation != null) _uiOperation.GotoTerritoryBattle(index);
        }
    }
}