Page 1 of 1

How to calculate 3rd person vieworg from servercode?

Posted: Sat Feb 06, 2021 1:58 pm
by leo9949
The topic says it all:

how to calculate cg.refdef.vieworg (calculated in cg_view.c) from server-side code?

:) I'm trying to find out, but I'm just asking just in case someone already knows the answer.

Re: How to calculate 3rd person vieworg from servercode?

Posted: Mon Feb 08, 2021 2:14 pm
by themuffinman
Easy solutions from the top of my head:
1. Send vieworg information from client via server command, probably not network efficient
2. Add thirdperson cvars to clientinfo (CVAR_USERINFO flag), mirror CG_OffsetThirdPersonView on server side using said userinfo to predict where vieworg is.

What are you trying to achieve?