SAIPO 153454f312 修改建议
1.在第一次与父亲对话时加入了对电报机操作的语言
2.在序章中的背景加入视差
3.加入了一个Shake脚本,以提供物体震动(实装到了石堆上面 效果还可以)

4.对检查死亡的机枪手的对话(我不会用fungus哼哼啊啊啊啊)
 1)(已经是一具没有气息的尸体了)
 2)父亲被你们所害,这是你们罪有应得。
2021-09-14 03:08:27 +08:00

39 lines
788 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class Shake : MonoBehaviour
{
public float shakeAmount = 0.05f; //振幅
public bool is_shake;
Vector3 first_pos;
private void Start()
{
first_pos = this.transform.localPosition;
}
public void StartShake()
{
//if (is_shake) return;
is_shake = true;
}
public void Update()
{
if (!is_shake) return;
Vector3 pos = first_pos + Random.insideUnitSphere * shakeAmount;
pos.y = transform.localPosition.y;
transform.localPosition = pos;
}
public void EndShake()
{
is_shake = false;
first_pos.y = transform.localPosition.y;
transform.localPosition = first_pos;
}
}