Commit graph

358 commits

Author SHA1 Message Date
CobaltBW
48514ee88d Fixed G_RemovePlayer crash in players.iterate
This was done by storing flag-for-removal status as a boolean inside the player struct.
Bot players are instead removed at the start of G_Ticker, rather than being removed immediately by G_RemovePlayer.
2021-07-15 15:04:24 -07:00
Shane Ellis
18c47afc76 Merge branch 'next' into 'addplayer'
# Conflicts:
#   src/lua_baselib.c
#   src/r_skins.c
2021-06-02 11:47:11 -04:00
SteelT
ad2b4b1809 Merge branch 'save-skin-names' into 'next'
Save skin names in save files instead of skin numbers

See merge request STJr/SRB2!1503
2021-05-28 22:05:20 -04:00
Steel Titanium
a2667f4dc9 Merge branch 'master' into next 2021-05-11 20:08:44 -04:00
Sally Coolatta
d136c60a3f Add some comments, write an empty string instead of a boolean determining if the bot skin exists or not.
I was a little scared of doing this at first, but after a bit of thought & some testing that it'll be fine.
2021-05-07 20:13:16 -04:00
Sally Coolatta
dc6851dabc Save skin name instead of skin number into save files
Allows you to save a game as any character, and you don't have to load the files in a specific order to access the save file.
2021-05-07 19:41:44 -04:00
LJ Sonic
d325c7e6d3 The year is 2021 2021-05-07 17:45:56 +02:00
Monster Iestyn
34fa977192 move the old "can't load the level" error to its proper place, added specific error messages for all the times that unarchiving Lua banks can fail 2021-04-26 19:07:11 +01:00
CobaltBW
b112e12c93 Merge remote-tracking branch 'origin/next' into addplayer 2021-01-23 13:33:19 -08:00
Shane Ellis
1274b4651e Added botstuffs to savestate 2021-01-23 10:39:59 -05:00
Jaime Ita Passos
f3ad648874 Revert "Move a few mobj spawn defaults to its own function"
This reverts commit 6f9c48a305.

# Conflicts:
#	src/p_mobj.c
2021-01-17 23:17:46 +01:00
Jaime Ita Passos
6f9c48a305 Move a few mobj spawn defaults to its own function 2020-12-06 17:46:35 -03:00
Jaime Ita Passos
24ba782144 Fix archived mobjs having no default blend mode and sprite scales 2020-12-06 17:29:20 -03:00
James R
8d71559afe Merge branch 'make-some-lua-globals-rw' into 'next'
Make several Lua global variables writable.

See merge request STJr/SRB2!1233
2020-11-22 18:47:53 -05:00
Jaime Ita Passos
5e890ee6f8 Merge branch 'next' into spritestuff2 2020-11-19 00:52:43 -03:00
Nev3r
fb9432ae57 Merge branch 'next' of https://git.do.srb2.org/STJr/SRB2 into udmf-multitag 2020-11-10 11:46:53 +01:00
GoldenTails
9e6c0c31be Add skincolor vars to the NetSave 2020-11-08 20:43:16 -06:00
Nev3r
c62ef355ef Merge branch 'next' of https://git.do.srb2.org/STJr/SRB2 into udmf-multitag
# Conflicts:
#	src/lua_baselib.c
#	src/lua_maplib.c
2020-10-27 20:48:25 +01:00
Jaime Passos
b872222b50 Implement blend modes 2020-10-27 00:03:41 -03:00
Louis-Antoine
50d2c95470 Merge branch 'next' of https://git.do.srb2.org/STJr/SRB2.git into resend-gamestate 2020-10-24 16:21:44 +02:00
Jaime Passos
e63efdac13 Only create floor sprite slopes when needed, instead of always allocating them.
Has to be done manually in Lua. Use P_CreateFloorSpriteSlope, and P_DeleteFloorSpriteSlope when done with it.
2020-10-14 13:07:02 -03:00
Jaime Passos
ab526e47cc Implement object-defined floor sprite slopes. 2020-10-14 00:57:13 -03:00
Jaime Passos
4273896311 Implement relative and absolute sprite offsets for objects (mobjs)
Added RF_ABSOLUTEOFFSETS and RF_FLIPOFFSETS
2020-10-13 12:57:36 -03:00
Jaime Passos
cc97e22e2f Changes to sprite rendering:
- Added render flags (see r_defs.h)
- Implemented floor splats
- Drop shadow sprite rendering through render flags
2020-10-12 00:13:22 -03:00
SteelT
a033f482be Merge branch 'pictureformats' into 'next'
PNG conversion refactoring

