Creating a Enemy Spawn / Despawn Mechanic to Improve Game Performance
During the last couple of weeks my team has been dealing with ongoing performance problems, so it was my job as the lead programmer to figure out a solution. I decided that implementing a despawn / spawn mechanic to set specific enemies to specific locations so not all of the enemies were in the scene at once. In the beginning of the game, all of the enemies are spawned in, and then turned off after they have grabbed their required components, and then when the player hits a collider they will spawn the next or previous enemies depending on their direction. This greatly improved performance, and also decreased the amount of objects updating in the scene. In the images I provided I show a snippet of how I use the toggle switches for the enemies.
Get R-BRT
R-BRT
Status | Released |
Author | Sdearing0409 |
Tags | 3D, First-Person, Stealth, storygame |
More posts
- Dev Log 9: GoldJul 29, 2024
- Dev Log 07: Designing UIJul 16, 2024
- Dev Log 06: Lighting and VFX UpdateJul 09, 2024
- Dev Log 05: Designing Level LayoutJul 08, 2024
- Devlog-04 Character loreJul 08, 2024
- Devlog-01 EnemiesJul 08, 2024
- Dev Log 4: LoreJul 01, 2024
- Instantiating Individualized Instances of Enemies For Game Over SequenceJun 24, 2024
- Dev Log 03: Creating a Moving Texture with Shader GraphJun 17, 2024
Leave a comment
Log in with itch.io to leave a comment.