mirror of
https://github.com/zoriya/ForecastingVillage.git
synced 2026-05-27 00:23:26 +00:00
Adding a prefab for the load screen
This commit is contained in:
+1
-1
Submodule lib/gamacon updated: f2a99eda8c...67386416c6
@@ -0,0 +1,11 @@
|
||||
<gc_entities>
|
||||
<gc_entity>
|
||||
<transform_component>
|
||||
<Size x="800" y="600" />
|
||||
</transform_component>
|
||||
<renderer src="loading">
|
||||
<Rect height="auto" width="auto" top="0" left="0" />
|
||||
</renderer>
|
||||
<fixed_to_cam x="50%" y="50%" width="100%" height="100%" />
|
||||
</gc_entity>
|
||||
</gc_entities>
|
||||
@@ -2,6 +2,7 @@
|
||||
<data>
|
||||
<sprite name="panel" src="assets/ui/panel.png" />
|
||||
<sprite name="button_background" src="assets/ui/button_background.png" />
|
||||
<sprite name="loading" src="assets/ui/panel.png" />
|
||||
<font src="assets/fonts/roboto.ttf" />
|
||||
</data>
|
||||
<gc_entities>
|
||||
|
||||
+5
-1
@@ -15,7 +15,11 @@
|
||||
bool start_button(gc_engine *engine, gc_entity *entity, gc_vector2 _, \
|
||||
enum gc_mousekeys __)
|
||||
{
|
||||
gc_scene *scene = scene_create(engine, "prefabs/game.gcprefab");
|
||||
gc_scene *scene;
|
||||
|
||||
prefab_load(engine, "prefabs/loading.gcprefab");
|
||||
engine->game_loop(engine, 0);
|
||||
scene = scene_create(engine, "prefabs/game.gcprefab");
|
||||
if (!scene) {
|
||||
engine->should_close = true;
|
||||
my_printf("The game scene couldn't be loaded.\n");
|
||||
|
||||
Reference in New Issue
Block a user