Commit 5d59739a authored by 16이상민's avatar 16이상민

Modified judging machanism

parent fca95994
...@@ -29,13 +29,13 @@ namespace JudgeModule ...@@ -29,13 +29,13 @@ namespace JudgeModule
private string[] notenames private string[] notenames
= new string[] { "SBT", "LBT", "SMO", "LMO" }; = new string[] { "SBT", "LBT", "SMO", "LMO" };
public Note Current public Note CurrentBT
{ {
get get
{ {
float timing = 0; float timing = 0;
string type = null; string type = null;
foreach (var x in notenames) foreach (var x in new string[] { "SBT", "LBT" })
{ {
if (enables[x].Count == 0) if (enables[x].Count == 0)
continue; continue;
...@@ -47,9 +47,23 @@ namespace JudgeModule ...@@ -47,9 +47,23 @@ namespace JudgeModule
} }
} }
if (type == null) return type == null ? null : enables[type][0].Instance;
return null; }
return enables[type][0].Instance; }
public Note CurrentSMO
{
get
{
return enables["SMO"].Count == 0 ? null : enables["SMO"][0].Instance;
}
}
public Note CurrentLMO
{
get
{
return enables["LMO"].Count == 0 ? null : enables["LMO"][0].Instance;
} }
} }
......
...@@ -143,7 +143,13 @@ public class InGameManager : MonoBehaviour ...@@ -143,7 +143,13 @@ public class InGameManager : MonoBehaviour
return; return;
} }
Note note = notemanager.Current; JudgeNote(notemanager.CurrentBT, timing);
JudgeNote(notemanager.CurrentSMO, timing);
JudgeNote(notemanager.CurrentLMO, timing);
}
private void JudgeNote(Note note, float timing)
{
if (note != null) if (note != null)
judgemanager.JudgeNote(note, timing); judgemanager.JudgeNote(note, timing);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment