[Existing feature] Light Obstacle Hitbox

I feel like a cool feature to add to gdevelop would be being able to change the light hitbox of a light obstacle. Sometimes the normal collision box won’t seem to look well with the shadow, like in the case of going behind an object.
lightobstacleweirdness

I believe the light hitbox is based on the objects hitbox. You could create a few new objects as masks with the desired hitboxes, place them where you need to (example ontop the chests) and set them to hidden so they’re not visible.

Quick Sunday Morning Exmaple (Drag black box)

(Online Example) https://games.gdevelop-app.com/game-ed1d2086-6236-421b-9b50-40c7844b8722/index.html
(Project file) Upload files for free - Light Hitbox Example.zip - ufile.io (30 days until expires)

2 Likes

Oh, thank you! it works now.

1 Like