Introduction
This page records my work for each sprint during the development of Carnival of Evil video game by Groovy Games.
Throughout the development of this project we had SCRUM sprints that would last a week or two. I keep track of all my work in a technical journal with the details on every task undertaken including code, screen shots, gifs, videos and referenced materials. In every sprint section I reflect on the task process and my conclusion of the sprint as a whole.
Sprint 1:
Sprint one was more about finding our feet in the team, discussing game ideas and sorting out roles. I chose the same roles as my 3rd year project, sound designer, player mechanics and input as I had gained some experience with these and the team agreed. I gathered some SFX and music for this sprint as we just started development and didn't have a great idea of the game yet so couldn't work on much else. Since I was working on player mechanics I thought it would be a good idea to make a mock scene to use as a sandbox and play with Unity's engine and character controller. Also could use this scene to build a mock-up of what the intro scene could look like. I was glad to be using Unity's engine instead of having to build our own first giving us more time to work on the mechanics and not the back bones.
Tasks
- Worked on paper prototype.
-
Made a mock up Unity scene to test player mechanics and intro cutscene.
Car drives to the carnival using Rigitbody's AddForce method.
Car hits invisible trigger which slows it down and it comes to a gradual stop outside the Carnival dirt road.
Camera changes to first person and the player can Move, Look and Shoot with the effect taking the normal into account.
If the other object has a "Damageable" script then it can be shot and take damage.
Mouse Look was achieved by getting the mouse X and Y delta from the new Input system then clamping rotation.
Unity's new Input System was a good choice as it has a UI that's easy to use, quick to set up and highly extensible.
I set up all the controls in the Awake() of my InputManager Class.
Using Composition over Inheritance I then made a movement and mouseLook instance. - Researched and found music / SFX from the Unity Asset store and Freesound.org:
-
Unity Asset Store - https://assetstore.unity.com/
-
Walk/Run/jump SFX
https://assetstore.unity.com/packages/audio/sound-fx/foley/footsteps-essentials-189879#content -
Vehicle SFX
https://assetstore.unity.com/packages/audio/sound-fx/transportation/vehicle-essentials-194951 -
Horror elements
https://assetstore.unity.com/packages/audio/sound-fx/horror-elements-112021#content -
UI SFX
https://assetstore.unity.com/packages/audio/sound-fx/ui-sfx-36989#content -
Horror SFX
https://assetstore.unity.com/packages/audio/sound-fx/horror-sfx-32834https://assetstore.unity.com/packages/audio/sound-fx/horror-sfx-082918-127389
-
Horror Ambience
https://assetstore.unity.com/packages/audio/ambient/horror-ambient-album-082318-127190#
-
-
Freesound.org - https://freesound.org/
- Gun shot
https://freesound.org/people/CJDeets/sounds/476740/
-
Hunted by Xanco123
https://freesound.org/people/Xanco123/sounds/233311/
- Gun shot
-
Unity Asset Store - https://assetstore.unity.com/
Conclusion
A great productive sprint with some normal work stress and anxiety like getting it finished before the next sprint. It was fun using Unity's new Input System and I learned about Unity's character controller component.
Sprint 2:
Sprint 2 was focused a lot around the paper prototype which helped us tease out the game mechanics and narrative by immersing us in the world and thinking about the placement of things and what things we should add here and there to make a carnival. We met on Tuesday for 2 hours all together to discuss our game and make the paper prototype with cardboard boxes I got from Lidl and colored card I bought in a stationary shop. I made the stalls, Zoltan's, monkey cage, Ferris wheel and other little pieces. It was a relief to be nearly finished so we could start with recording a live play through with sound board to add sound. I couldn't think of much to do this sprint so the team lead asked me if I would like to design the 3 main puzzles and 3 mini games so I happily obliged. After working on the paper prototype and the games I found that I needed more SFX so researched and sourced them from the Unity asset store and Freesound.org.
Tasks
- We all worked on the paper prototype.
- Designed 3 major and 3 minor puzzle drafts.
Bumper Cars draft.
Carousel draft.
Ferris Wheel draft.
Don't feed the animals draft.
Shooting gallery draft.
Hit the hammer draft.
Example riddle that could be used for the carousel or Zoltan as a tip were he lights up the key words. -
Researched and found more SFX for NPC's from the Unity Asset store and Freesound.org:
-
Unity Asset Store - https://assetstore.unity.com/
-
Freesound.org - https://freesound.org/
-
Psycho Killer Alarm Bell Loop
https://freesound.org/people/BaDoink/sounds/540030/ -
The Kill by imaginaryband
https://freesound.org/people/imaginaryband/sounds/145008/ -
17 Evil laugh.wav by The Baron
https://freesound.org/people/The%20Baron/sounds/98382/ -
Evil Laugh.wav by LukeSharples
https://freesound.org/people/LukeSharples/sounds/145619/ -
Laugh.mp3 by tchild
https://freesound.org/people/tchild/sounds/319766/ -
laugh4.wav by max_cristos
https://freesound.org/people/max_cristos/sounds/506406/ -
Evil Laugh 2.wav by 222laurio
https://freesound.org/people/222laurio/sounds/466057/
-
-
Unity Asset Store - https://assetstore.unity.com/
Conclusion
A productive week paper prototype wise as week nearly finished it and it helped me know what SFX we will need. The hard part was thinking about and designing the 3 puzzles and 3 minigames as they had to not only fit with the theme of a carnival but have a connection to the player narrative and game logic which we didn't know yet.
Sprint 3:
Sprint 3 occurred partially during reading week and focused on technical tasks as we had done a lot of work on the paper prototype previously. I worked on making the player character be able to sprint by holding down the shift key and crouch by holding down the control key. I couldn't figure out how to make the character sprint only while the key is being pressed but could only toggle the sprinting on or off. Left it for this sprint and would come back to that later. Added all the currently collected sound files to the team google drive file so they could check them out and give feedback.
Tasks
- Added sprint code, crouch code and controls to Unity mockup level.
- Added all sound files to google drive.
Conclusion
Felt just ok about the player mechanics as I didn't achieve the sprinting mechanic how I would have liked but accepted it and told myself I can come back to it at a later stage and to focus on more important tasks. I learned how to deal with not being able to complete something straight away and that I must accept it for the moment as it could effect me mentally towards my other assignments and team.
Sprint 4:
Sprint 4 was all about time management as we had lots of assignments coming up. For the moment it was important to work on our assignment deadlines and what was needed to be completed for them. I made a soundboard for the game that SFX and music could be played while playing through our paper prototype and for making a video on it. The player flashlight mechanic was important too as we had to show case our progress for our collaborative module. The player needs the flashlight to be able to see in the darkly lit level and no one would be able to see the game without it.
- Make a soundboard for our paper-prototype presentation.
- Make flashlight mechanic for player.
Added this script to the flashlight object and this class with composition to access the Use() in the InputManager class.
Toggle on and off with 'F' key.
Conclusion
Adding all the SFX to the soundboard was monotonous and pain staking as the open source software "Pearl" has terrible functionality. You must keep going back and forth in the website to upload and add. Was glad to get the flashlight mechanic finished in time for our presentation.
Sprint 5:
Sprint 5 was all about finishing up our paper prototype presentation and video recording a play through to add on a PowerPoint slide. Our team met up for 2 hours so we could set up the paper prototype and each play out a part for the video recording. I moved the killers and threw their weapons and traps. I gathered some more SFX. After I received the recording from our team lead I got to work in "Davinci Resolve 17" to edit and add sound. I then uploaded the recording to YouTube for easy access just in case the video couldn't be played on the PowerPoint presentation.
Tasks
- Helped make the paper-prototype movie by controlling the killer clowns.
-
Researched and found SFX and music for soundboard from Zapsplat, Notification-sounds and Freesound:
- Zapsplat.com - https://www.zapsplat.com
-
Monkeys, apes, jabbering
https://www.zapsplat.com/music/monkeys-apes-jabbering/
-
-
Notification-sounds.com - https://notification-sounds.com/
-
Calliope Music
https://notification-sounds.com/754-calliope-music.html
-
-
Freesound.org - https://freesound.org/
-
Quarter Inserted, falls into coin return by bassmosphere
https://freesound.org/people/bassmosphere/sounds/384700/ -
door_unlock_brickhario.wav by Brickhario
https://freesound.org/people/Brickhario/sounds/491111/ -
The ding by suzenako
https://freesound.org/people/suzenako/sounds/320905/ -
sad_thank_you.wav by dannyprikaz
https://freesound.org/people/dannyprikaz/sounds/486921/ -
Cat eats by 16FVolejnikovaA
https://freesound.org/people/16FVolejnikovaA/sounds/498390/
-
- Zapsplat.com - https://www.zapsplat.com
- Added and edited audio to the paper prototype video using "Davinci Resolve 17".
https://www.blackmagicdesign.com/uk/products/davinciresolve/studio
-
A playthrough of the paper-prototype can be found on YouTube
https://www.youtube.com/watch?v=nJBnTNCm3_c&ab_channel=PixelPat
-
Conclusion
All in all a successful week with no hiccups and we were happy with the work we had put in. I learned that I should make a more thorough list of audio files needed before starting to resource them as I realized I had not thought of every sound needed but only did when making the paper prototype or editing the video. I gained more experience in video editing such as how to use Davinci Resolves Fairlight software to edit sound.
Sprint 6:
Sprint 6 for me was mostly about integrating all the player mechanics I had worked on previously in my own Unity project into our team repo on GitHub.
Tasks
- Implemented player mechanics and gun canvas with crosshair into the groups GitHub repo.
All the player mechanics and UI I had made on my own hard drive was transferred to our game repository on GitHub.
I made a new branch called "player-mechanics" and implemented it into our project and made adjustments for it to work.
Player shooting mechanic in action - shooting a dummy object to test the bullet impact effects.
Conclusion
It was relieving to finally have all our own prototypes merged together in the main game repo and play it on Unity. I had some issues while integrating my work into our team repo because there was already a player there and he was connected to a lot of other objects in the scene so I had to delicately move, edit and add new scripts and references in Unity. I gained experience in errors related to null references in Unity which is when you make modifications on a script and the reference on it is removed so you have to just drag that object back into the reference variable in the editor.
Sprint 7:
Sprint 7 was based around our Research module in which we needed to get participants to play test our game. I was researching about the importance of sound pitch in a horror game so I gathered some more audio based on human voice pitches, low , medium and high. I worked on implementing audio into the first area for the main objects like the players footsteps, killer, hostage and amusements.
Tasks
-
Source/Foley different pitch voices for the hostages from Freesound.org:
- Freesound.org - https://www.freesound.org
- Freesound.org - https://www.freesound.org
- Implemented audio for the main objects in the first area of the carnival.
Implemented audio in the puzzle timer script to the Carousel so that the music starts when the player interacts with it and it stops when the puzzle is over.
Drag in all your audio sources as references in Unity editor and call the losing condition methods if timer stops.
Implemented to the hostage so he will say "Help me" when the puzzle starts, "Thank you" if you complete the puzzle or "aaaaaaahhhh" when you do not complete the puzzle and he dies.
Used IEnumerator methods to be able to wait. Play these Coroutines for the hostages different states.
Implemented the killer clown audio in his patrol script so he laughs when he spots you on line 154 below.
The clowns Audio Source and distance of the rolloff volume.
Implemented player footsteps when he walks, runs or jumps.
Made a footstep generator class that will store footstep clips in a list and jump clip.
In the movement script I can use the FootstepGenerator class and make the player move with a random step sound.
Conclusion
I learned the importance of user testing and implementing 3D sound in Unity . I learned how to use IEnumerators to play sounds for the first time. A productive and informative sprint.
Sprint 8:
Sprint 8 was about using the feedback I got from our survey the week before from our research experiment. I added chase music when the killer sees you and then he laughs evilly. I added the player out of breath when his stamina bar is empty. Really just honing the player mechanics and immersion of the player character.
Tasks
- Added chase music for the killer clown in first area of carnival that plays after he laughs and chases the player.
I placed the clown laugh in the chase music method because they will play after each other and reduce methods. - Implemented stamina bar logic and basic UI placeholder.
Implemented 2 IEnumerator methods to refill stamina and hide stamina bar after 2 seconds of not sprinting.
Added breath clips so he breaths heavy while sprinting and takes a deep breath when stamina bar is depleted.
I used Unity's 'Slider' component which has some properties like maxValue ready made.
UseStamina method decreases the current stamina value and updates the stamina bar value to that untill zero value.
The stamina bar will decreases while sprinting and automatically refills until full while you can't sprint until refilled.
The bar disappears after 2 seconds of not sprinting so it doesn't obstruct the players view.
Conclusion
A productive week thanks to our play testers last week. I learned more about IEnumerators while playing and looping breathing sounds from the player character. It took me a while to figure out that I could use Unity's one shot play sound so I didn't have to check if it was still playing to play another sound.
Sprint 9:
Sprint 9 was a two week sprint and was around the start of the Christmas break so was hard to juggle assignments with family occasions. I worked on adding a health system so the player could pick up a health object to gain health or lose health from standing in a trap.
Tasks
- Added a scriptable object float health value to the player which can get decreased or increased by interactions around the carnival.
The 'HandlePickup' function has a switch of pickup data that holds the kind of pickup object is being picked up. If the case is 'Health' then I add the value of the pick up item to the player health scriptable object, then update the health icon on the screen. - Added a health system that allows the player to pick up items to increase health or lose health if they walk into a trap object.
The 'UpdateHealthHUDIcon' function checks if the player health is below a threshold of 25 points in which each icon becomes active. 'healthIcons is a List that holds the 4 health HUD icons, each health icon is a quarter big than the last and the highest ones are drawn on top of the latter. If the player has 25% health left then the first if statement will set the first icon to true and hide the rest so the lowest health icon will be shown.
The 'ReduceTrapDamageFromPlayerHP' function does the opposite of the add health method and subtracts the trap damage from the players health script.
In the top left corner we have full health with the 4th icon active and in front of us is a trap that can take 25% health from the player.
After the player walks on the trap the health icon in the top left gets reduced as the 3rd icon is now active and the rest are set to inactive.
To gain his health back the player must pick up a health object and increase it by 25%.
After walking over the health object you see the health icon is full again.
Here it is in action!
Conclusion
A good sprint for learning about scriptable objects as I spent ages researching them and testing them. A hard sprint on the mind and body but glad I completed what I had to do.
Sprint 10:
Sprint 10, I continued on the health system as their was no death condition when the player's health reached zero either from a trap or killer. The player has a gun but what good is it if he can't use it on the killer, so I worked on a stun condition for the killer in the first area that stuns him if he is shot 10 times. Also the killer needed a SFX for his reaction to being stunned.
Tasks
- Added player death logic.
This script has a method 'OnPlayerHealthZero()' that is called by an event when the players scriptable object health reaches zero and displays text on screen. It calls the 'GameOverToast()' coroutine that plays the players death sound, waits for 3 seconds and quits the game. Will go back to the main menu in future. - Created killer stun logic when he gets shot.
- Added sound for the killer's reaction to being stunned.
Conclusion
This sprint helped give the game some immersion by making the players gun stun the killer and changing his state and gave the user a sense of caution because now if he gets hit 4 times he dies and the game is over. A good starting point was made on the player mechanics that will be further expanded with player HUD effects when hit and killer animations when stunned.
Sprint 11
Sprint 11 was built around bringing the mini games and puzzles to life with sound and expanding player mechanics with an ammo pickup. The bumper car sound I found didn't exactly fit the purpose but was the only sound that came close to the movement of bumper cars. I plan to make a foley sound for this in the near future.
Tasks
-
Source Foley's from Freesound.org:
- Freesound.org - https://www.freesound.org
- Freesound.org - https://www.freesound.org
- Add audio for Bumper cars, Zoltan, Monkey’s, Shooting gallery and High Striker.
- Add basic sphere game object for the gun ammo pickups for the Player and implemented the logic so when the Player walks over it when his ammo is not full he picks it.
Conclusion
With most of the SFX and music for the mini games and puzzles done, the game seemed more immersive than before. The ammo pickup logic gave the player more reasoning for holding a gun and gave another dimension to the player mechanics.
Sprint 12
Sprint 12 focused mostly on giving the user more feedback to his actions whether it be in-game on the player HUD when he picks up ammo or gets hurt or in the menu's when navigating through options with SFX and music.
Tasks
-
Source Icons from flaticon.com:
- Add audio for the hostages, pause menu, main menu, ending scenes.
- Add Player UI icons for health and ammo.
Conclusion
A good sprint overall most of the game music had been implemented and unique hostage voices gave it more realism. The player HUD icons improved on the flack jacket and just ammo numbers on the screen that no one knew were for.
Sprint 13
Sprint 13 was about adding some polish with to characters, interactables and puzzles with audio and player mechanic logic. Before, I had the same generic audio for the killer clowns so added unique sounds to the 3 different clowns for their bite, stun and chase music. Every time you took out your flashlight or gun there was no feedback whether it was out or not if you weren't looking at them so added SFX for equipping/unequipping them. Also not audio feedback for picking up health and ammo so worked on that too. The player had ways of being hurt like from being smacked by a monkey for example but logic wasn't implemented yet. Worked on making the player take damage from the bumper cars spikes, monkey puzzle and throwing knives from the Performer killer in the same way the logic for the trap works at damaging the player. After demoing the game to our lecturers the feedback on audio being too high in one section and too low in another area made me work on remastering all the sounds while sitting in a quiet room with headphones on.
Tasks
-
Source Foley's from Freesound.org:
- Freesound.org - https://www.freesound.org
-
Monster bite
https://freesound.org/people/LucasDuff/sounds/467701/ -
Monster Attack
https://freesound.org/people/sonidotv/sounds/238316/ -
Chase Music 1
https://freesound.org/people/NightWolfCFM/sounds/425134/ -
Chase Music 2
https://freesound.org/people/Victor_Natas/sounds/544913/ -
Chase Music 3
https://freesound.org/people/Victor_Natas/sounds/544912/ -
Pained Yelp
https://freesound.org/people/InspectorJ/sounds/414074/ -
Cyborg Hurt
https://freesound.org/people/scorpion67890/sounds/396805/ -
Pistol Gun Cocking
https://freesound.org/people/EminYILDIRIM/sounds/543927/ -
Empty Ruger Rifle
https://freesound.org/people/Kruf/sounds/528708/ -
Holster Pistol
https://freesound.org/people/nioczkus/sounds/388819/ -
Flashlight_On
https://freesound.org/people/LightYarn/sounds/173420/ -
Flashlight_Off
https://freesound.org/people/LightYarn/sounds/173419/ -
Metal Lever 1
https://freesound.org/people/timgormly/sounds/151271/ -
Ammo Pickup #2
https://freesound.org/people/zivs/sounds/433771/ -
SFXKeyPickUp
https://freesound.org/people/dkiller2204/sounds/422971/
-
- Freesound.org - https://www.freesound.org
- Add audio for Levers, equipping/unequipping flashlight and gun, Ringmaster killer, Performer killer.
- Add SFX for pickups, health, ammo, key, banana.
- Remaster all game audio so there are no sounds too high or too low.
- Add player damage for Monkey puzzle, Bumper cars puzzle and throwing knife stab.
Conclusion
A good sprint for making mistakes and learning from them and making me more familiar with implementing audio in Unity and increased my experience with scriptable objects while making more player damage logic. I had an issue with conflicts when merging to our GitHub repo because I didn't notice a member of my team had a pull request pending and I pulled from the main branch without reviewing it. I had to spend hours on fixing the conflicts to no avail so after a few failed attempts of merging I start all over again with a new branch having to do all the work again. I big lesson learned that will not be repeated.
Sprint 14
This sprint I had to work on fixing player damage issues with hazards from puzzles that were only playing SFX but not actually damaging the player. The monkey slap, bumper car spikes and throwing knifes stopped working after a big update. We agreed that having a blood splatter effect on screen when damaged would be better than just a heart icon as it would make the game look more gory.
Some feedback from the lecturing panel suggested that some of the interactables were hard to find and see and we should consider adding some way of letting the user find them easier so I made a shader using Unity shader graph and added it to a material that pulsates on an object when the player enters its box collider and removes it when he exits to save processing power. Some interactables have the material all the time and don't have to be triggered because they have a short life span anyway like pickups but Zoltan and the levers have a shader trigger script to turn the shader on and off for them.
Along the way I discovered that the player double jumped if the jump button was pressed more than once and the player stamina bar decreased when the sprint button was pressed even if the player wasn't moving. A bug occurred were the player couldn't interact with the levers after adding a new box collider to it to trigger the shader with a raycast when the 'E' key was pressed. The new collide had to be lowered below the main box collider of the lever so it wouldn't get in the way.
Tasks
- Conducted user testing with Patrick and Antanas to gain feedback on what needs to be improved or added.
-
Fix Player Damage Issues With Certain Hazards.
-
Implement Damage Effect To UI.
A blood splatter effect shows on screen when damage is taken from any damageable object with the alpha value increasing for each event.
Blood splatter alpha decreases for each damage event and disappears once the heart is full again.
-
Added a shader to all interactable items to make them shimmer.
Image below shows all the parts of the shader.
Added a shader to health, ammo, mini game items and signs, Zoltar's crystal ball, keys, locks and levers.
The levers used colliders to activate and deactivate their pulse shader with the "PulseShaderTrigger" script attached.
First you select the layer that can trigger the shader and the shader material you want to be applied to the object. I choose the Player as the layer and pulse shader I made for interactables.
If the Player enters the objects box collider and with his layer set to "Player" the block inside the if statement will be processed.
A local material array is created with the size of the objects current materials array plus one to make space for the new shader material.
The current material array is copied to the local material array at index zero.
Then the pulse shader is added to the last element of the local array.
Finally the current materials array will be assigned the local array with the shader.
When the Player exits the box collider if he has the "Player" layer then we must delete the shader.
A new material array is made called "materialsArray" with the size of the current materials array minus one because the shader material will be deleted.
A for loop iterates through the current material array not including the last element with the shader in it, adding the rest to the new material array just made.
Then assigning the new material array to the current material array now without the shader material.
The shader will only activate when the Player will pass by the tent when he could realistically see it anyway.
Here's what the shader looks like on one of the levers.
-
Bug fixes to player mechanics.
Conclusion
A cleansing sprint that rid a lot of major and minor bugs. The reason why there was a bug with the player not taking damage was because we started working with all the scenes loaded additively which meant that only one player and manager was active from level one but some of the logic for level two damage was in the manager from level 2 which was disabled, so I had to add the logic from all the scenes into the one active manager. I learned a lot about material arrays, shaders and how Unity works with multiple scenes.
Sprint 15
For sprint 15 I wanted to deal with some feedback we gained last week from user testing and bring all the controls using Unity's old input system to the new input system and use the InputManager script as it's good to have all the controls in one system to maintain, debug and reduce Update() calls that the old input system keys were doing.
After the intro scene was finished it needed music and SFX for the vehicle added. I used the track "Wheel of Fortune" from the "Circus music" pack I had. For the car I used the "Vehicle SFX" pack from Unity. I edited the sounds of the engine to be double the size and fade in and fade out. The handbreak SFX was good as is. Had to reduce the amplitude of the intro music in Audacity as it was drowning out the car engine SFX even when turned down in the editor.
Zoltan had basic text showing up on it but needed a fancy revamp so worked on creating fortune telling tickets that you would get from a real machine in Photoshop for each machine with a different clue written on it. Had an issue were the game event and listener Classes we have does not cater for a situation were we need to take as a parameter non C# data types like and 'int' or 'string' so I had to create a new game event and listener Class for this. Once that was done I could pass Zoltan's hit info from the players InteractionHandler script component to a specific Zoltan object.
Added some game pad support for all in-game actions except for menu's as it will take a lot of work to do that and will do it in future.
Users suggested that there should be a dot on screen even when the gun is not equipped so it would be easier to know where the center of the screen was and interact with objects precisely. I added a small gold dot to the player HUD and increased the size of the gun reticle so the dot didn't hide much of the screen.
Tasks
-
Added audio to the introduction scene. Music and vehicle SFX taken out from Unity store audio packs.
-
Unity Asset Store - https://assetstore.unity.com/
- Circus Music Album - 052818
https://assetstore.unity.com/packages/audio/music/circus-music-album-052818-119946
- Vehicle - Essentials
https://assetstore.unity.com/packages/audio/sound-fx/transportation/vehicle-essentials-194951
- Circus Music Album - 052818
-
Unity Asset Store - https://assetstore.unity.com/
-
Added Proper Zoltan UI hints.
I created a new event called "RaycastHitEventSO" that takes a "RaycastHit" as a parameter because the other event Class I had could only take in a C# data type like and "int" or "string" etc.
To be able to listen for this event I needed to make an event listener called "RaycastHitGameEventListenerSO".
I created the RaycastHit game event data.
Then made a RaycastHit game event listener component on each Zoltan and dragged the newly made event data to it.
After that we choose the "ActivateZoltar" method so it will be called when the player interacts with it.
I changed the private "ActivateZoltan" method to public and to take in a RaycastHit as a parameter from the players "InteractionHandler" script.
With this info it checks which Zoltan machine the player interacted with and starts the corresponding IEnumerator method.
The IEnumerator method "DisplayZoltanClue" uses "LeanTween" to ease in and out the Zoltan card for a few seconds.
Once that is set up we can drag the event data into the "InteractionHandler" script which is a component of the Player.
Zoltan's tag is "Interactable" so if the player interacts with an object with that tag we raise an event with the hitInfo, "OnZoltanInteraction.Raise(hitInfo)" that is sent to Zoltan's "GiveHInt" script and the "ActivateZoltar(RaycastHit hitInfo)" is called.
I created two fortune teller cards, one for each Zoltan machine using Photoshop and added them to Zoltan's Canvas, disabled and out of screen view from the user.
A clip of what it looks like finished. The card shows longer but shortened it here to save space.
-
Added some gamepad bindings to the key controls for in-game play, does not work with the menu's yet.
Added some "Actions" that were using the old input system to the new input system to increase performance and reduce spaghetti code. "Interact" and "Pause".
Used composition to get the "InteractionHandler" and "GamePauseBehaviour" methods in the "InputManager".
In the "Awake()" method I initialize the player actions "Interact" and "Pause" and connect them to their appropriate methods.
Here is the "OnInteractPressed()" method int the "InteractionHandler" script that is called every time the interact button is pressed.
Here is the "OnPausePressed()" method int the "GamePauseBehaviour" script that is called every time pause is pressed. - Added a bright circled image to the center of screen when gun isn't equipped to better interact with items.
Increased the size of the gun reticle and changed it's color to a more visible gold.
Conclusion
Got a lot done for backend and frontend this sprint and took care of some user feedback that was important. Was good to have all the controls in the one script "InputManager" as I have wanted to do that for a while. Will have to think about how I will make the gamepad work in the menu's using the new input system before the next sprint so I can hit the ground running. Was a tough sprint but worth it in the end.
Sprint 16
Sprint 16 for me was mainly focused on the player mechanics and it's UI.
It felt a bit frustrating when sprinting because the stamina bar would only refill once it was depleted so wanted to change it so it refilled when the player stopped sprinting to give him more sprint time.
The gun had no weight to it as there was no reaction after shooting so needed to add some recoil and a muzzle particle effect to make it feel more useful. The reticle was too small and not visible enough so had to make it bigger and brighter to a gold colour.
The user couldn't know where the center of the screen was to interact with objects so adding a dot when the gun was not equipped was a no brainer.
After shooting the killers they didn't react and notice that they were shot so had to make him chase the player once he got shot.
Lastly the ghost that randomly appears needed some sound to make the full effect.
Tasks
- Changed up the stamina bar so that stamina regenerates while walking instead of when the player runs out.
When the Player is not sprinting, so walking or his stamina is refilling then start refilling his stamina bar. - Have a muzzle flash go off when gun shoots.
- Changed gun reticule color and size to be more visible.
- Have a different reticule when gun is not equipped.
- Improved the killer script so that the killers starts chasing the player after being hit with a bullet.
The OnKillerShot() method is called when the player hits the killer which changes his state to ChaseTarget. - Added random voice SFX for Jason 3 to say.
Conclusion
A sprint that cleared up some crucial player mechanic bugs that could ruin the experience for the user. I learned that by added little things like a reticle or muzzle flash that it can improve the gameplay a lot.
Sprint 17
Sprint 17 was over the Easter break while we had a lot of other assignments due so was apprehensive to take on too many tasks. Having said that I still took on the usual amount of hours as there was still too much to do.
After shooting and stunning the killers they could still hurt and chase the player when he came in contact with him taking the user out of the world because it didn't make sense.
The shooting gallery uses raycasts which can hit targets regardless of whether they have their gun out or not so fixed it to work only when the gun is equipped.
There was a bug were Zoltan in the second area would not show his hint which is important to the game so looked into that.
The background ambience was noticeable when it started it's loop again so worked on making it seamless using online software ALooper as I wanted it to be done professionally by an algorithm and not in Audacity by eye.
The bumper car ghosts looked static with no SFX so searched for the right sound and added it to all the ghosts.
Finally there were still some differences in sound levels in certain areas that were too loud or too noisy in its own context so worked on evening out the volume to not blow your ear drums off.
The Player HUD blood splatter effect doesn't leave the screen so that had to be made to fade out.
Tasks
- Fix the killer being able to damage the player when stunned and afterwards being able to move about while still in the stun animation.
When the Player enters the killers box collider and the state of the killer is not Stunned then he can only attack and cause damage to the Player. - Fix Shooting Gallery Issue were targets are hit when the gun is unequipped.
The code below is a code block from the Gun script in the "Shoot()" method.
If the gun hitInfo is equal to the tag "ShootingTarget" which all targets have then send the hitInfo over an event to the target script to use and do as it needs. -
Fix the issue with the Zoltan hint in area 2 not appearing.
When the Player pressed the 'E' key and interacted with the Zoltan in area two the players coin wasn't working on that Zoltan because it had a different player inventory object as it is in a different scene so to solve the problem I dealt with the coin in the InteractionHandler script which is in the same scene as the Player which is area 1 scene. - Fade out blood splatter effect on Player HUD after a few seconds to not annoy the user.
A coroutine is started using this IEnumerator method every time the player gets damaged.
This method basically uses a for loop to reduce the alpha of the blood splatter until it's at zero.
- Make the music and ambience seamless so you don't notice when it starts the loop again.
To do this professionally I used an online website called ALooper. - Add SFX to Bumper Car Ghost.
-
Final Audio Normalization.
Conclusion
This Sprint took a lot of energy away from other assignments but after ironing out some player mechanic flaws and sound issues the game started to feel more finished and enjoyable.
I learned that I shouldn't feel too anxious when having a lot of tasks to do that could be difficult because every time I was in this situation it worked out ok in the end, taking one task at a time.