- 博客(9)
- 资源 (1)
- 收藏
- 关注
转载 建立双链表
#include typedef struct student { int data; struct student *next; struct student *pre; }dnode; // 建立双链表 dnode *creat() { dnode *head, *p, *s; int x, cycle = 1; head = (dnode *)malloc(sizeof(
2016-02-19 22:06:24 357
转载 struct和typedef struct彻底明白了
http://www.cnblogs.com/qyaizs/articles/2039101.html struct和typedef struct 分三块来讲述: 1 首先://注意在C和C++里不同 在C中定义一个结构体类型要用typedef: typedef struct Student { int a; }Stu;
2016-02-19 22:02:41 386 1
转载 EOF在C++中的定义为:const int EOF = -1;
它这么定义是有道理的: 举个例子来说 int ch; //注意:这里定义了ch是int型的,而不是char型的 while((ch = cin.get()) != EOF) { cout } cin.get()是读取输入流中的一个字节,但是时常忽略的,也是必须注意的是:那些C++的设计者们将cin.get()设计成返回int型,而不是char型,这不是令人挺奇怪的吗?感觉char
2016-02-19 19:31:16 714
原创 光源旋转照射游戏角色
using UnityEngine; using System.Collections; public class RotateAround : MonoBehaviour { public Transform target; public float speed; // Use this for initialization void Start () { } // U
2016-02-19 17:20:25 522 1
转载 Setting the parent of a transform which resides in a prefab is disabled to prevent data corruption
http://www.ceeger.com/forum/read.php?tid=18880 Setting the parent of a transform which resides in a prefab is disabled to prevent data corruption. 导致问题原因是,用Resouce.Load加载一个prefab,没有实例化直接设置parent
2016-02-17 17:39:22 6346
转载 下面的两种方法都能够将Sphere变为Cube 父节点元素
http://jingyan.baidu.com/article/3065b3b681e0b1becff8a40f.html
2016-02-17 17:38:17 564
原创 AssetBundleBuild 关于打包与加载
一,打包资源 Editor文件夹下 Packing.cs using UnityEngine; using System.Collections; // using UnityEditor; using System.Collections.Generic; // 加了一个容器 List public class Packing { // 编辑器扩展不继承于MonoBehavio
2016-02-15 20:57:38 9123 3
原创 Unity编辑器扩展
*.cs文件必须位于Editor文件夹下 using UnityEngine; using System.Collections; // using UnityEditor; public class Packing { // 编辑器扩展不继承于MonoBehaviour [MenuItem("Packing/Make AssetsBundle")] static void
2016-02-15 17:15:46 376
原创 Unity3d中加载资源prefab的方法
using UnityEngine; using System.Collections; // using UnityEditor; // AssetDatabase public class LoadResource : MonoBehaviour { // Use this for initialization void Start () { /*
2016-02-15 16:47:47 10971
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人