Commit graph

1230 commits

Author SHA1 Message Date
Clownacy
c60cdb3610 Make CMake detect static SDL2 installations
Fixes #46
2019-09-10 12:23:09 +00:00
Clownacy
0510e017e1 Merge branch 'accurate' into portable 2019-09-10 02:03:58 +00:00
Clownacy
2cb7bfbd3d Tiny cleanup 2019-09-10 01:59:26 +00:00
Clownacy
355b303635 Shut up some warnings 2019-09-10 01:53:19 +01:00
Clownacy
751daaf42f Ignore another VS2017 file 2019-09-10 01:27:12 +01:00
Clownacy
271f86e009 Add 64-bit targets to VS2017 project 2019-09-10 01:25:47 +01:00
Clownacy
385d7e5844 Clean up Back.cpp a little 2019-09-10 01:04:09 +01:00
Clownacy
9ca503a96e Add Visual Studio 2017 project files
This required hacking-in DirectInput8 support since Visual Studio
hasn't supported DirectInput7 and earlier since 2007.
2019-09-10 00:43:23 +01:00
Clownacy
a81fe10fc7 Move Visual Studio 2003 files to their own folder
We don't want these conflicting with the upcoming Visual Studio 2017
files.
2019-09-10 00:41:32 +01:00
Clownacy
f8c2e17655 Clean up Map.cpp 2019-09-09 23:46:35 +01:00
Clownacy
c368734a5c Fix the resource file in MinGW-w64
I hate all these headers
2019-09-09 23:43:48 +01:00
Clownacy
3eb346ce10 Synchronise the audio callback with Organya
This is the 'perfect' Organya playback I mentioned in the commit
message for 5ea356a3bd
2019-09-09 21:43:33 +00:00
Clownacy
a076274864 Make a clamp macro safer 2019-09-09 20:24:09 +00:00
Gabriel Ravier
c492f9add1
Merge Clownacy/accurate into accurate (#28)
Merge Clownacy/accurate into accurate
2019-09-09 20:53:22 +02:00
Gabriel Ravier
3ce23e87aa
Merge Clownacy/master into master (#26)
Merge Clownacy/master into master
2019-09-09 19:22:09 +02:00
Clownacy
217ce5437b Port the Windows version's mouse-hiding
The original Windows version would hide the mouse cursor in
fullscreen.
2019-09-08 23:59:13 +00:00
Clownacy
e216fa8e18 Remove the old colour-depth code
It's basically unused anyway
2019-09-08 23:58:48 +00:00
Clownacy
4b8a6849d3 Actually make the surface regeneration work 2019-09-06 22:13:00 +01:00
Clownacy
b5f2fa8693 Add a DEBUG_SAVE option to CMakeLists.txt 2019-09-06 21:24:54 +01:00
Clownacy
668516f4e6 Add CMake info to the readme 2019-09-06 21:19:30 +01:00
Clownacy
950bf28273 Merge branch 'accurate' into portable 2019-09-06 21:08:25 +01:00
Clownacy
c5a4a3cb4c Future-proof the Windows resource file
Now it works with newer versions of Visual Studio
2019-09-06 21:04:40 +01:00
Clownacy
0532e2afa2 Shut up a warning 2019-09-06 20:08:07 +01:00
Clownacy
a220732aac Shut up some warnings 2019-09-06 20:03:35 +01:00
Clownacy
b53741ca25 Fix CMakeLists.txt some more 2019-09-06 19:59:44 +01:00
Clownacy
0907027a82 Merge branch 'accurate' into portable 2019-09-06 19:30:23 +00:00
Clownacy
9f40c68ab2 Repair CMakeLists.txt 2019-09-06 19:27:32 +00:00
Clownacy
d0b17cd406 Fix crash when quitting the game 2019-09-06 19:27:14 +00:00
Clownacy
4e239c3175 Restore the rendering backend callbacks
Now the SDLSurface backend survives window resizes (also triggered by
alt-tabbing while in fullscreen), and the SDLTexture backend properly
regenerates its textures after a fullscreen alt-tab in DirectX mode.
2019-09-06 19:07:49 +00:00
Clownacy
8114f88dd1 Shut up some build warnings 2019-09-06 15:21:43 +00:00
Clownacy
b6fccd509d Add a missing comment translation 2019-09-06 14:47:13 +00:00
Clownacy
0dc9bb6b1b Change the audio backend API again 2019-09-06 14:46:31 +00:00
Clownacy
d02af1bfba Merge branch 'accurate' into portable 2019-09-06 00:36:24 +00:00
Clownacy
9aa97205b7
Get Peter Mackay's name right 2019-09-05 23:35:59 +00:00
Clownacy
7dc8c8b2c1 Merge branch 'accurate' into portable 2019-09-05 23:01:49 +00:00
Clownacy
4d42842742
More readme work 2019-09-05 22:00:29 +00:00
Clownacy
7778e25369 Merge branch 'accurate' into portable 2019-09-05 21:42:49 +00:00
Clownacy
d80adf9cc8 Comment on a bug in MakePixToneObject 2019-09-05 21:41:40 +00:00
Clownacy
46fdc08ecd Fix PixTone sounds missing their ends
I was accidentally replicating a bug from the original code in the
wrong place. I should probably comment on that bug in the accurate
branch.
2019-09-05 21:39:38 +00:00
Clownacy
12f69e3c6c Fix idling hogging 100% of a CPU core
This was me not converting the WinAPI code properly. Stupid me.
2019-09-05 21:07:30 +00:00
Clownacy
1b8fbcee43 New screenshot
Shows CSE2 running on Arch Linux with XFCE4.
2019-09-05 20:57:48 +00:00
Clownacy
69d34f51bf Don't assume users are on Windows 2019-09-05 20:50:19 +00:00
Clownacy
2625af1ac8 Merge branch 'accurate' into portable 2019-09-05 20:49:42 +00:00
Clownacy
1f3c33f2a0 Merge branch 'accurate' into portable 2019-09-05 20:43:24 +00:00
Clownacy
7300157f54
Convert the Makefile setting list to a table 2019-09-05 19:48:27 +00:00
Clownacy
14442eaaba
Add some background information to the readme
Also removed the link to the woefully-neglected 'Bug Fixes.txt'.
2019-09-05 19:37:44 +00:00
Clownacy
eabda30263 Merge branch 'accurate' into portable 2019-09-05 17:19:48 +01:00
Clownacy
7f7553bef2 An accuracy improvement in Triangle.cpp
This one's weird: it doesn't affect the actual generation of ASM in
the function, but rather it affects the ASM of sinf and cosf.

You see, sinf and cosf are static - they're built right into the EXE.
Since the previous code used cosf and sinf, they were embedded into
the EXE, and InitTriangleTable would call them directly.

However, this isn't what the original EXE does: instead,
InitTriangleTable calls an intermediary function, that in turn calls
the real cosf and sinf. Turns out this strange code generation is
caused by calling cos and sin instead of cosf and sinf, but still
using float parameters.
2019-09-05 17:04:07 +01:00
Clownacy
af7d8222a8 The EXE now has its functions in the exact same order as the original
This is crazy. So, MSVC2003 always links the source files in
alphabetical order, but for some reason the original EXE ends with
the NPC and boss files.

Cucky figured out why: Pixel used folders in his Visual Studio
project - one for NPC code, and one for boss code.

With this, the built EXE now has its functions in the exact same
order as the original. Hell yeah. I guess now we just have to figure
out how to get the variables in the correct order.
2019-09-05 16:42:16 +01:00
Clownacy
c21bb1c14f Merge branch 'accurate' into portable 2019-09-05 16:12:36 +01:00