Skip to content

Commit 8ae295d

Browse files
committed
Finally fixed the Fader!
1 parent cbc7adc commit 8ae295d

29 files changed

Lines changed: 155 additions & 24 deletions

Packages/Fader v1.5.unitypackage

4 KB
Binary file not shown.
124 KB
Binary file not shown.

Testie/Assets/CrosshairRenderer.cs

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
using System.Collections;
2+
using System.Collections.Generic;
3+
using UnityEngine;
4+
5+
/// <summary>
6+
/// sets Canvas's Camera for camera space resizing
7+
/// </summary>
8+
public class CrosshairRenderer : MonoBehaviour {
9+
10+
11+
void Awake()
12+
{
13+
14+
Canvas canvas = GetComponent<Canvas>();
15+
if (canvas)
16+
{
17+
canvas.worldCamera = Camera.allCameras[0];
18+
canvas.planeDistance = Camera.allCameras[0].nearClipPlane + .01f;
19+
}
20+
21+
}
22+
23+
24+
25+
26+
}

Testie/Assets/CrosshairRenderer.cs.meta

Lines changed: 12 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Testie/Assets/CurveTest.unity

12.2 KB
Binary file not shown.

Testie/Assets/CurveTest.unity.meta

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Testie/Assets/Curvess.cs

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
using System.Collections;
2+
using System.Collections.Generic;
3+
using UnityEngine;
4+
5+
public class Curvess : MonoBehaviour {
6+
7+
//This class will be awesome!
8+
9+
10+
public AnimationCurve curve;
11+
12+
void Update()
13+
{
14+
transform.localScale = new Vector3(curve.Evaluate(Time.time), curve.Evaluate(Time.time), curve.Evaluate(Time.time));
15+
}
16+
17+
18+
}

Testie/Assets/Curvess.cs.meta

Lines changed: 12 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Testie/Assets/New Material.mat

4.91 KB
Binary file not shown.

Testie/Assets/New Material.mat.meta

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)