diff --git a/.gitignore b/.gitignore index 8b73f04f5..7f8d56035 100644 --- a/.gitignore +++ b/.gitignore @@ -13,16 +13,17 @@ Win32_LIB_ASM_Release *.dgb *.debug *.debug.txt -/bin/VC10/ -/objs/VC10/ *.user *.db *.opendb /.vs /debian /assets/debian -compile.sh -*.gz -.vscode/ -out -build +/make +/bin +/build +/build/* +/CMakeUserPresets.json +/out +/objs/VC10 +*.kate-swp diff --git a/CMakeLists.txt b/CMakeLists.txt index ceaf65f04..b7d280190 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.0) +cmake_minimum_required(VERSION 3.5) # DO NOT CHANGE THIS SRB2 STRING! Some variable names depend on this string. # Version change is fine. project(SRB2 diff --git a/LUASTUFF.md b/LUASTUFF.md index 881cbe4f7..83ec76545 100644 --- a/LUASTUFF.md +++ b/LUASTUFF.md @@ -156,6 +156,42 @@ Add Gamepad Rumble support for things. To be used with Displayplayers. Duration is in milliseconds and is optional to set, default value is 84ms. +## P_CheckSightFast(mo1, mo2) + +Exactly same as P_CheckSight but uses cheaper algorithm, useful for things like nametags. Doesn't work exactly +like P_CheckSight so don't use it for anything gameplay-related. + +## musicdef_t + +Userdata structure representing a musicdef. Fields: + +`musicdef.name` - song identifier ("kmap01" for example). + +`musicdef.usage`, `musicdef.source` - fields from vanilla MUSICDEFS lump. + +`musicdef.filename` - unused for now. + +`musicdef.title`, `musicdef.alttitle`, `musicdef.authors` - fields from MUSCINFO lump. + +`#musicdef` - returns integer id for musicdef (which can be used as index in `musicdefs`). + +All fields are read-only. + +## S_FindMusicCredit(name) + +Returns musicdef corresponding to music with given identifier. For example, `S_FindMusicCredit("kmap01")` will return +musicdef for green hills music. + +## musicdefs + +Global table for all musicdefs, similar to mobjinfo, states, etc. Can take either integer indices, +from `0` to `#musicdefs-1`, or string indices (which is equal to calling `S_FindMusicCredit`). + +## addHook("MusicCredit", function(musicdef)) + +Hook is called whenever `S_ShowMusicCredit` (either from game or mod) is called. Takes musicdef as only argument, returning true +will overwrite vanilla behavior (not show music credit), can be used to implement custom music credit pop-ups. + # Other changes ## P_PlayRinglossSound(source, damager) diff --git a/SRB2.cbp b/SRB2.cbp index b4cf543db..e5be4f5e0 100644 --- a/SRB2.cbp +++ b/SRB2.cbp @@ -1726,11 +1726,6 @@ HW3SOUND for 3D hardware sound support