22 lines
701 B
C#
22 lines
701 B
C#
using System;
|
|
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
/*******************************************************************************
|
|
*Create By CG
|
|
*Function 给每个子物体添加碰撞器后,触发后引起父物体相应,此处为添加到父物体的相应脚本
|
|
*******************************************************************************/
|
|
namespace ZXK.GYJQR
|
|
{
|
|
public class ItemTriCtrl : MonoBehaviour
|
|
{
|
|
public void TriCallAction(Action<GameObject> triHandle)
|
|
{
|
|
triHandle?.Invoke(gameObject);
|
|
}
|
|
public void TriCall(bool lightAble)
|
|
{
|
|
gameObject.GetComponent<OutLineRender>().enabled = lightAble;
|
|
}
|
|
}
|
|
} |