Last blog post I mentioned a falling dominoes tower hazard. Well, here it is in action!

Toybox Dominoes Hazard Kill Enemy Toy Player Animated

I won’t go too in depth on this hazard, because honestly there is just a lot going on. The key components were setting up a lot of static mesh actors to look like a stack of dominoes, then creating collision for the key parts and checking if players or bullets hit them, and triggering a simple timeline based animation for the falling for right now. Beyond that I made it so it can reference objects to fall with the dominoes tower top, that way you can put objects on top of it and have them fall down for the player to get for example, and I also made sure the top platform itself had collision so it could destroy enemies or players. That’s the hazardous part. Well, that and barrels that explode if they fall with it!

I got to create some other fun hazards this week as well. I made a bear trap and a slow trap. The bear trap catches a player in place and pops up a target they have to shoot before they can move. The slow trap just creates a zone on the ground which slows the player down. Together these two new hazards will make players think more about how they move through the environment and add an interesting twist to avoiding enemy shots and carefully aiming shots of their own.

I think creating hazards and level interactables like these is one of my favorite types of programming tasks. I really enjoy directly affecting gameplay and how players interface with a virtual world. Plus these traps and obstacles elicit lots of excited reactions from game testers, and that’s always really rewarding to see. I know not all programming can be fun and games, but at least a lot of it can be when you’re a game programmer, and I’m glad I get to do this type of work for the Toybox team.

Leave a comment