aboutsummaryrefslogtreecommitdiffstats
path: root/src/yabs_core.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/yabs_core.h')
-rw-r--r--src/yabs_core.h35
1 files changed, 8 insertions, 27 deletions
diff --git a/src/yabs_core.h b/src/yabs_core.h
index d8f111d..8ca4cfe 100644
--- a/src/yabs_core.h
+++ b/src/yabs_core.h
@@ -1,6 +1,3 @@
-#ifndef YABS_CORE_H
-#define YABS_CORE_H
-
/*********************************/
/* YABS ( // */
/* yabs_CORE ( )/ */
@@ -9,10 +6,15 @@
/* ()__)____________))))) :^} */
/*********************************/
+#ifndef YABS_CORE_H
+#define YABS_CORE_H
+
#include "raylib.h"
#include "raymath.h"
#include <vector>
+#include "yabs_structs.h"
+
#ifdef __FreeBSD__
# define YABS_SCREENWIDTH 1280
# define YABS_SCREENHEIGHT 720
@@ -43,6 +45,7 @@
CLITERAL(Color) { 153, 0, 0, 255 } // cool Purple
namespace yabs {
+namespace core {
typedef struct Scene3D {
Camera camera;
@@ -61,35 +64,13 @@ typedef enum gameState {
} gameState;
// core functions and structs
-namespace core {
-
-typedef struct Player {
- int hp;
- Vector3 pos;
-}Player;
-
-typedef struct Enemy {
- Vector3 enemyStartPos;
- Vector3 enemyBoxPos;
- Vector3 enemyBoxSize;
- BoundingBox enemyBounds;
- bool active;
-} Enemy;
-
-typedef struct World {
- Model & ground;
- std::vector<Enemy*> enemies;
- Player * player;
-} World;
int reset_camera(Scene3D& scene_3d);
-int draw(World& world);
-int tick(World& world, Scene3D& scene_3d);
+int render(RenderObjs & robjs);
+int tick(TickObjs & tobjs, Scene3D & scene_3d);
void init_game();
-void cleanupAndExit(World & world);
} // namespace core
-
} // namespace yabs
#endif /* YABS_CORE_H */