Camera Collision against Walls
author: Ali Abunada
The last thing you want to see in a game is a cheater; unless it's yourself of course. Working on this first sprint from scratch as a blank project meant I had to relearn the fundamentals of Unreal. It sounded simple, but of course I had my grievances with one of the most important things of gameplay--the camera. The player's camera, to be specific. After setting the camera on a spring arm, I started to walk around and noticed that the camera was clipping into one of the walls I placed into the level. This could be bad for the players playing the game as it could obstruct their view when unnecessary space they should be using to view enemies.
So the issue was obvious; I had to make sure the camera didn't clip into things. If it could clip through a simple square resized to look like a wall, it could definitely clip through other assets in our game. I thought that this was an issue with the camera, so I fiddled around with its blueprint settings for a while trying to get it to work. Assuming maybe I could use some sort of collider, I found that was quickly going to be an issue as I didn't want the camera not clipping into every object. Surprisingly, I found that the thing I was looking for was in the Spring Arm. So adjusting its target length, position, and finding something called 'Do Collision Tests' I was able to make sure that it didn't clip through anything I didn't want it to.
Get Zombats
Zombats
Third-person Ability Shooter
Status | In development |
Authors | Wombat Studios, JRarrat, Josh The Dark, iWannaNuhh, aabunada, Devon Flynn |
Genre | Action |
Tags | 3D, Third-Person Shooter, Zombies |
More posts
- Damage Feedback: Ragdoll Deaths and Screen Flash74 days ago
- Shattering Expectations - Ben Bissett74 days ago
- Sometimes Math is Hard74 days ago
- The Journey to Multiplayer, Part 3 - Joshua Newton75 days ago
- Audio in C++ - Ali Abunada75 days ago
- Guns and Ballistics - Ben Bissett80 days ago
- Proper Ragdolling - Ali Abunada80 days ago
- Wave Based Spawning and Spawner Management80 days ago
- The Journey to Multiplayer, Part 2 - Joshua Newton81 days ago
- Pause Menu Doubling81 days ago
Leave a comment
Log in with itch.io to leave a comment.