Render x/y for UI elements.

This commit is contained in:
2021-09-03 19:02:37 -07:00
parent 4b55ec7b93
commit c0d13042b4
32 changed files with 196 additions and 155 deletions

View File

@ -38,12 +38,13 @@
#include "game/dawn/dawngame.h"
#include "game/poker/ui/pokerplayerui.h"
#include "game/poker/ui/pokerui.h"
#include "game/poker/pokerdiscussion.h"
#include "game/poker/pokergame.h"
#include "game/poker/pokergameaction.h"
#include "game/poker/pokergameassets.h"
#include "game/poker/pokerworld.h"
#include "game/poker/pokerui.h"
// Player Input
#include "input/input.h"

View File

@ -10,8 +10,8 @@
#include "../../display/animation/queue.h"
#include "pokergameassets.h"
#include "pokerworld.h"
#include "pokerui.h"
#include "pokergameaction.h"
#include "ui/pokerui.h"
#include "../../poker/poker.h"
#include "../../poker/player.h"
#include "../../poker/dealer.h"

View File

@ -1,20 +0,0 @@
/**
* Copyright (c) 2021 Dominic Masters
*
* This software is released under the MIT License.
* https://opensource.org/licenses/MIT
*/
#pragma once
#include "../../libs.h"
#include "../../ui/label.h"
#include "../../poker/player.h"
typedef struct {
label_t labelInfo;
} pokerplayerui_t;
typedef struct {
pokerplayerui_t players[POKER_PLAYER_COUNT];
label_t labelGameInfo;
} pokerui_t;

View File

@ -0,0 +1,14 @@
/**
* Copyright (c) 2021 Dominic Masters
*
* This software is released under the MIT License.
* https://opensource.org/licenses/MIT
*/
#pragma once
#include "../../../libs.h"
#include "../../../ui/label.h"
typedef struct {
label_t label;
} pokerplayerui_t;

View File

@ -0,0 +1,15 @@
/**
* Copyright (c) 2021 Dominic Masters
*
* This software is released under the MIT License.
* https://opensource.org/licenses/MIT
*/
#pragma once
#include "../../../libs.h"
#include "../../../poker/player.h"
#include "pokerplayerui.h"
typedef struct {
pokerplayerui_t player[POKER_PLAYER_COUNT];
} pokerui_t;

View File

@ -18,7 +18,6 @@
#define FRAME_PRIMITIVE_COUNT 9
typedef struct {
float x, y;
texture_t *texture;
primitive_t primitive;
} frame_t;

View File

@ -10,7 +10,6 @@
#include "../display/primitive.h"
typedef struct {
float x, y;
texture_t *texture;
primitive_t quad;
float u0, v0;

View File

@ -13,7 +13,6 @@
/** Representation of a Label UI Element */
typedef struct {
font_t *font;
float x, y;
float fontSize;
fonttextinfo_t info;
primitive_t primitive;

View File

@ -25,7 +25,6 @@ typedef void menulistcallback_t(menulist_t *list, uint8_t i, void *user);
/** Representation of a menu list, a menu with multiple menu items. */
typedef struct _menulist_t {
float x, y;
char *items[MENULIST_ITEMS_MAX];
label_t labels[MENULIST_ITEMS_MAX];
frame_t frame;

View File

@ -10,7 +10,6 @@
#include "../display/primitive.h"
typedef struct {
float x, y;
float width, height;
texture_t texture;
primitive_t quad;

View File

@ -33,9 +33,6 @@ typedef struct {
int32_t linesMax;
int32_t lineCurrent;
/** X, Y Position of the textbox */
float x, y;
/** Readonly values for the dimensions of the textbox */
float width, height;