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: Gold60 days ago
- Dev Log 07: Designing UI73 days ago
- Dev Log 06: Lighting and VFX Update80 days ago
- Dev Log 05: Designing Level Layout81 days ago
- Devlog-04 Character lore81 days ago
- Devlog-01 Enemies81 days ago
- Dev Log 4: Lore88 days ago
- Instantiating Individualized Instances of Enemies For Game Over Sequence95 days ago
- Dev Log 03: Creating a Moving Texture with Shader GraphJun 17, 2024
Leave a comment
Log in with itch.io to leave a comment.