added viewable score

This commit is contained in:
Yonokid
2025-08-17 15:17:22 -04:00
parent e3d24f00f9
commit cbcad82604
5 changed files with 85 additions and 20 deletions

View File

@@ -1,6 +1,8 @@
import pyray as ray
from libs.utils import global_data, session_data
from libs.texture import tex
from libs.utils import get_current_ms
from scenes.song_select import ScoreHistory
class DevScreen:
@@ -8,14 +10,16 @@ class DevScreen:
self.width = width
self.height = height
self.screen_init = False
tex.load_screen_textures('song_select')
self.history = ScoreHistory({0: (583892, 0, 0, 0),
1: (234941, 0, 0, 0),
2: (867847, 0, 0, 0),
3: (485589, 0, 0, 0),
4: (1584395, 0, 0, 0)}, get_current_ms())
def on_screen_start(self):
if not self.screen_init:
self.screen_init = True
session_data.result_score = 961000
session_data.result_good = 100
session_data.result_max_combo = 20
session_data.result_total_drumroll = 40
def on_screen_end(self, next_screen: str):
self.screen_init = False
@@ -23,12 +27,12 @@ class DevScreen:
def update(self):
self.on_screen_start()
self.history.update(get_current_ms())
if ray.is_key_pressed(ray.KeyboardKey.KEY_ENTER):
return self.on_screen_end('RESULT')
def draw(self):
pass
self.history.draw()
def draw_3d(self):
pass