Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Jordon Moss
EDuke32-CSRefactor
Commits
600ce46a
Commit
600ce46a
authored
Aug 15, 2021
by
Richard Gobeille
Browse files
Duke3d: remove extra camera smoothing from G_DrawRooms, it's no longer required
parent
dc2f3016
Changes
1
Hide whitespace changes
Inline
Side-by-side
source/duke3d/src/game.cpp
View file @
600ce46a
...
...
@@ -963,22 +963,9 @@ void G_DrawRooms(int32_t playerNum, int32_t smoothRatio)
if
(
pPlayer
->
newowner
<
0
)
{
vec3_t
const
goal
=
{
pPlayer
->
opos
.
x
+
mulscale16
(
pPlayer
->
pos
.
x
-
pPlayer
->
opos
.
x
,
smoothRatio
),
pPlayer
->
opos
.
y
+
mulscale16
(
pPlayer
->
pos
.
y
-
pPlayer
->
opos
.
y
,
smoothRatio
),
pPlayer
->
opos
.
z
+
mulscale16
(
pPlayer
->
pos
.
z
-
pPlayer
->
opos
.
z
,
smoothRatio
)
};
CAMERA
(
pos
)
=
goal
;
#if 1
// I'm not particularly happy with this
static
vec3_t
lastcam
;
static
int16_t
lastcamsect
;
if
(
cansee
(
lastcam
.
x
,
lastcam
.
y
,
lastcam
.
z
,
lastcamsect
,
goal
.
x
,
goal
.
y
,
goal
.
z
,
CAMERA
(
sect
)))
CAMERA
(
pos
)
=
{
logapproach
(
lastcam
.
x
,
goal
.
x
),
logapproach
(
lastcam
.
y
,
goal
.
y
),
logapproach
(
lastcam
.
z
,
goal
.
z
)
};
lastcam
=
CAMERA
(
pos
);
lastcamsect
=
CAMERA
(
sect
);
#endif
CAMERA
(
pos
)
=
{
pPlayer
->
pos
.
x
-
mulscale16
(
65536
-
smoothRatio
,
pPlayer
->
pos
.
x
-
pPlayer
->
opos
.
x
),
pPlayer
->
pos
.
y
-
mulscale16
(
65536
-
smoothRatio
,
pPlayer
->
pos
.
y
-
pPlayer
->
opos
.
y
),
pPlayer
->
pos
.
z
-
mulscale16
(
65536
-
smoothRatio
,
pPlayer
->
pos
.
z
-
pPlayer
->
opos
.
z
)
};
if
(
thisPlayer
.
smoothcamera
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment