Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
S
SRB2
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Container registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Eidolon
SRB2
Commits
2e960793
Commit
2e960793
authored
Jun 4, 2016
by
Monster Iestyn
Browse files
Options
Downloads
Plain Diff
Merge branch 'master' into next
parents
83c4dba4
6bf40b8f
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/hardware/hw_main.c
+50
-8
50 additions, 8 deletions
src/hardware/hw_main.c
with
50 additions
and
8 deletions
src/hardware/hw_main.c
+
50
−
8
View file @
2e960793
...
...
@@ -2892,6 +2892,47 @@ static void HWR_AddLine(seg_t * line)
gr_backsector
=
R_FakeFlat
(
gr_backsector
,
&
tempsec
,
NULL
,
NULL
,
true
);
#ifdef ESLOPE
if
(
gr_frontsector
->
f_slope
||
gr_frontsector
->
c_slope
||
gr_backsector
->
f_slope
||
gr_backsector
->
c_slope
)
{
fixed_t
v1x
,
v1y
,
v2x
,
v2y
;
// the seg's vertexes as fixed_t
fixed_t
frontf1
,
frontf2
,
frontc1
,
frontc2
;
// front floor/ceiling ends
fixed_t
backf1
,
backf2
,
backc1
,
backc2
;
// back floor ceiling ends
v1x
=
FLOAT_TO_FIXED
(((
polyvertex_t
*
)
gr_curline
->
v1
)
->
x
);
v1y
=
FLOAT_TO_FIXED
(((
polyvertex_t
*
)
gr_curline
->
v1
)
->
y
);
v2x
=
FLOAT_TO_FIXED
(((
polyvertex_t
*
)
gr_curline
->
v2
)
->
x
);
v2y
=
FLOAT_TO_FIXED
(((
polyvertex_t
*
)
gr_curline
->
v2
)
->
y
);
#define SLOPEPARAMS(slope, end1, end2, normalheight) \
if (slope) { \
end1 = P_GetZAt(slope, v1x, v1y); \
end2 = P_GetZAt(slope, v2x, v2y); \
} else \
end1 = end2 = normalheight;
SLOPEPARAMS
(
gr_frontsector
->
f_slope
,
frontf1
,
frontf2
,
gr_frontsector
->
floorheight
)
SLOPEPARAMS
(
gr_frontsector
->
c_slope
,
frontc1
,
frontc2
,
gr_frontsector
->
ceilingheight
)
SLOPEPARAMS
(
gr_backsector
->
f_slope
,
backf1
,
backf2
,
gr_backsector
->
floorheight
)
SLOPEPARAMS
(
gr_backsector
->
c_slope
,
backc1
,
backc2
,
gr_backsector
->
ceilingheight
)
#undef SLOPEPARAMS
// Closed door.
if
((
backc1
<=
frontf1
&&
backc2
<=
frontf2
)
||
(
backf1
>=
frontc1
&&
backf2
>=
frontc2
))
{
goto
clipsolid
;
}
// Window.
if
(
backc1
!=
frontc1
||
backc2
!=
frontc2
||
backf1
!=
frontf1
||
backf2
!=
frontf2
)
{
goto
clippass
;
}
}
else
#endif
{
// Closed door.
if
(
gr_backsector
->
ceilingheight
<=
gr_frontsector
->
floorheight
||
gr_backsector
->
floorheight
>=
gr_frontsector
->
ceilingheight
)
...
...
@@ -2901,6 +2942,7 @@ static void HWR_AddLine(seg_t * line)
if
(
gr_backsector
->
ceilingheight
!=
gr_frontsector
->
ceilingheight
||
gr_backsector
->
floorheight
!=
gr_frontsector
->
floorheight
)
goto
clippass
;
}
// Reject empty lines used for triggers and special events.
// Identical floor and ceiling on both sides,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment