Devlog #3: Doors, spikes and respawning
Introduction
This is the third devlog for Subject 13. There has been a gap from the usual devlog upload pattern due to other university projects taking priority over this one, however those projects are now done, so I can focus back on the development of Subject 13, moving forward there will be a shift to the creation of shorter weekly devlogs, this will mean more regular bite sized updates. Now back to the current devlog, we will be covering the creation of the door system, spikes and respawning.
Door system
The premis of Subject 13 is that you are escaping a lab, this means the placement of doors and of the puzzles within level are essential for both physically splitting up gameplay areas into distinct separate areas and for the use in puzzle systems alike.
Because of there will need to be doors used in a wide range of situations, I felt it was appropriate to make a versatile system so that it'll work and integrate with future systems with minimal extra work. The doors themselves are standalone prefabs that have a DoorHandeler script attached to them that handles all of the core functionality.
The functionality that the doorHandeler provides is as follows:
- Open door
- Close door
- Move door
Whist simple, these functions allow me to create varied and dynamic doors that can open and close at variable speeds, have multiple doors linked to one trigger or multiple triggers linked to a single door (we will cover the triggers in the next section). These simple behaviours can all be linked together to create unique door/pathing puzzles with minimal effort and a unique design.
Door triggers
Door triggers are interactable object in the game world that when they do a certain thing or are interacted with in a specific way will cause the door its linked with to trigger. This means that multiple doors that are in different states can all be linked to one trigger object and once the trigger has been activated it will trigger all asociated doors to change their current state (open->close and close->open respectively).
Current there are two implemented triggers, the lever and the weighted button. Both work as you might expect, the lever triggering when its flipped and the weighted button being triggered upon something weighing it down. I am planning on adding in other triggers in the future, but i also think its important not to just add features for the sake of it, this means that everything in the game will have a distinct purpose that is clear and easy to understand.
Future triggers may include:
- Proximity triggers
- Sequence or code based triggers
- Item triggers
Spikes
As the first of the hazards to be added to Subject 13 the spike is the most basic of these planned hazards. The implementation of the spikes is much as you'd expect, it has a trigger collider and script to check any collisions that occur to check if it was the player that is colling with the spikes. The only point of note is that there is actually two colliders on the spikes, one a trigger and another attached to a child empty that isn't a trigger, this is so i can have them on different layers so i can disable the player collision with the spikes to that the player will then interact with the trigger collider, but all other objects (because they aren't on the player layer) will correctly collide and interact with the spikes.
Resawing
Now hazards are starting to be implemented it's necessary to implement a respawn mechanic. When playing games that are likely to entail frustration, confusion and such forth, it is a good idea to have a fast seamless respawning mechanism. For this reason when the player dies, the screen fades to black before quickly fading back in with the player at the start of the level, this way all death screens are avoided and the player is free to have another attempt straight away, thus streamlining the entire game play experience due to the fact that dying is no longer a big deal.
Future development
This devlog has laid the foundations for the future development of more complex puzzle system and starts to really show the direction of this game. The next steps for development are outlined as below. These points represent upcoming features, though they may not necessarily appear in the very next devlog.
Things to Come:
- More hazards and dangers (turrets, cameras, lasers, etc.)
- Dynamic environment effects
- Menu systems
- Level design and asset creation
- Music and SFX
- Saving and loading
This is the end of the third devlog for Subject 13, there's still a lot of features and mechanics to come, as listed above. If you have any feedback, comments, or suggestions, please leave a comment below.
Subject 13
The experiment was a success. The containment was not.
Status | In development |
Author | Michael kronfeld |
Genre | Puzzle |
Tags | 2D, Side Scroller, softbody, Unity |
More posts
- Devlog 5#: Turrets, Cameras and Controller support6 days ago
- Devlog #4:Lasers and splatters12 days ago
- Devlog #2: Dynamic mesh creation, Movement & Cinemachine47 days ago
- Devlog #1: Soft-body physics63 days ago
Leave a comment
Log in with itch.io to leave a comment.