summaryrefslogtreecommitdiff
path: root/GameCode/Zip.cs
blob: 1f2c02cd2dd8f485d4210d1035a029bb27d855d3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
using UnityEngine;

public class Zip : MonoBehaviour
{
	public float multiplier = 1f;

	public float turn = 0.2f;

	private float count;

	private int up = 1;

	private void Start()
	{
	}

	private void Update()
	{
		count += TimeHandler.deltaTime;
		if (count > turn)
		{
			count = 0f;
			up *= -1;
		}
		base.transform.root.position += base.transform.up * multiplier * up * Time.smoothDeltaTime;
	}
}