Following the modular kit environment tests and subsequent creation of a starter room for the map from week 1, I decided the get the creation of a new skybox out of the way. As the map is set on a spaceship in the Cygnus constellation it would obviously have to be in space. After some research for what colours to use I used a program called “Spacescape” to create a skysphere texture which could be imported into UE4. The raw material was then added to a material, which was added to a new skybox blueprint, which was then placed into the level.
After implementing the new skybox into the level I began working on another level mechanic, the electric trap. In CoD Zombies the electric trap is traditionally a device placed above a doorway or narrow corridor which when turned on shoots bolts of electricity downwards, killing anything that passes under it when activated by its switch which is usually just next to it. Although there are several variations of it across all zombie maps, I based mine on the original as seen in the map Verruckt.
I decided to create the electric trap and electric trap switch as separate blueprints actors, with each BP set as a variable in the other so that they can communicate with each other in level and allow to have multiple in the level. The electric trap switch works in much the same way as most of the other level mechanics I’ve done in that once the player enters its collision box a UI widget is displayed prompting the player to “Press F to activate electric trap for 1000”. Once the trap is activated a series of branches are checked to see if the player is in the collision box and that the trap isn’t on cooldown or currently active. Once these are passed a custom event in both the BP_MainCharacter and the electric trap proper are activated. After this a boolean variable for the trap being activated is set to true and a delay timer for 30 seconds begins. After this the trap activated bool is set to false and a trap on cooldown bool is set to true. Another 60 second delay follows this before the trap cooldown is set to false again.
Once the custom event in the electric trap is activated, a series of functions which fire line traces which constantly check if they are casting to the player are fired. If a line trace hits the player it sets their health to 0.1. After 30 seconds all the functions are cleared and the line traces are turned off, deactivating the trap.
Following the implementation of new AI enemies into the project, I added small spawn rooms to the back of the windows in the level so that the zombies have a space to spawn in. Following this I am going to working on the BP_Window once again to ensure that the AI zombies can enter a collision box and tear down the pole barricades on the window, before entering the level.