Unity3D学习 愤怒的小鸟之关卡选择界面(六)
2012-07-10 22:26
639 查看
目标:实现关卡选择界面
这一篇里没有新的内容,全是前面5讲知识点的综合,如何用GUITexture做背景,如何用GUISkin做个性化的按钮,如何添加游戏背景音乐,如何修改鼠标样式,这些都是前面提到的知识点,在这里大家用这个界面把之前的都巩固下吧。
OK,运行下试试吧!
源码下载地址: http://download.csdn.net/detail/ariel7321/4421702
这一篇里没有新的内容,全是前面5讲知识点的综合,如何用GUITexture做背景,如何用GUISkin做个性化的按钮,如何添加游戏背景音乐,如何修改鼠标样式,这些都是前面提到的知识点,在这里大家用这个界面把之前的都巩固下吧。
#pragma strict var customSkin : GUISkin; function Start () { } function Update () { } function OnGUI () { GUI.matrix = Matrix4x4.TRS(Vector3.zero, Quaternion.identity, Vector3(Screen.width / 800.0, Screen.height / 600.0, 1)); GUI.skin = customSkin; if (GUI.Button(Rect(125, 100, 150, 150), "", "Level1")) { Application.LoadLevel(3); } if (GUI.Button(Rect(325, 100, 150, 150), "", "Level2")) { } if (GUI.Button(Rect(525, 100, 150, 150), "", "Level3")) { } if (GUI.Button(Rect(125, 300, 150, 150), "", "Level4")) { } if (GUI.Button(Rect(325, 300, 150, 150), "", "Level5")) { } if (GUI.Button(Rect(525, 300, 150, 150), "", "Level6")) { } if (GUI.Button(Rect(70, 500, 100, 80), "", "Back")) { Application.LoadLevel(1); } }
OK,运行下试试吧!
源码下载地址: http://download.csdn.net/detail/ariel7321/4421702
相关文章推荐
- Unity3D学习 愤怒的小鸟之Play界面(四)
- Unity3D学习 愤怒的小鸟之用Plane制作关卡1背景(七)
- Unity3D学习 愤怒的小鸟之Play界面(三)
- Unity3D学习 愤怒的小鸟之Play界面(二)
- Unity3D学习 愤怒的小鸟之Play界面(五)
- Unity3D学习 愤怒的小鸟之Logo界面(一)
- cocos2d-x 3.0游戏实例学习笔记《卡牌塔防》第一步---开始界面&关卡选择
- Unity3D笔记 愤怒的小鸟<四> 实现Selelction界面
- Unity3D学习——(二)愤怒的小鸟项目总结
- Unity3D笔记 愤怒的小鸟<三> 实现Play界面2
- cocos2d-x 3.0游戏实例学习笔记《卡牌塔防》第一步---開始界面&关卡选择
- Unity3D笔记 愤怒的小鸟<二> 实现Play界面
- Unity3D自学笔记——架构应用(二)选择英雄界面
- Unity3D游戏-愤怒的小鸟游戏源码和教程(二)
- 【Cocos2d-x for WP8 学习整理】(3)CCScrollView 实现捕鱼达人一样的场景选择界面
- Cocos2d-JS中使用CocosStudio资源——关卡选择界面
- coco2d-x CCScrollView实现关卡选择 新手引导 帮助界面
- Unity3D学习之界面编辑器(一)
- 五,一个可以左右滑动的关卡选择界面
- unity3D游戏之昆仑游戏获[愤怒的小鸟]IP开发授权