Update KekEngine

This commit is contained in:
MrLetsplay 2023-12-23 23:25:59 +01:00
parent bb98a34cb6
commit bbb720af79
Signed by: mr
SSH Key Fingerprint: SHA256:92jBH80vpXyaZHjaIl47pjRq+Yt7XGTArqQg1V7hSqg
2 changed files with 4 additions and 4 deletions

@ -1 +1 @@
Subproject commit 81ea6e0dc52e7dc5055c5f5b8e445d1e21a6e027
Subproject commit 3051fbd3b924c13ceeb06305be9420cbec69970a

View File

@ -51,7 +51,7 @@ Mesh *floorMesh;
TextElement *debugText;
std::shared_ptr<Texture> red, gray, white, wallpaper;
void gameLoop(GLFWwindow *window, void *) {
void gameLoop(kek::PeriodicEvent event) {
Player *player = Engine::getPlayer();
Camera *camera = Engine::getActiveCamera();
glm::vec3 playerPos = player->getPosition();
@ -147,7 +147,7 @@ void gameLoop(GLFWwindow *window, void *) {
}
}
void startGame(void *) {
void startGame() {
buttonPlay->visible = false;
Scene *scene = new Scene();
@ -160,7 +160,7 @@ void startGame(void *) {
flashlight = new SpotLight(glm::vec3(1), glm::vec3(0), 2, 3, 5, 0.5, 0.6);
flashlight->moveTo(Engine::getPlayer()->getPosition() + glm::vec3(0, KEK_PLAYER_EYE_OFFSET, 0));
Input::addPeriodicCallback(PeriodicCallback(gameLoop, nullptr));
Input::addPeriodicCallback(PeriodicCallback(gameLoop));
std::shared_ptr<Texture> cubeTexture = Texture::generateColor(glm::vec3(1, 0, 0));
GameObject *floorObject = new GameObject();