See merge request STJr/SRB2!675
2020-09-10 15:58:18 -04:00
Jaime Passos
9b426b474c Merge branch 'pictureformats' into patch-stuff-again-2 2020-08-15 20:48:28 -03:00
Louis-Antoine
9dd5c11322 Merge branch 'next' of https://git.magicalgirl.moe/STJr/SRB2.git into resend-gamestate
# Conflicts:
#	src/d_clisrv.c
#	src/d_clisrv.h
#	src/d_net.c
#	src/p_saveg.c
#	src/p_saveg.h
2020-08-13 13:53:10 +02:00
Nev3r
ad55f5f872 Merge branch 'udmf-next' of https://git.magicalgirl.moe/STJr/SRB2/ into udmf-multitag
# Conflicts:
#	src/hardware/hw_main.c
#	src/p_ceilng.c
#	src/p_floor.c
#	src/p_mobj.c
#	src/p_mobj.h
#	src/p_polyobj.c
#	src/p_saveg.c
#	src/p_setup.c
#	src/p_spec.c
#	src/p_spec.h
#	src/p_user.c
#	src/r_bsp.c
#	src/r_defs.h
2020-07-10 18:18:07 +02:00
Jaime Passos
7911deebf8 Merge branch 'next' of https://git.magicalgirl.moe/STJr/SRB2 into pictureformats 2020-07-06 19:29:14 -03:00
Nev3r
fd5b05cafc Merge branch 'next' of https://git.magicalgirl.moe/STJr/SRB2/ into udmf-next 2020-07-06 11:13:27 +02:00
LJ Sonic
6e7446dea3 Merge branch 'ff_horizontalflip' into 'next'
FF_HORIZONTALFLIP and mobj->mirrored (sprite enhancements)

See merge request STJr/SRB2!987
2020-07-03 16:56:32 -04:00
Nev3r
ff8759e507 Merge branch 'next' of https://git.magicalgirl.moe/STJr/SRB2/ into udmf-next
# Conflicts:
#	src/hardware/hw_main.c
2020-06-30 20:29:48 +02:00
toaster
4502604007 Special saves!
All this refactoring, just to resolve #162. Specifically, it engages savegame events not at level load (except for savefile start) but on level completion, just after you've gotten all the intermission bonuses but before the intermission actually starts.

Also fixes a never-before-discovered bug where if the titlemap has LF_SAVEGAME, your save file will be overwritten upon returning to the title screen. This game is a mess of hacks, I swear...

One unintended side effect: It may actually be faster in some speedrun circumstances in mods with cutscenes to complete the map, exit back to the title screen, and reload the file. It's a common feature of optimal runs in games with cutscenes, though, and Marathon Run has a toggle for cutscenes, so I'm not particularly bothered.
2020-06-22 19:00:47 +01:00
kaysrishaq
cad1f57b1e FF_HORIZONTALFLIP and mobj->mirrored (sprite enhancements) 2020-06-19 11:11:18 -04:00
SteelT
bff6b19056 Merge branch 'marathonmode' into 'next'
MARATHON RUN

See merge request STJr/SRB2!941
2020-06-17 19:36:10 -04:00
MascaraSnake
4a0206b38d Merge branch 'next' into udmf-next
# Conflicts:
#	src/p_mobj.c
#	src/p_polyobj.c
2020-06-09 09:38:01 +02:00
Lachlan Wright
191e2e094d Merge branch 'fix-spawn-desynch' into 'next'
Fix desynch when a player spawns

