Commit graph

362 commits

Author SHA1 Message Date
Louis-Antoine
74fa35221d Merge branch 'next' of https://git.magicalgirl.moe/STJr/SRB2.git into slope-cleanup
# Conflicts:
#	src/hardware/hw_main.c
#	src/p_spec.c
2020-05-18 16:14:05 +02:00
Louis-Antoine
6af2871fa5 Rename P_GetZAt to P_GetSlopeZAt and P_GetZAt2 to P_GetZAt 2020-05-18 15:23:56 +02:00
Jaime Passos
668b9bc684 Fix missing sprite column 2020-05-15 16:17:31 -03:00
Monster Iestyn
c06fbf4fe7 Merge branch 'master' into next 2020-05-06 21:51:36 +01:00
Monster Iestyn
145b7d8f66 Fix drop shadow and rotsprite code to use SHORT() 2020-05-02 17:13:16 +01:00
MascaraSnake
8efec04051 Remove POLYOBJECTS and POLYOBJECTS_PLANES defines 2020-05-02 12:08:31 +02:00
Monster Iestyn
e78a2fa297 Merge branch 'master' into next 2020-04-23 18:49:53 +01:00
James R
f68a361f6e Merge branch 'pk3-directory-start' into 'next'
Don't skip the first directory entry of PK3 if it's a file

See merge request STJr/SRB2!764
2020-04-09 19:49:44 -04:00
toaster
c74dde0f0f Minor optimisations surrounding R_DrawFlippedMaskedColumn.
* Replace the texheight parameter provided directly to it with a previously existing (now renamed) global used for the same purpose, so that it can be used as an interchangeable function pointer with R_DrawMaskedColumn.
* Using the above, optimise R_DrawVisSprite to call a function pointer in a tighter loop rather than check SC_VFLIP each time around.
* SHORT macro can involve repeated operations; calculate once and put in memory for both RANGECHECK and papersprite.
* Remove irrelevant range check (already covered by existing range check immediately above) from R_DrawFlippedMaskedColumn and R_DrawMaskedColumn.
* "Warning: avoiding a crash in %s %d" is a terrible error message, and it chips away at the tightness of the loop just for something most people will never see printed. Replace with a PARANOIA I_Error in case someone actively wants to go hunting for its cause.
2020-03-26 16:09:19 +00:00
Louis-Antoine
29294a53cc Encapsulate plane height checks 2020-03-22 17:28:50 +01:00
Louis-Antoine
4e7605f0e2 Make SRB2 flat like Earth 2020-03-20 18:55:29 +01:00
Monster Iestyn
d35464204e Set the "spritename" variable within R_AddSingleSpriteDef rather than externally to it, since R_InstallSpriteLump is the only place it gets used anyway
This way we don't have to make it some extern in order for r_skins.c to use it
2020-03-08 19:51:18 +00:00
Monster Iestyn
a12833ccd2 remove r_skins.c include in r_things.c, on second thoughts 2020-03-08 19:36:56 +00:00
Monster Iestyn
9013398151 Create r_skins.c/.h, to contain skins code formerly in r_things.c/h 2020-03-08 19:32:07 +00:00
Steel Titanium
fc042e90f0 Merge branch 'master' into next 2020-02-21 21:01:29 -05:00
James R
2274129f57 Update copyright year to 2020 2020-02-19 14:08:45 -08:00
James R
d6251a763b Merge branch 'viewroll' into 'next'
Rolling

