Unity3D 黑暗之光RPG出现的问题
5.63版本密码:cj4g视频及素材仅供学习参考,不得商用,不妥删除1,Water在 Environment 里 Skybox未知在以前项目里导入2,Fog 在Window--Settings里找 NGUI要更新 API3,动画过时public class PlayerAnimation : MonoBehaviour {private PlayerMove mov...4,场景跳转过时
·
5.63版本密码:cj4g视频及素材仅供学习参考,不得商用,不妥删除
1,Water在 Environment 里 Skybox未知在以前项目里导入
2,Fog 在Window--Settings里找 NGUI要更新 API
3,动画过时
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class PlayerAnimation : MonoBehaviour {
private PlayerMove move;
private Animation anim;
void Start () {
move = this.GetComponent<PlayerMove>();
anim = this.GetComponent<Animation>();
}
void LateUpdate () {
if (move.state == PlayerState.Moving)
{
//anim.Play("Run");
PlayAnim("Run");
}
else if (move.state == PlayerState.Idle)
{
//PlayAnim("Idle");
anim.Play("Idle");
}
{
}
}
void PlayAnim(string animName)
{
anim.CrossFade(animName);
}
}
4.场景跳转过时
using UnityEngine.SceneManagement;
SceneManager.LoadScene("three");
更多推荐
已为社区贡献1条内容
所有评论(0)