自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(16)
  • 收藏
  • 关注

原创 Editor中侦听 Hierarchy 中发生变化

当hierarchy 中有物体被创建,重命名,改变父子关系或者被销毁时EditorApplication.hierarchyWindowChangedusing UnityEditor;using UnityEngine;public class ExampleCode { [MenuItem ("Example/Hierarchy Window Changed")

2015-07-22 20:55:10 631

翻译 unity3d calculatepath

NavMesh.CalculatePathpublic static function CalculatePath(sourcePosition:Vector3,targetPosition:Vector3,areaMask: int,path:NavMeshPath): bool; ParameterssourcePos

2015-07-15 12:01:34 1739 1

转载 托管代码 VS 非托管代码

什么是托管代码(managed code)?      托管代码是一microsoft的中间语言(IL),他主要的作用是在.NET   FRAMEWORK的公共语言运行库(CLR)执行代码前去编译源代码,也就是说托管代码充当着翻译的作用,源代码在运行时分为两个阶段:       1.源代码编译为托管代码,(所以源代码可以有很多种,如VB,C#,J#)       2.托管代码编译为micros

2015-07-15 10:43:57 626

转载 IEnumerable与IEnumerator在C#中的使用

一、示例:在C#中,凡是实现了IEnumerator接口的数据类型都可以用foreach语句进行迭代访问,可是,对于自定义类型如何实现这个接口以支持foreach的迭代呢? * 要实现这个功能,先来看看IEnumerable和IEnumerator接口的定义:public interface IEnumerable{      //IEnumerable只有一个方法,返

2015-07-12 14:31:58 365

原创 VS2013 自动生成 get set

private string _value;//定义变量//将上面定义好的变量,用鼠标将private string _value; 这段代码选中,然后按快捷键:Ctrl+r+e,这时会弹出一个小的窗体,直接按确定,再弹出一个小窗体,在按确定。页面上自动会在刚定义的私有变量下出现公有的变量,里面有get、set方面:public string Value{get { return

2015-07-07 15:19:22 1984 1

原创 Unity3D 解锁preview window 随意拖动

在preview window的顶部右键单击就可以解锁所以拖动了

2015-07-07 15:05:13 705

原创 Unity3D Editor在右键弹出菜单中添加 item

[MenuItem("Assets/StuffDoSomething")]    static void DoubleMass(MenuCommand command)    {    }

2015-07-07 14:28:22 2378

转载 Unity3D expand hierachry by code

public static void SetExpandedRecursive(GameObject go, bool expand)    {        var type = typeof(EditorWindow).Assembly.GetType("UnityEditor.SceneHierarchyWindow");        var methodInfo = type

2015-07-07 11:33:34 889

原创 Unity3D Lights

光照的两种方式:  一、基于顶点的。  二、基于像素的。   第一种开销小,但是功能少。第二少开销大,功能多,效果好。  Lights can be rendered using either of two methods:Vertex lighting calculates the illumination only at the vertices

2015-07-06 15:53:31 466

原创 Unity3D 资源路径

On a desktop computer (Mac OS or Windows) the location of the files can be obtained with the following code: path = Application.dataPath + "/StreamingAssets";On iOS, you should use: path =

2015-07-06 11:11:56 398

原创 Unity3D 获得GameObjectHierarchy 中的全路径

方式一、privatestaticstringGetGameObjectPath(Transform transform){string path= transform.name;while(transform.parent!=null){transform = transform.parent;path = transform.name

2015-07-03 09:59:24 3686

原创 unity3D 根据所在文件夹自动设置一些属性

12131415161718usingUnityEngine;usingSystem.Collections;usingUnityEditor;usingSystem.IO; publicclass  Post:AssetPostprocessor

2015-07-02 15:12:43 578

原创 Unity里面三角面数

unity里面三角面数为stats上显示的数值减去2. 可以用一个cube测试。 一个cube 12个三角面。上面显示的14.

2015-07-02 14:19:24 2801

原创 AS3 复制Object

public static function copy(value:Object):Object    {        var buffer:ByteArray = new ByteArray();        buffer.writeObject(value);        buffer.position = 0;        var result:Object =

2015-07-01 18:08:03 489

转载 FLex 4.0 Module里面Alert.show();出错问题

from:http://blog.csdn.net/jiangyu198558/article/details/7004964解决办法:在Application文件里添加import mx.managers.PopUpManager;private var pop:PopUpManager=new PopUpManager();即可同时Alert.show("t

2015-07-01 16:29:39 383

转载 Flex warning: unable to bind to property 'name' on class 'Object' (class is not an IEventDispatcher)

If you have built a custom item renderer for a DataGroup or List you may have come across warnings in your Flash Builder console output similar to this:warning: unable to bind to property

2015-07-01 16:21:18 780

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除