Ajout de l'order

This commit is contained in:
Tipragot 2023-11-05 09:01:53 +01:00
parent f49eff21df
commit 3374d3dd51

View file

@ -45,7 +45,12 @@ def spawn_all_dialogs(
pygame.mixer.Sound(f"assets/dialogs/{name}/{i}.mp3"), pygame.mixer.Sound(f"assets/dialogs/{name}/{i}.mp3"),
callback=lambda world, entity: entity.destroy(), callback=lambda world, entity: entity.destroy(),
), ),
Text(text, position=Vec2(render.WIDTH / 2, height), origin=Vec2(0.5)), Text(
text,
position=Vec2(render.WIDTH / 2, height),
order=1000,
origin=Vec2(0.5),
),
) )
yield __spawn_all_condition(entity) yield __spawn_all_condition(entity)
yield wait(waiting_between) yield wait(waiting_between)
@ -73,7 +78,12 @@ def spawn_dialog(
pygame.mixer.Sound(f"assets/dialogs/{name}/{index}.mp3"), pygame.mixer.Sound(f"assets/dialogs/{name}/{index}.mp3"),
callback=lambda world, entity: __sound_end(world, entity, callback), callback=lambda world, entity: __sound_end(world, entity, callback),
), ),
Text(text, position=Vec2(render.WIDTH / 2, height), origin=Vec2(0.5)), Text(
text,
position=Vec2(render.WIDTH / 2, height),
order=1000,
origin=Vec2(0.5),
),
) )