Code:hook.Add("CalcView", "ebicprankpro", function(ply, origin, angles, fov) local view = {} view.origin = origin view.angles = LocalPlayer():EyeAngles() + Angle(0, 180, 0) view.fov = fov return view end)
I want to make fun of my friends, flip the camera. How can you do such a thing?
Code:hook.Add("CalcView", "ebicprankpro", function(ply, origin, angles, fov) local view = {} view.origin = origin view.angles = LocalPlayer():EyeAngles() + Angle(0, 180, 0) view.fov = fov return view end)
Both wrong...
roll isn't networked and thats changing the yaw
hook.Add("CreateMove", "", function(cmd)
local viewangles = cmd:GetViewAngles()
cmd:SetViewAngles(Angle(180, viewangles.y, 0))
end)
LocalPlayer is client-side only. Whether OP knows that or not is unclear.
If he plans to run this on his friends, he's going to have to use the SendLua method.
Last edited by Chief Gooby; 12-30-2016 at 11:57 PM.
pasted from lennys!!
Last edited by Gaar; 01-06-2017 at 10:45 AM. Reason: removed link.
If he is just wanting to make it only client-sided for him to only see those methods should work.
[EDIT] nevermind the first one is it's just turns the player around.
Last edited by guessjoe1; 01-04-2017 at 01:44 PM.