Author Topic: Flip Player Camera  (Read 370 times)

Whats the easiest way to go about flipping the players camera completely upside down?

In a post by Drydess back in 2017 they mention:

i know there's a console command somewhere out there to flip your screen upside down but i can't remember it to save my life. i think it was some variable like $pref::player::zskew but i don't think that's it

Anyone have a clue as to what they might have been referring to?

Idk about  console commands but you cam do it by changing playertype look angles

Idk about  console commands but you cam do it by changing playertype look angles
doesn't seem to be a thing

minLookAngle = controls how far down you can look
maxLookAngle = controls how far up you can look
maxFreelookAngle = controls how far you can look left or right (while holding z)




   maxLookAngle = -3.14159;
   minLookAngle = -3.14159;
?

well holy crap, it really was that easy.  why the heck is it negative pi? In retrospect, my line of thinking was that it would be in degrees from 0-360 or soPhysician Prescribed Desoxyning along those lines.

thanks much Biqus

edit: Okay so it works fine except for the one tiny issue, that being in 3rd person (and to everyone seeing you) your character is stuck looking at the sky and can't stand up straight

« Last Edit: January 12, 2023, 08:50:37 PM by Goth77 »

why the heck is it negative pi? In retrospect, my line of thinking was that it would be in degrees from 0-360 or soPhysician Prescribed Desoxyning along those lines.
pretty much all of the game's code uses radians and not degrees

edit: Okay so it works fine except for the one tiny issue, that being in 3rd person (and to everyone seeing you) your character is stuck looking at the sky and can't stand up straight
that's because flipping the max look angle makes the game think you're looking up, not backwards
the look animation was likely coded assuming nobody would use values past pi/2

well holy crap, it really was that easy.  why the heck is it negative pi? In retrospect, my line of thinking was that it would be in degrees from 0-360 or soPhysician Prescribed Desoxyning along those lines.

thanks much Biqus

edit: Okay so it works fine except for the one tiny issue, that being in 3rd person (and to everyone seeing you) your character is stuck looking at the sky and can't stand up straight


Ur welcome. if it looks better you can change the numbers 2 positive and you will be looking down instead

Alright, so by copying the default player and shape mdts code and making a new playertype from it, by replacing the look sequence I have made it so that the player stands normally (root is used as look)

this brings another question, is there a way to make it so that the camera is facing the characters back instead of the front?



« Last Edit: January 14, 2023, 01:17:06 PM by Goth77 »

unfortunately not really with this approach as the whole upside down is predicated on rotating the original view by 180

you could do some invisible/hidden bot shenanigans to make it work from behind as discussed in dms. a new idea that came to mind is using spy cam > mounting a bot to spy cam with inverted view > setting that bot to control the player and the cam to control the bot