|
1 | | -using System; |
| 1 | +using System; |
2 | 2 | using System.Collections.Generic; |
3 | 3 | using System.Reflection; |
4 | 4 | using ExtLib; |
@@ -84,7 +84,8 @@ public static class Main |
84 | 84 |
|
85 | 85 | {"{Accuracy}", "Accuracy"}, |
86 | 86 | {"{Progress}", "Progress"}, |
87 | | - {"{CheckPointCount}", "Check Point Used Count"} |
| 87 | + {"{CheckPointCount}", "Check Point Used Count"}, |
| 88 | + {"{Timing}", "Hit Timing"} |
88 | 89 | }; |
89 | 90 | public static void UpdateTV() |
90 | 91 | { |
@@ -487,6 +488,8 @@ public void OnChange() |
487 | 488 | public int adecimals = 2; |
488 | 489 | [Draw("보일 소수점 (진행도) Showing Decimals (Progress)")] |
489 | 490 | public int pdecimals = 2; |
| 491 | + [Draw("보일 소수점 (판정 오차) Showing Decimals (Hit Timing)")] |
| 492 | + public int tdecimals = 2; |
490 | 493 | [Draw("죽으면 횟수 초기화")] |
491 | 494 | public bool DeadReset = false; |
492 | 495 | [Draw("메뉴로 나가면 초기화")] |
@@ -514,6 +517,21 @@ public void OnChange() |
514 | 517 | } |
515 | 518 | public class Patches |
516 | 519 | { |
| 520 | + [HarmonyPatch(typeof(scrPlanet), "SwitchChosen")] |
| 521 | + public static class TimingP |
| 522 | + { |
| 523 | + public static void Postfix(scrPlanet __instance) |
| 524 | + { |
| 525 | + if (__instance.controller.gameworld) |
| 526 | + { |
| 527 | + Main.TagValues["{Timing}"] = Math.Round((__instance.angle - __instance.targetExitAngle) * (__instance.controller.isCW ? 1.0 : -1.0) * 60000.0 / (3.1415926535897931 * (double)__instance.conductor.bpm * __instance.controller.speed * (double)__instance.conductor.song.pitch), Main.Set.tdecimals).ToString(); |
| 528 | + } |
| 529 | + else |
| 530 | + { |
| 531 | + Main.TagValues["{Timing}"] = 0.ToString(); |
| 532 | + } |
| 533 | + } |
| 534 | + } |
517 | 535 | public static Patches instance; |
518 | 536 | public static HitMargin GetHitMargin(float angle) |
519 | 537 | { |
|
0 commit comments