CCTV "Camera"

Hey, I was wondering if there is any function that can be used to set a player view position?
Not thinking of RT-camera as it’s pretty buggy and also interferes with already map-made RT cameras.

The use of it would be like a CCTV cam you could view around specific places of the map.

ypu’ll be looking into the calcview hook I believe

Thanks for that. Seems to be what I’m looking for. Though when I use it, I can see a players fists infront.
Any idea how to hide them ?

Edit: Also noticed this became problematic when you placed the camera in parts of the map far away. That doors and such doesn’t render.
I suppose that’s normal as that part of the map is not rendered properly because my player in reality is not there. So the question is if there is a workaround this or something?

For the players fists you need to hide the view model



self.Owner:DrawViewModel(false)


As for the doors, could you possibly move the player to the position of the RT camera to combat the rendering issue? If you need the player to return to their old position (such as checking a computer terminal to view the cameras in a building) then you could store the players position vector and return them to it once they had cycled through the cameras.

Regardless, Good luck, sounds pretty cool!

-snip- sorry mis read.

That’s something that would be nice to have indeed. It’s what I thought as the solution as well.
But if I’m going to use it, how would I make maybe some kind of rag doll staying the the position the player triggered the camera view? So if someone passes him/her, they understand he’s there. So they don’t “disappear” and reappear when done cycling cameras.

Create an entity and set its position to the stored player’s position and set it’s model to the player’s model. May also want to have the player stored in a variable on the entity and make it so when the entity takes damage the actual player will get hurt. When the player is done looking through the camera just delete the entity and set the player’s position back.