Commit graph

19942 commits

Author SHA1 Message Date
Sally Coolatta
192b30f8ea Save+load SRB2 vars on ACS threads 2024-10-15 07:52:25 -04:00
Sally Coolatta
9ce121233e Add save/load stream for ACS
Saves the majority of the VM state, but not the SRB2-specific vars ... that can come after food
2024-10-15 07:51:13 -04:00
Sally Coolatta
e23180283a Contain end & size into savebuffer_t
I would've liked to make it use a single allocate function to do this very cleanly, but these cases were very clearly not meant to be standardized and use wildly different methods to allocate & free...
2024-10-15 07:48:51 -04:00
James R
3fb806ed71 Remove global lua_save_p and use savebuffer_t for LUA_Archive / LUA_UnArchive 2024-10-15 07:43:52 -04:00
James R
e91701fe5b g_demo.c: use savebuffer_t 2024-10-15 07:41:38 -04:00
NepDisk
7a4b3e8017 Fix corrupt save files 2024-10-15 06:55:41 -04:00
Sally Coolatta
07cdd2f461 Make save_p / savebuffers not global
This caused some scary issues with P_SaveNetGame the other day, and it's making ACS net sync harder. Let's just cut this off right now.

Also fixed some scary mix-ups in some of the Lua archiving code.
2024-10-15 06:41:25 -04:00
Sally Coolatta
8637dc3ce3 Fully port the ACS integration to C++ and make it build 2024-10-15 06:01:14 -04:00
James R
6de3a1b573 Merge branch 'cmake-testers' into 'master'
Add TESTERS and HOSTTESTERS builds to CMake options

See merge request KartKrew/Kart!830
2024-10-15 04:45:25 -04:00
toaster
0e53b0513f Remove dynamic base from CMake target link options
Permits functional debugging of crash reports by preventing ASLR
2024-10-15 04:44:21 -04:00
James R
bcf014a539 .gitignore: add CMakeUserPresets.json 2024-10-15 04:44:14 -04:00
Sally Coolatta
e250450084 Add ACSVM building to CMake
Currently this breaks some parts of the ACS functionality ... before I made a handful of small extensions to ACSVM's slightly-limited C API myself, and I didn't get them into the actual repo yet.

But now that we've moved to actual C++ compiling, I will likely just flat-out rewrite the SRB2 side of the code in C++ so it can use the library directly.
2024-10-15 04:44:02 -04:00
Sal
f0370fc1a1 Merge branch 'cmake-sources' into 'master'
Move sources list from Sourcefile to CMakeLists.txt

See merge request KartKrew/Kart!795
2024-10-15 04:36:26 -04:00
NepDisk
ae739b9ef1 Merge branch 'CPP' into ACS2 2024-10-15 04:25:57 -04:00
NepDisk
872b3b70c1 Disable catch 2 2024-10-15 04:23:59 -04:00
Sal
f503d88ab5 Merge branch 'enable-cxx' into 'master'
Enable C++17 additionally with Catch2 unit testing

See merge request KartKrew/Kart!807
2024-10-15 04:19:22 -04:00
NepDisk
c7b48c8fe4 Remove unused headers 2024-10-15 04:18:11 -04:00
James R
9e801c66d5 Merge branch 'universal-typedef' into 'master'
Move all typedef into one file

See merge request KartKrew/Kart!791
2024-10-15 04:16:58 -04:00
Eidolon
a4f618b052 cmake: Fix png and openmpt builds in clean envs
In environments without zlib installed, png would fail to build since
it can't find zlib.h. The zlib build's generated public include dir
needs zlib.h to work.

openmpt fails to build because it can't find Rpcrt4, which is not a
necessary link under mingw, but exists in some mingw-w64 toolchains.
It is only needed for MSVC.

(cherry picked from commit fcf69001ada08077f82d3fc8510dcd24b4433e64)
2024-10-15 03:42:15 -04:00
Eidolon
475215dec4 cmake: Use MAME YM2612 emu in GME
(cherry picked from commit fb0f0c5e6c161b4b88439cda84c8b6cae9d236cc)
2024-10-15 03:42:07 -04:00
Eidolon
9b2a590938 Cherry-pick internal zlib MR from SRB2/next
cmake: build zlib manually in internal build

See merge request STJr/SRB2!1856

(cherry picked from commit 3597957af13878854c02305a0aec5ca744209ef2)

# Conflicts:
#	thirdparty/CMakeLists.txt
2024-10-15 03:41:53 -04:00
Sal
45cd500eda Merge branch 'cmake-fix-override-exe-name' into 'master'
cmake: let SRB2_SDL2_EXE_NAME override git branch

