diff options
| author | Xavier Del Campo Romero <xavi.dcr@tutanota.com> | 2022-06-29 01:01:31 +0200 |
|---|---|---|
| committer | Xavier Del Campo Romero <xavi.dcr@tutanota.com> | 2022-06-29 01:01:31 +0200 |
| commit | c4a24800b8566b6e1a0f9888a184ee9e3d5864ac (patch) | |
| tree | 64d2f8f5829f1b259808e06864246ee56d799d1e /src | |
| parent | 391c8958b1f46bbd6e9124004db9ba6deb861f52 (diff) | |
| download | rts-c4a24800b8566b6e1a0f9888a184ee9e3d5864ac.tar.gz | |
menu.c: center play button on screen
Diffstat (limited to 'src')
| -rw-r--r-- | src/menu/src/menu.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/menu/src/menu.c b/src/menu/src/menu.c index 12da1a8..41adbb5 100644 --- a/src/menu/src/menu.c +++ b/src/menu/src/menu.c @@ -27,6 +27,8 @@ int menu(void) play.on_pressed = on_pressed; play.arg = &start; play.w = 140; + play.common.hcentered = true; + play.common.vcentered = true; play.label.text = "Play"; { @@ -44,8 +46,6 @@ int menu(void) peripheral_update(&p); camera_update(&cam, &p); - play.common.x = screen_w / 2 - play.w / 2; - play.common.y = screen_h / 2 - 20; play.label.common.x = play.w / 2 - 20; play.label.common.y = 4; |
