Home Artists Posts Import Register

Downloads

Content

I started the week investigating changes to the collision avoidance algorithm, the code that keeps the robot from penetrating walls and doors. My aim was to improve how the navigation felt, especially close to walls where the robot could easily get stuck. I also wanted to get rid of the annoying bounces that happen when the robot collides slowly with walls. I worked for about one day on a toy classical model and I managed to significantly improve the algorithm. In the new version, assisted braking only occurs if there are obstacles along the current trajectory. This means that the player can now move reasonably well, unless it is on a collision trajectory.

The next step was to re-implement those changes in the game. However, this required significant changes to the collider, the code that handles the collisions.

I knew there were quite a number of improvements to make, but it took longer than I expected. I spent one entire day brainstorming and writing down what the collider should and should not do. It then took two days to implement the changes. I hoped I could  have the new collision avoidance algorithm working by the end of the week, but it’ll slip to the next one. In the meanwhile, I share a video showing that the key is now also managed by the collision avoidance algorithm. After the work I did this week, the key cannot go out of the room anymore.

It’s also worth mentioning that I spent one afternoon improving the Lua infrastructure in the engine. The Lua code in the game now consumes far less memory: it used to produce about 4KB of garbage per frame. It now produces zero, at least when the player isn’t moving (after the initialization phase).

Comments

No comments found for this post.