From 96b7a7205751c76f74d6a5fecb3b5b2ff168b9cd Mon Sep 17 00:00:00 2001 From: nathan Date: Sat, 20 Sep 2025 14:27:00 -0600 Subject: Flat is flat --- src/entity.c | 2 +- src/world.c | 10 ++++++---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/entity.c b/src/entity.c index bc6bb99..8de3eab 100644 --- a/src/entity.c +++ b/src/entity.c @@ -79,7 +79,7 @@ Entity createEntity(EntityId id, Vector3 position) void updateEntity(Entity* entity, Game* game) { - DrawBoundingBox(entity->box, RED); + //DrawBoundingBox(entity->box, RED); switch (entity->id) { diff --git a/src/world.c b/src/world.c index a32bec2..74c5fec 100644 --- a/src/world.c +++ b/src/world.c @@ -489,12 +489,14 @@ void generateWorldSamanthasPlace(World* world, Color* heightmap, WorldUID* placeId) { // Make area flat. - float width = WORLD_IMAGE_WIDTH / world->size.x * SAMANTHAS_SPOT_SIZE; - float height = WORLD_IMAGE_HEIGHT / world->size.z * SAMANTHAS_SPOT_SIZE; + float width = SAMANTHAS_SPOT_SIZE * (WORLD_IMAGE_WIDTH / world->size.x) + * 2.0; + float height = SAMANTHAS_SPOT_SIZE * (WORLD_IMAGE_HEIGHT / world->size.z) + * 2.0; Rectangle area = (Rectangle){ - .x = WORLD_IMAGE_WIDTH / 2.0 - width, - .y = WORLD_IMAGE_HEIGHT / 2.0 - height, + .x = WORLD_IMAGE_WIDTH / 2.0 - width / 2.0, + .y = WORLD_IMAGE_HEIGHT / 2.0 - height / 2.0, .width = width, .height = height }; -- cgit v1.2.3