diff options
| author | Aldrik Ramaekers <aldrikboy@gmail.com> | 2024-11-28 21:32:10 +0100 |
|---|---|---|
| committer | Aldrik Ramaekers <aldrikboy@gmail.com> | 2024-11-28 21:32:10 +0100 |
| commit | cb92e568b6af4c7a5cdfa4fccf20d6dd1d6e0727 (patch) | |
| tree | 4a92a68a1f4f7f6c75ee0892b1ec6a791c356bec /src/world.c | |
| parent | e3724ffc498462d1da85542a57e91d9b882ad6dd (diff) | |
working on shadows
Diffstat (limited to 'src/world.c')
| -rw-r--r-- | src/world.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/world.c b/src/world.c index 8ceb5b3..13dc644 100644 --- a/src/world.c +++ b/src/world.c @@ -1351,6 +1351,8 @@ static bool world_check_location_accessibility(world_location* orig, world_locat return false;
}
+bool world_map_location_is_in_sun(vec2f px_pos);
+
world_update_result world_render(platform_window* window, world* world)
{
world_update_result result = {0,0};
@@ -1391,6 +1393,10 @@ world_update_result world_render(platform_window* window, world* world) if (!location->is_accessible) {
tint = COLOR_LOCATION_DOT_UNACCESSIBLE;
}
+
+ if (!world_map_location_is_in_sun(map_pos)) {
+ tint = rgb(255, 255, 0);
+ }
renderer->render_image_tint(img_locationdot, circle_x, circle_y, dotsize, dotsize, tint);
}
|
