博客
关于我
unity OnTriggerEnter碰撞器
阅读量:577 次
发布时间:2019-03-11

本文共 453 字,大约阅读时间需要 1 分钟。

 

 

using System.Collections;using System.Collections.Generic;using UnityEngine;public class tig : MonoBehaviour{    // Start is called before the first frame update    void Start()    {            }    // Update is called once per frame    void Update()    {            }    //进入碰撞器    void OnTriggerEnter(Collider collider) {        if (collider.gameObject.tag == "Player") {            transform.FindChild("door").SendMessage("doorcheck");        }    }}

 

转载地址:http://wmhvz.baihongyu.com/

你可能感兴趣的文章
MySQL之2003-Can‘t connect to MySQL server on ‘localhost‘(10038)的解决办法
查看>>
MySQL之CRUD
查看>>
MySQL之DML
查看>>
Mysql之IN 和 Exists 用法
查看>>
Mysql之主从复制
查看>>
mysql之分组查询GROUP BY,HAVING
查看>>
mysql之分页查询
查看>>
Mysql之备份与恢复
查看>>
mysql之子查询
查看>>
MySQL之字符串函数
查看>>
mysql之常见函数
查看>>
Mysql之性能优化--索引的使用
查看>>
mysql之旅【第一篇】
查看>>
Mysql之索引选择及优化
查看>>
mysql之联合查询UNION
查看>>
mysql之连接查询,多表连接
查看>>
mysql乱码
查看>>
Mysql事务。开启事务、脏读、不可重复读、幻读、隔离级别
查看>>
MySQL事务与锁详解
查看>>
MySQL事务原理以及MVCC详解
查看>>