Skip to content

Commit 44cbe86

Browse files
committed
0.0.3
Added Capture Card Settings
1 parent e73b321 commit 44cbe86

File tree

847 files changed

+245109
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

847 files changed

+245109
-0
lines changed

Assets/Capture.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.

Assets/Capture/Animations.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.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
using System.Collections;
2+
using System.Collections.Generic;
3+
using UnityEngine;
4+
5+
public class ButtonClickAnimation : MonoBehaviour
6+
{
7+
public GameObject button;
8+
public void onButtonClickAnimation()
9+
{
10+
LeanTween.cancel(gameObject);
11+
button.transform.localScale = Vector3.zero;
12+
}
13+
}

Assets/Capture/Animations/ButtonClickAnimation.cs.meta

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

Assets/Capture/Animations/InfoScreen.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.
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
using UnityEngine;
2+
3+
/*
4+
* This class is the new Animator for the CaptureCardSettings and Infp UI.
5+
* i will also add this class to the Normal Settings UI but right now im to lazy tbh
6+
*
7+
* i use the LeanTween library for animation
8+
*/
9+
public class ScreenAnimation : MonoBehaviour
10+
{
11+
public GameObject startAnimationPoint;
12+
public GameObject endAnimationPoint;
13+
14+
public float time = 0.15f;
15+
public void show(bool show)
16+
{
17+
if (!show)
18+
{
19+
stopAnimation();
20+
return;
21+
}
22+
startAnimation();
23+
}
24+
25+
private void startAnimation()
26+
{
27+
LeanTween.cancel(gameObject);
28+
gameObject.SetActive(true);
29+
Vector3 vector3 = transform.position;
30+
vector3.y = startAnimationPoint.transform.position.y;
31+
transform.position = vector3;
32+
33+
LeanTween.move(gameObject, endAnimationPoint.transform.position, time);
34+
}
35+
36+
private void stopAnimation()
37+
{
38+
if (gameObject.active)
39+
{
40+
LeanTween.cancel(gameObject);
41+
LeanTween.move(gameObject, startAnimationPoint.transform.position, time).setOnComplete(hideSettingsMenu);
42+
}
43+
}
44+
45+
private void hideSettingsMenu()
46+
{
47+
gameObject.SetActive(false);
48+
}
49+
}
50+

Assets/Capture/Animations/InfoScreen/ScreenAnimation.cs.meta

Lines changed: 11 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
using System.Collections;
2+
using System.Collections.Generic;
3+
using UnityEngine;
4+
5+
6+
/*
7+
* This is the OLD Animation class that is currently used for the Normal Settings UI. In the future it gets replaced by the new Animation class
8+
*/
9+
public class SettingsAnimation : MonoBehaviour
10+
{
11+
public void showSettings(bool show)
12+
{
13+
if (!show)
14+
{
15+
stopAnimation();
16+
return;
17+
}
18+
startAnimation();
19+
}
20+
21+
private void startAnimation()
22+
{
23+
LeanTween.cancel(gameObject);
24+
gameObject.SetActive(true);
25+
Vector3 vector3 = transform.position;
26+
vector3.x = -512f;
27+
transform.position = vector3;
28+
29+
LeanTween.moveX(gameObject, 0f, 0.15f);
30+
}
31+
32+
private void stopAnimation()
33+
{
34+
LeanTween.cancel(gameObject);
35+
LeanTween.moveX(gameObject, -512f, 0.15f).setOnComplete(hideSettingsMenu);
36+
}
37+
38+
private void hideSettingsMenu()
39+
{
40+
gameObject.SetActive(false);
41+
}
42+
}

Assets/Capture/Animations/SettingsAnimation.cs.meta

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

Assets/Capture/Images.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)