add:添加石柱,调整第三个和第四个boss
This commit is contained in:
12
Assets/_FutureMen2/Scripts/Player/LookPlayer.cs
Normal file
12
Assets/_FutureMen2/Scripts/Player/LookPlayer.cs
Normal file
@@ -0,0 +1,12 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class LookPlayer : MonoBehaviour
|
||||
{
|
||||
private void OnEnable()
|
||||
{
|
||||
transform.LookAt(GameManager.Ins.player.transform);
|
||||
}
|
||||
}
|
||||
11
Assets/_FutureMen2/Scripts/Player/LookPlayer.cs.meta
Normal file
11
Assets/_FutureMen2/Scripts/Player/LookPlayer.cs.meta
Normal file
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 52207f12addcf354380218a5cda9debc
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -2,6 +2,8 @@ using System;
|
||||
using System.Collections.Generic;
|
||||
using DragonLi.Core;
|
||||
using DragonLi.Frame;
|
||||
using Pathfinding;
|
||||
using Pathfinding.RVO;
|
||||
using UnityEngine;
|
||||
using UnityEngine.XR;
|
||||
using Random = UnityEngine.Random;
|
||||
@@ -18,6 +20,10 @@ public class Player : MonoBehaviour
|
||||
public Transform LeftHand;
|
||||
public Transform RightHand;
|
||||
|
||||
[Header("导航")]
|
||||
public RVOController rvo;
|
||||
public AIPath aiPath;
|
||||
|
||||
[Header("玩家最大血量")]
|
||||
private float maxHp = 50;
|
||||
private float currentHp;
|
||||
@@ -206,6 +212,12 @@ public class Player : MonoBehaviour
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
public void SetAiPath(bool isShow)
|
||||
{
|
||||
aiPath.enabled = isShow;
|
||||
rvo.enabled = isShow;
|
||||
}
|
||||
|
||||
#region 后坐力与切换
|
||||
|
||||
|
||||
Reference in New Issue
Block a user