Skip to content

Commit

Permalink
Merge pull request #1 from Wolferacing/master
Browse files Browse the repository at this point in the history
Wolf update 1, see changelog for info.
  • Loading branch information
rolopogo authored Apr 10, 2019
2 parents c4b91ec + 89f6f8a commit 885c892
Show file tree
Hide file tree
Showing 85 changed files with 16,385 additions and 2,688 deletions.
3 changes: 2 additions & 1 deletion Assets/Cue.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,15 @@

public enum TargetHandType { Either = 0, Right = 1, Left = 2, None = 3 }
public enum TargetBehavior { Standard = 0, Vertical = 1, Horizontal = 2, Hold = 3, ChainStart = 4, Chain = 5, Melee = 6 }
public enum TargetVelocity { Standard = 20, Vertical = 20, Horizontal = 20, Hold = 20, ChainStart = 1, Chain = 2, Melee = 3 }

[System.Serializable]
public class Cue
{
public int tick;
public int tickLength;
public int pitch;
public int velocity;
public TargetVelocity velocity = TargetVelocity.Standard;
public GridOffset gridOffset = new GridOffset { x = 0, y = 0};
public TargetHandType handType = TargetHandType.Right;
public TargetBehavior behavior = TargetBehavior.Standard;
Expand Down
2 changes: 1 addition & 1 deletion Assets/GridTarget.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
public TargetHandType handType;
public TargetBehavior behavior;
public float beatLength = 1;
public int velocity = 20;
public TargetVelocity velocity;
}
5 changes: 3 additions & 2 deletions Assets/Materials/White.mat
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ Material:
serializedVersion: 6
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: White
m_Shader: {fileID: 10770, guid: 0000000000000000f000000000000000, type: 0}
m_ShaderKeywords:
Expand Down Expand Up @@ -79,5 +80,5 @@ Material:
- _UseUIAlphaClip: 0
- _ZWrite: 1
m_Colors:
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _Color: {r: 1, g: 0.910701, b: 0, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
10 changes: 10 additions & 0 deletions Assets/NoteGrid.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.EventSystems;

public class NoteGrid : MonoBehaviour {

Expand All @@ -24,6 +25,9 @@ private void Update()
{
if (hover)
{
if (EventSystem.current.IsPointerOverGameObject())
return;

var mousePos = Camera.main.ScreenToWorldPoint(Input.mousePosition);
mousePos = SnapToGrid(mousePos);
var ghostPos = ghost.position;
Expand All @@ -33,12 +37,18 @@ private void Update()

if (Input.GetMouseButtonDown(0))
{
if (EventSystem.current.IsPointerOverGameObject())
return;

timeline.AddTarget(mousePos.x, mousePos.y);
}
}

if (Input.GetMouseButtonDown(1))
{
if (EventSystem.current.IsPointerOverGameObject())
return;

timeline.DeleteTarget(NoteUnderMouse());
}

Expand Down
Loading

0 comments on commit 885c892

Please sign in to comment.