Added Node camera transitions

Fixed Conveyor speedup issue
This commit is contained in:
Jan Groß
2021-06-12 15:28:07 +02:00
parent 4ad82fe684
commit 759cf0a383
10 changed files with 228 additions and 32 deletions

View File

@@ -0,0 +1,21 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class NetworkCamera : MonoBehaviour
{
public Vector3 targetPosition;
public float lerpSpeed = 2;
// Start is called before the first frame update
void Start()
{
targetPosition = transform.position;
}
// Update is called once per frame
void Update()
{
transform.position = Vector3.Lerp(transform.position, targetPosition, Time.deltaTime * lerpSpeed);
}
}