diff --git a/game.h b/game.h new file mode 100644 index 0000000000000000000000000000000000000000..51074e9f4bab444b846bb8f16f638ec062a433fb --- /dev/null +++ b/game.h @@ -0,0 +1,23 @@ +#ifndef GAME_H +#define GAME_H + +#include "raylib.h" + +typedef struct Paddle { + Rectangle rect; + int speed; +} Paddle; + +typedef struct Ball { + Vector2 position; + Vector2 speed; + int radius; +} Ball; + +Paddle *CreatePaddle(float x, float y, float width, float height, int speed); +Ball *CreateBall(float x, float y, int radius, float speedX, float speedY); +void UpdateBall(Ball *ball, Paddle *paddle); +void DrawGame(Paddle *paddle, Ball *ball); +void FreeGame(Paddle *paddle, Ball *ball); + +#endif