1.0 release

This commit is contained in:
Anthony Samms
2025-11-20 17:55:57 -05:00
parent 547761eb0d
commit cf2b5f07a6
34 changed files with 1223 additions and 19 deletions

View File

@@ -42,7 +42,7 @@ class DanGameScreen(GameScreen):
logger.info("Loaded nijiiro notes textures")
ray.set_shader_value_texture(self.mask_shader, ray.get_shader_location(self.mask_shader, "texture0"), tex.textures['balloon']['rainbow_mask'].texture)
ray.set_shader_value_texture(self.mask_shader, ray.get_shader_location(self.mask_shader, "texture1"), tex.textures['balloon']['rainbow'].texture)
self.hori_name = OutlinedText(global_data.session_data[global_data.player_num].song_title, 40, ray.WHITE)
self.hori_name = OutlinedText(global_data.session_data[global_data.player_num].song_title, tex.skin_config["dan_title"].font_size, ray.WHITE)
self.init_dan()
self.background = Background(global_data.player_num, self.bpm, scene_preset='DAN')
self.transition = Transition('', '', is_second=True)
@@ -297,7 +297,7 @@ class DanGameScreen(GameScreen):
# Draw exam type and red value counter
red_counter = str(exam_info['red_value'])
self._draw_counter(red_counter, margin=tex.skin_config["dan_score_box_margin"].x, texture='value_counter', index=0, y=y_offset)
tex.draw_texture('dan_info', f'exam_{exam.type}', y=y_offset, x=-len(red_counter)*20)
tex.draw_texture('dan_info', f'exam_{exam.type}', y=y_offset, x=-len(red_counter)*(20 * tex.screen_scale))
# Draw range indicator
if exam.range == 'less':
@@ -383,7 +383,7 @@ class DanGauge(Gauge):
self.gauge_length = self.gauge_max
if int(self.gauge_length * 8) % 8 == 0:
self.visual_length = int(self.gauge_length * 8)
self.visual_length = int(self.gauge_length * tex.textures["gauge_dan"][f'{self.player_num}p_bar'].width)
def add_ok(self):
"""Adds an ok note to the gauge"""
@@ -394,7 +394,7 @@ class DanGauge(Gauge):
self.gauge_length = self.gauge_max
if int(self.gauge_length * 8) % 8 == 0:
self.visual_length = int(self.gauge_length * 8)
self.visual_length = int(self.gauge_length * tex.textures["gauge_dan"][f'{self.player_num}p_bar'].width)
def add_bad(self):
"""Adds a bad note to the gauge"""
@@ -404,7 +404,7 @@ class DanGauge(Gauge):
self.gauge_length = 0
if int(self.gauge_length * 8) % 8 == 0:
self.visual_length = int(self.gauge_length * 8)
self.visual_length = int(self.gauge_length * tex.textures["gauge_dan"][f'{self.player_num}p_bar'].width)
def update(self, current_ms: float):
self.is_rainbow = self.gauge_length == self.gauge_max

View File

@@ -1895,13 +1895,13 @@ class ResultTransition:
if self.player_num == PlayerNum.TWO_PLAYER:
global_tex.draw_texture('result_transition', '1p_shutter', frame=0, x=x, y=-tex.screen_height + self.move.attribute)
global_tex.draw_texture('result_transition', '2p_shutter', frame=0, x=x, y=tex.screen_height - self.move.attribute)
global_tex.draw_texture('result_transition', '1p_shutter_footer', x=x, y=-tex_height + self.move.attribute)
global_tex.draw_texture('result_transition', '2p_shutter_footer', x=x, y=tex.screen_height + tex_height - self.move.attribute)
global_tex.draw_texture('result_transition', '1p_shutter_footer', x=x, y=-(tex_height*3) + self.move.attribute)
global_tex.draw_texture('result_transition', '2p_shutter_footer', x=x, y=tex.screen_height + (tex_height*2) - self.move.attribute)
else:
global_tex.draw_texture('result_transition', f'{self.player_num}p_shutter', frame=0, x=x, y=-tex.screen_height + self.move.attribute)
global_tex.draw_texture('result_transition', f'{self.player_num}p_shutter', frame=0, x=x, y=tex.screen_height - self.move.attribute)
global_tex.draw_texture('result_transition', f'{self.player_num}p_shutter_footer', x=x, y=-tex_height + self.move.attribute)
global_tex.draw_texture('result_transition', f'{self.player_num}p_shutter_footer', x=x, y=tex.screen_height + tex_height - self.move.attribute)
global_tex.draw_texture('result_transition', f'{self.player_num}p_shutter_footer', x=x, y=-(tex_height*3) + self.move.attribute)
global_tex.draw_texture('result_transition', f'{self.player_num}p_shutter_footer', x=x, y=tex.screen_height + (tex_height*2) - self.move.attribute)
x += tex.screen_width // 5
class GogoTime:

View File

@@ -87,20 +87,20 @@ class Background:
self.width = width
def draw(self):
x = 0
footer_height = tex.textures["background"]["footer_1p"].height
footer_height = tex.textures["background"][f"footer_{self.player_num}p"].height
if self.player_num == PlayerNum.TWO_PLAYER:
while x < self.width:
tex.draw_texture('background', 'background_1p', x=x, y=-(tex.screen_height//2))
tex.draw_texture('background', 'background_2p', x=x, y=tex.screen_height//2)
tex.draw_texture('background', 'footer_1p', x=x, y=-footer_height)
tex.draw_texture('background', 'footer_2p', x=x, y=tex.screen_height-footer_height)
tex.draw_texture('background', 'footer_1p', x=x, y=-(footer_height//2))
tex.draw_texture('background', 'footer_2p', x=x, y=tex.screen_height-(footer_height//2))
x += tex.screen_width // 5
else:
while x < self.width:
tex.draw_texture('background', f'background_{self.player_num}p', x=x, y=-(tex.screen_height//2))
tex.draw_texture('background', f'background_{self.player_num}p', x=x, y=(tex.screen_height//2))
tex.draw_texture('background', f'footer_{self.player_num}p', x=x, y=-footer_height)
tex.draw_texture('background', f'footer_{self.player_num}p', x=x, y=tex.screen_height-footer_height)
tex.draw_texture('background', f'footer_{self.player_num}p', x=x, y=-(footer_height//2))
tex.draw_texture('background', f'footer_{self.player_num}p', x=x, y=tex.screen_height-(footer_height//2))
x += tex.screen_width // 5
tex.draw_texture('background', 'result_text')

View File

@@ -958,7 +958,7 @@ class DiffSortSelect:
tex.draw_texture('diff_sort', 'diff', frame=self.selected_box, fade=self.diff_fade_in.attribute)
tex.draw_texture('diff_sort', 'star_num', frame=self.selected_level, fade=self.diff_fade_in.attribute)
for i in range(self.selected_level):
tex.draw_texture('diff_sort', 'star', x=(i*40.5 * tex.screen_scale), fade=self.diff_fade_in.attribute)
tex.draw_texture('diff_sort', 'star', x=(i*(40.5 * tex.screen_scale)), fade=self.diff_fade_in.attribute)
if self.confirmation:
texture = tex.textures['diff_sort']['level_box']