Basic stubs for graphical output and UDP thread.

This commit is contained in:
2023-07-02 13:23:07 +01:00
parent 39ce546015
commit e3b3ce4582
5 changed files with 209 additions and 17 deletions

25
src/cspt-state.h Normal file
View File

@ -0,0 +1,25 @@
#ifndef CSPT_STATE_H
#define CSPT_STATE_H
#include <time.h>
#include <stdbool.h>
struct clientMovement
{
double xPosition, yPosition, xVelocity, yVelocity;
bool leftAcceleration, rightAcceleration, upAcceleration, downAcceleration, registered;
};
struct clientInput
{
bool left, right, up, down;
};
struct gameState
{
time_t timestamp;
struct clientMovement clients[16];
};
void doGameTick(struct gameState * state);
#endif