Skip to content

Commit

Permalink
Move Unity part to its own folder
Browse files Browse the repository at this point in the history
  • Loading branch information
Torbilicious committed Jan 28, 2019
1 parent c7eeaa1 commit fd5ea08
Show file tree
Hide file tree
Showing 963 changed files with 102 additions and 102 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
84 changes: 42 additions & 42 deletions Assets/Scripts/Level.cs → Unity/Assets/Scripts/Level.cs
Original file line number Diff line number Diff line change
@@ -1,42 +1,42 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Level : MonoBehaviour
{
public Dictionary<Vector2, DropTile> _droppedTiles = new Dictionary<Vector2, DropTile>();
public int nextLevel;

public AudioSource bgSound;

public AudioClip dieSound;

private bool diePlayed = false;

// Start is called before the first frame update
void Start()
{
GameState.Reset();
GameState.nexLevel = nextLevel;
_droppedTiles = new Dictionary<Vector2, DropTile>();
diePlayed = false;
}

// Update is called once per frame
void Update()
{
if(bgSound)
{
if(GameState.isDead) {
bgSound.pitch = 0.6f;
if(!diePlayed)
{
AudioSource.PlayClipAtPoint(dieSound,new Vector3(0.0f, 0.0f, -6.0f), 6.5f);
diePlayed = true;
}
} else {
bgSound.pitch = 1.0f;
}
}
}
}
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Level : MonoBehaviour
{
public Dictionary<Vector2, DropTile> _droppedTiles = new Dictionary<Vector2, DropTile>();
public int nextLevel;

public AudioSource bgSound;

public AudioClip dieSound;

private bool diePlayed = false;

// Start is called before the first frame update
void Start()
{
GameState.Reset();
GameState.nexLevel = nextLevel;
_droppedTiles = new Dictionary<Vector2, DropTile>();
diePlayed = false;
}

// Update is called once per frame
void Update()
{
if(bgSound)
{
if(GameState.isDead) {
bgSound.pitch = 0.6f;
if(!diePlayed)
{
AudioSource.PlayClipAtPoint(dieSound,new Vector3(0.0f, 0.0f, -6.0f), 6.5f);
diePlayed = true;
}
} else {
bgSound.pitch = 1.0f;
}
}
}
}
File renamed without changes.
56 changes: 28 additions & 28 deletions Assets/Scripts/NpcLizard.cs → Unity/Assets/Scripts/NpcLizard.cs
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class NpcLizard : MonoBehaviour
{
uint moveCounter = 0;
float randRotScale = 1.0f;
public bool forceShake = false;

// Start is called before the first frame update
void Start()
{
System.Random rnd = new System.Random();
randRotScale = (float)rnd.NextDouble() + 0.8f;
}

// Update is called once per frame
void Update()
{
if(GameState.isDead || forceShake)
{
float rot = (float)Mathf.Sin((float)moveCounter * 0.2f) * randRotScale;
transform.Rotate(0.0f, 0.0f, rot);
++moveCounter;
}
}
}
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class NpcLizard : MonoBehaviour
{
uint moveCounter = 0;
float randRotScale = 1.0f;
public bool forceShake = false;

// Start is called before the first frame update
void Start()
{
System.Random rnd = new System.Random();
randRotScale = (float)rnd.NextDouble() + 0.8f;
}

// Update is called once per frame
void Update()
{
if(GameState.isDead || forceShake)
{
float rot = (float)Mathf.Sin((float)moveCounter * 0.2f) * randRotScale;
transform.Rotate(0.0f, 0.0f, rot);
++moveCounter;
}
}
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;

public class GameOver : MonoBehaviour
{
public GameObject canvas;

// Start is called before the first frame update
void Start()
{

}

// Update is called once per frame
void Update()
{

}

public void Show()
{
canvas.SetActive(true);
}

public void Retry()
{
SceneManager.LoadScene(SceneManager.GetActiveScene().name);
canvas.SetActive(false);
}
}
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;

public class GameOver : MonoBehaviour
{
public GameObject canvas;

// Start is called before the first frame update
void Start()
{

}

// Update is called once per frame
void Update()
{

}

public void Show()
{
canvas.SetActive(true);
}

public void Retry()
{
SceneManager.LoadScene(SceneManager.GetActiveScene().name);
canvas.SetActive(false);
}
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit fd5ea08

Please sign in to comment.