12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455 |
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- using UnityEngine.UI;
- using UnityGameFramework.Runtime;
- /// <summary>
- /// 场景组件 炸弹
- /// </summary>
- public class SceneEventBombEntryLogic : MonoBehaviour
- {
- private List<Role> roleList;
- private void Awake()
- {
- this.roleList = new List<Role>();
- }
- // Start is called before the first frame update
- void Start()
- {
-
- }
- public List<Role> GetEntryRoleList()
- {
- return this.roleList;
- }
- public void OnTriggerEnter(Collider collider)
- {
- Role newRole = collider.GetComponent<Role>();
- if(newRole)
- {
- roleList.Add(newRole);
- }
-
- }
- public void OnTriggerExit(Collider collider)
- {
- Role newRole = collider.GetComponent<Role>();
- if(newRole)
- {
- roleList.Remove(newRole);
- }
- }
- public void EnableCollider()
- {
- }
- public void OnClickInteractive()
- {
-
- }
- }
|