Top-Down Camera Issues

Me and a friend’s recently decided to try and make a top-down shooter, and as such I have been working on the camera a bit. My goal is to achieve camera behavior similar to that of Alien Swarm where the camera’s focus is mainly the character, but also follows the cursor around a bit so the player can look a bit further away*(see this video for a quick example)*.

I managed to sort of get a similar behavior but it was rather buggy and I decided to scrap it as I try to think of a better way to do it. So currently I have a very basic setup using Get Mouse Position Scaled by DPI and clamping the X and Y values. So if anyone has any suggestions as to how to get behavior similar to that game, I’d greatly appreciate it!

However, there are 2 other issues I have which I just can’t seem to find a way to fix;

1. Camera is Very Twitchy

I am using Get Hit Result Under Cursor Channel’s location output in order to have my character face towards the Cursor, and while this works most of the time, there are areas where the camera will get very twitchy for example when the cursor is on top of a wall and the such. I still have to find a nice way to prevent this from happening.

Would the best way be to just make an array of all the actors it should ignore? Or would there be a better way to do it?

2. Weird Camera Behavior in Multiplayer

My character’s movement is nicely replicated, however there’s something going on with the client where it still seems to be affected by the Server’s camera or something. I’m not even sure how to describe it, so I recorded a video of it instead. My assumption is that it’s due to me using Get Player Controller which is set to Player Index 0.

Here’s a video I recorded showcasing both of my issues;

Does your camera have any sort of collision? Try turn that off if that’s the case.

I’ve turned off the collision, the twitching of it would be due to the camera boom following the cursor, so whenever the cursor is over an object, it gets confused as to what to do :stuck_out_tongue:

Hm, I don’t know what properties the boom have to turn on or off to maybe help it.

I’ve managed to solve it, the twitchy camera issue was due to how I had set it up. And I’ve also managed to find a way to replicate similar camera behavior as to what Alien Swarm has, like this;

Seems to work very nicely, the Max Distance variable is set to 200.

The only issue remaining is the multiplayer one, I simply can’t figure it out. I’m fairly acquainted with the whole Server to Client communication stuff as I’ve done similar things in other games. My assumption is that it’s because I’m using Get Player Controller which has an index of 0. So if anyone could shed some light on this, that would be greatly appreciated!