See merge request STJr/SRB2!977
2020-06-08 05:25:41 -04:00
Monster Iestyn
9e4ed738b7 Sync turnobjs for polyrotate_t thinkers in netgames 2020-06-04 21:31:26 +01:00
LJ Sonic
e2b860dc28 Merge branch 'next' into 'fix-spawn-desynch'
# Conflicts:
#   src/p_map.c
2020-06-01 08:15:02 -04:00
MascaraSnake
508160ed42 Use 0 instead of 0xffff as dummy mobjnum 2020-05-31 22:58:14 +02:00
MascaraSnake
3a4502fa87 Netsync waypoint sequences 2020-05-31 22:44:25 +02:00
Louis-Antoine
67eef5a37f Fix potential desynch when a player spawns 2020-05-28 11:03:35 +02:00
SwitchKaze
b37c73b008 Make colors UINT16, increase color freeslots to 1024 2020-05-23 19:35:36 -05:00
MascaraSnake
6f854f2de3 Merge branch 'more-polyobject-cleanup' into 'next'
Smooth polyobject movement and other cleanup

See merge request STJr/SRB2!947
2020-05-18 16:00:55 -04:00
MascaraSnake
a7c7f7afa9 Merge branch 'fof-cleanup' into 'next'
FOF cleanup

See merge request STJr/SRB2!910
2020-05-17 02:30:16 -04:00
MascaraSnake
3680b246c9 T_PolyObjWaypoint: We can find waypoints in constant time now, so no need to store the waypoint mobj in the thinker anymore 2020-05-16 09:03:02 +02:00
Jaime Passos
1a79f6246d Merge remote-tracking branch 'origin/next' into pictureformats 2020-05-15 01:34:54 -03:00
toaster
d593e2e1bb Introducing Marathon Run. (I was going to call it Marathon Mode, but NiGHTS Mode being right next to it on the menu looked terrible.)
Basically a dedicated Record Attack-like experience for speedrunning the game as a continuous chunk rather than ILs. Has several quality of life features.

Benefits include:
* An unambiguous real-time bar across the bottom of the screen, always displaying the current time, ticking up until you reach the ending.
* Disable the console (pausing is still allowed, but the timer will still increment).
* Automatically skip intermissions as if you're holding down the spin button.
* Show centiseconds on HUD automatically, like record attack.
* "Live Event Backups" - a category of run fit for major events like GDQ, where recovery from crashes or chokes makes for better entertainment. Essentially a modified SP savefile, down to using the same basic functions, but has its own filename and tweaked internal layout.
* "spmarathon_start" MainCfg block parameter and "marathonnext" mapheader parameter, allowing for a customised flow (makes this fit for purpose for an eventual SUGOI port).
* Disabling inter-level custom cutscenes by default with a menu option to toggle this (won't show up if the mod doesn't *have* any custom cutscenes), although either way ending cutscenes (vanilla or custom) remain intact since is time is called before them.
* Won't show up if you have a mod that consists of only one level (determined by spmarathon_start's nextlevel; this won't trip if you manually set its marathonnext).
* Unconditional gratitude on the evaluation screen, instead of a negging "Try again..." if you didn't get all the emeralds (which you may not have been aiming for).
* Gorgeous new menu (no new assets required, unless you wanna give it a header later).

Changes which were required for the above but affect other areas of the game include:
* "useBlackRock" MainCFG block parameter, which can be used to disable the presence of the Black Rock or Egg Rock in both the Evaluation screen and the Marathon Run menu (for total conversions with different stories).
* Disabling Continues in NiGHTS mode, to match the most common singleplayer experience post 2.2.4's release (is reverted if useContinues is set to true).
* Hiding the exitmove "powerup" outside of multiplayer. (Okay, this isn't really related, I just saw this bug in action a lot while doing test runs and got annoyed enough to fix it here.)
* The ability to use V_DrawPromptBack (in hardcode only at the moment, but) to draw in terms of pixels rather than rows of text, by providing negative instead of positive inputs).
* A refactoring of redundant game saves smattered across the ending, credits, and evaluation - in addition to saving the game slightly earlier.
* Minor m_menu.c touchups and refactorings here and there.

Built using feedback from the official server's #speedruns channel, among other places.
2020-05-14 23:10:00 +01:00
MascaraSnake
7413da918b Store PolyObject waypoint return behavior in an enum 2020-05-13 16:21:47 +02:00
MascaraSnake
b561ee7921 Remove diffx/y/z from polywaypoint_t, since they're always 0 anyway 2020-05-13 14:40:07 +02:00