See merge request STJr/SRB2!690
2020-02-17 00:10:57 -05:00
fickleheart
51ef6b3684 Merge remote-tracking branch 'upstream/master' into viewroll 2020-02-16 21:32:57 -06:00
MascaraSnake
4c4596a45f Clean up the mess that is extracolormap_t::fog 2020-02-16 20:19:24 +01:00
James R
eada06b7ff Add flag name variant of SF_NONIGHTSROTATION to S_SKIN 2020-02-12 18:02:36 -08:00
James R
e1b67967ce Don't skip the first directory entry of PK3 if it's a file
Also puts the marker skipping in the WAD API.
2020-02-07 19:41:45 -08:00
James R
ff2ec925ee Merge remote-tracking branch 'origin/master' into next 2020-01-30 23:54:56 -08:00
fickleheart
54a844a59e Fix lighting discrepancies between different FOVs 2020-01-18 00:16:18 -06:00
fickleheart
e0a6e7ec74 Avoid rendering unused left/right edges of screen while rolling 2020-01-17 23:21:11 -06:00
James R
ef459ba647 Don't draw Tails' tails in first person (MF2_LINKDRAW) 2020-01-17 20:56:32 -08:00
James R
a1a6956618 Duplicated code is gone, so sad 2020-01-17 20:53:36 -08:00
fickleheart
a69be1f388 DOUBLE DAMNIT 2020-01-17 00:34:57 -06:00
fickleheart
bc7a271901 Let nerds turn off shadows 2020-01-17 00:20:10 -06:00
fickleheart
fa245e90ae DAMNIT 2020-01-17 00:13:13 -06:00
fickleheart
4e97b1825b Let vissprites have shadows too
fuck it, hopefully it works
2020-01-17 00:13:05 -06:00
James R
362c74ea65 Don't draw player mobj in first person
This solves that annoying albeit slightly amusing bug
where your sprite clips into your view during a quake.

For OpenGL, this also solves the player's model
rendering while in first person. So you'll no
longer be looking through Sonic's body!
2020-01-16 03:18:05 -08:00
fickleheart
03d95484e2 Limit shadow Y scale to prevent graphical bugs 2020-01-12 09:10:09 -06:00
fickleheart
d2c6af1167 Add mobj shadowscale property 2020-01-11 18:24:08 -06:00
fickleheart
fb30054fcc Use dedicated shadow graphic 2020-01-11 17:56:49 -06:00
fickleheart
ad9bec06e6 Merge remote-tracking branch 'upstream/next' into software-dropshadows 2020-01-11 17:09:57 -06:00
Monster Iestyn
54f1cd601e Merge branch 'master' into next 2020-01-11 18:38:09 +00:00
James R
a77acb349a Merge branch 'accurate-papersprites' into 'master'
Accurate papersprite projection

See merge request STJr/SRB2!657
2020-01-10 16:02:23 -05:00
fickleheart
a21d664cd2 Fix shadows under hiresscale characters 2020-01-08 23:33:43 -06:00
fickleheart
52890deb59 Refactor shadow scale into an argument 2020-01-08 23:24:31 -06:00
fickleheart
9df5d1d0e3 Refactor shadow floor finding code a bit
I tried to fix ring shadows on polyobjects and got this in return:
https://media.discordapp.net/attachments/629477786943356938/664695818913185822/srb20156.png
2020-01-08 23:19:52 -06:00
fickleheart
d1793e8952 Stop misusing papersprite vars for sprite skew 2020-01-08 21:52:10 -06:00
fickleheart
c74ee13912 Apply portal clipping to drop shadows too 2020-01-08 21:37:44 -06:00
fickleheart
c7e28391a0 Make ring shadows smaller and fix scale bug 2020-01-08 21:37:43 -06:00
fickleheart
44aff735ac Fix more shadow crashes and save my sanity 2020-01-08 21:37:41 -06:00
fickleheart
8bf0c0533a FUCK IT, SLOPED SHADOWS NOW 2020-01-08 21:37:40 -06:00
fickleheart
9d2a3a060e This acursed crash-inducing typo spat in my face and called me a bitch 2020-01-08 21:37:39 -06:00
fickleheart
0ea9b26b97 Prevent linkdraw sprites from connecting to shadows 2020-01-08 21:37:38 -06:00
fickleheart
6326c3fe83 Add render-based drop shadows to some objects
Uses a hardcoded list for now. I was experiencing some
crashes with this, but the shadowyscale check seems to
have suppressed them.
2020-01-08 21:37:36 -06:00
fickleheart
e276e1979c Check for papersprites per-sprite instead of per-row
In theory, should be a performance improvement. In practice idk
2020-01-08 21:14:11 -06:00
fickleheart
8cae57eab0 Reduce disappearance of vissprites close to the camera 2020-01-08 21:14:09 -06:00