Missing Projectiles - Jonathan Kohl


This week I worked heavily in creating a town bell that villagers can interact with to notify their region of a threat. Everything quickly started to come together, and AI were reacting as intended. After completing this task, I immediately began working on a new enemy type. This new enemy was a ranged Inquisitor which was set up very similar to the ranged town guard. After I fully set up the ranged inquisitor, it was time for testing. I placed the guard in a controlled environment and watched his behavior which was preforming as intended. Then I had him agro the player, this is where things got interesting. The AI would perceive the player, face the players direction, animate as if shooting the crossbow, and even follow the player. The problem was bolts were not spawning. 


In the past bolts not spawning meant they were hitting something on the AI and typically killed the character after some time. So initially I sat there and waited to see if the character would kill itself. This did not happen, so I began to double check all of my work. I ensured I set up the blueprint correctly and set all variables to their appropriate values. I tested again finding the same results. I then set breakpoints and log statements into the script. When running the game in debug I found that all the breakpoints and log statements were getting hit. Thats when it hit me that the town bell had a massive collider on it that could be destroying the bolts. I moved the bell out of the map, sure enough my ranged inquisitor began shooting bolts. I added the bell back into the map and updated the bolt script so that the bolts would ignore the collider. After further testing this resolved the issue. 


Leave a comment

Log in with itch.io to leave a comment.