码迷,mamicode.com
首页 > 编程语言 > 详细

Unity Panel open & close

时间:2016-04-17 17:37:25      阅读:208      评论:0      收藏:0      [点我收藏+]

标签:

Making a Popup and Closable Panel in Unity 5

script:

public GameObject thePanel;

public open()

{

     thePannel.SetActive(true);

}

 

 

public open()

{

     thePannel.SetActive(false);

}

and add the up script to an Empty Object

 

add open/close button on the scene.

define open/close button onClick() function to call script‘s open/close function.

 

Unity Panel open & close

标签:

原文地址:http://www.cnblogs.com/wiessharling/p/5401349.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!