1. Introduction
1. Course Introduction
2. Preparation
1. Unity and Visual Studio Installation
2. SourceTree Installation and Using SourceTree With The Supplied Unity Project
3. Game Architecture and Course Structure Overview
4. Project Setup
1. Project Creation
需要安装的插件((windows->package manager))
导入课程资源包
setting
scene
创建相机
2. Review Custom Package
5. Player Basics
1. Player Gameobject Set-Up
2. Player Class and Abstract Singleton Class
using UnityEngine;
public abstract class SingletonMonobehaviour<T> : MonoBehaviour where T : MonoBehaviour
{
private static T _instance;
public static T Instance
{
get { return _instance; }
}
protected void Awake()
{
if (_instance == null)
{
_instance = this as T;
}
else
{
// 销毁之前的实例
Destroy(gameObject);
}
}
}
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class Player : SingletonMonobehaviour<Player>
{
}
3. Player Animation Controllers
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class MovementAnimationParameterController : MonoBehaviour
{
private void AnimationEventPlayFootstepSound()
{
}
}