"Weapon Assignment Bug" | Rex Mejia | 7-17-25



The Problem
During this week's sprint, I had an issue where the Enemy Agent could not properly equip a designated rifle. The rifle was being derived from the BaseCharacter but even though it was there visually the rifle would not do commands. When trying to debug the issue, the rifle was assigned as a child actor component in the editor but when the game ran, the references would come back null therefore wouldn't respond to function calls as expected. The result ended up with the enemy standing idly or ran it's wander function call if the player left its field of view. This made testing other functions of the game come to a standstill and until it was corrected, we could not move forward.
Problem Solution
With this bug hindering progress, I made a new WeaponChildActor that would respond to function calls and attached this working Rifle to the enemy. This led to another issue of the enemy now having two weapons visually, even though only one worked with the function calls. After some help from teammates, I was able to remove the old weapon reference and assign the new rifle as the functional weapon for the enemy. After validating that the new rifle successfully executed Fire functions, the enemy was able to engage the player in combat as intended. Which allowed us to progress to the other objectives we had for this week's sprint.
Get Operation Nightfall
Operation Nightfall
Status | Released |
Authors | Untamed Gaming Studio, kodadoka, AntonyXabier |
Genre | Shooter |
More posts
- Unreal 5.4 Quality of Life | Author: Connor Prosise | 7/24/2578 days ago
- Adjusting Real-Time Ammo Display | Author: Koda Durbin | 7/24/2578 days ago
- "Visual Countdown" | Rex Mejia |7-24-2578 days ago
- UI Logic Lost in Translation: When It Wasn’t the Code Author: Marcos Salinas |...78 days ago
- AI's Identity Crisis: When Enemies Turn on Each Other| Author: Antony Castro| Po...78 days ago
- Adding Fab Assets| Author: Connor Prosise | 7/18/2584 days ago
- Setting Up Game Loop | Author: Koda Durbin | 7/18/2584 days ago
- Fixing Audio Stacking and Overlay Duplication in Menu Transitions | Author: Marc...84 days ago
- Preventing Overlapping Spawns: Ensuring Enemies Don't Stack Up| Author: Antony C...85 days ago
Leave a comment
Log in with itch.io to leave a comment.