See merge request KartKrew/Kart!796
2024-10-15 03:41:02 -04:00
Sal
4d1add7e4c Merge branch 'cmake-overhaul' into 'master'
cmake: Rollup of srb2-side changes

See merge request KartKrew/Kart!758
2024-10-15 03:40:29 -04:00
NepDisk
1288c80d8b Fix flat animation 2024-10-13 16:08:36 -04:00
NepDisk
afecac0c00 Remove unused titlecard code, some unused sounds and simplify pvp damage code 2024-10-12 22:02:51 -04:00
Alug
739b84ea28 Remove GLU library loading code
hope i didnt forger smth X)
2024-10-12 01:23:03 -04:00
Alug
674290dc11 Better Opengl version check
somehow forgor about vendor information in the version string lmao
2024-10-12 01:22:34 -04:00
Alug
26304d0bbb Replace glBuild2DMipmaps with GL_GENERATE_MIPMAPS
Quote "gluBuild2DMipmaps. Never use this."
gluBuild2DMipmaps was causing massive stutters on many maps on windows
this replaces it with GL_GENERATE_MIPMAP and removes glBuild2DMipmaps completely

https://www.khronos.org/opengl/wiki/Common_Mistakes
2024-10-12 01:22:29 -04:00
NepDisk
9a6aeaaa56 Allow ACS to call linedef specials as functions 2024-10-10 15:30:22 -04:00
Sally Coolatta
9d0ae3e489 Add LAP script type
GDCC just updated after my feature request for remappable script type names, so there's no more limitations surrounding those.
2024-10-10 15:17:17 -04:00
NepDisk
6edb12de78 Revert " Allow ACS to call linedef specials as functions"
This reverts commit f46a9ed5fa.
2024-10-10 15:14:01 -04:00
NepDisk
f46a9ed5fa Allow ACS to call linedef specials as functions 2024-10-10 15:10:18 -04:00
NepDisk
40270bcf3d Fix acs map lump reading 2024-10-10 14:18:29 -04:00
Indev
2eea1d0cde Those were not necessary oops 2024-10-10 20:59:05 +03:00
Indev
03c740503e Attempt to fix ACS library linking 2024-10-10 20:56:12 +03:00
Alug
5e5144822e shut up -Wcomment warnings pls 2024-10-10 18:08:24 +02:00
NepDisk
19ef4ef1e0 add to cmakelists? 2024-10-10 12:04:31 -04:00
NepDisk
84bff805e9 Fix perfstats, add acs folder 2024-10-10 11:29:58 -04:00
Sally Coolatta
ff1f91ebad Implement remaining ACS0 codes that apply to SRB2
Only thing left to reach parity with Hexen is being able to use linedef specials as functions
2024-10-10 01:43:42 -04:00
Sally Coolatta
89a5ea4a21 Keep track of script activators
Can supply the activating object, line, line side, polyobject, and (added for SRB2) sector.
2024-10-10 01:43:33 -04:00
Sally Coolatta
eff994fd60 Add ThingCount
Hexen implements this as ThingCount(int, int), and ZDoom adds ThingCountName(str, int). I decided on simplifying down to ThingCount(str, int).
2024-10-10 01:42:38 -04:00
Sally Coolatta
27ae35a82f Add ChangeFloor/Ceiling, fix Random 2024-10-10 01:42:33 -04:00
Sally Coolatta
4cd8aaa8b7 More code cleanup
- Inline function to simplify adding call funcs
- Implemented print when thread is killed
2024-10-10 01:42:26 -04:00
Sally Coolatta
3e5fb19e2d Commentate code, add a few more CallFuncs 2024-10-10 01:42:04 -04:00
Sally Coolatta
f5fe8ddcbe Reset hub & map scopes on map load 2024-10-10 01:41:36 -04:00
Sally Coolatta
629b0aa77a ACS basic implementation
- BEHAVIOR lumps successfully load & run from maps. Currently they do not get unloaded between maps, though.
- Print and Timer are the only implemented CallFuncs. All of the base language functions (Delay, etc) are already implemented by the VM though.
- ACS compiler files are included, for use with GDCC. (Picked instead of ACC because it's less ZDoom-centric)
- Additionally, also added the configs for Zone Builder to be able to compile it in editor. Syntax highlighting is very incomplete atm.
2024-10-10 01:41:24 -04:00
Sally Coolatta
8d8100166e Attempt using ACSVM to implement
It's having trouble linking the dll on Windows currently
2024-10-10 01:40:23 -04:00
NepDisk
267e84d562 Change speed for this object 2024-10-09 23:05:19 -04:00
NepDisk
f4ce1a8f78 Add support for record attack and encore load linedef effects 2024-10-09 20:20:22 -04:00
NepDisk
8854918375 ACtually Fix content id music cvar 2024-10-09 19:16:52 -04:00