Commit graph

1352 commits

Author SHA1 Message Date
Clownacy
a70b4e444e Add CMake info to the readme 2020-03-14 19:42:58 +00:00
Clownacy
efa987d7ad Make the static MSVC runtime linkage optional
I'd tell people to use CMAKE_MSVC_RUNTIME_LIBRARY instead, but, eh,
it's too recent.
2020-03-14 19:36:47 +00:00
Clownacy
de1740b61c Match the portable branch's CMakeLists.txt 2020-03-14 19:15:41 +00:00
Clownacy
3de557807c This option shouldn't be on by default 2020-03-14 19:10:31 +00:00
Clownacy
140c67a5cb Make CMake file match the portable branch one 2020-03-14 19:09:32 +00:00
Clownacy
169a755ec3 Wrap UTF-8 strings in C89-style comments
This should prevent compilation errors when compilers don't read the
source files as UTF-8.

MSVC in certain codepages previously misread some UTF-8 comments as
containing newlines, causing it to try to process the rest of the
comment as code. This was fixed by forcing MSVC to read the files as
UTF-8 using the `/utf-8` flag, but this doesn't seem to be supported
in older versions.

Since the issue was caused by newlines being added where they didn't
belong, using C89-style comments instead should avoid the problem
altogether.

I'll still keep the utf-8 flag around for supported compilers - just
in case.
2020-03-14 14:12:53 +00:00
Clownacy
76e4fb5e8a Improve MSVC6 hacks 2020-03-14 14:08:25 +00:00
Clownacy
c6b77fb015 Move the windows.h include to the right place 2020-03-14 13:25:25 +00:00
Clownacy
8a3b5c1f7a Use macros instead of __stdcall
Wow Microsoft's documentation sucks: it constantly omits these,
making you think they're just plain `__cdecl`.
2020-03-14 13:22:36 +00:00
Clownacy
4e0a168533 Move the MSVC6 hacks to WindowsWrapper.h
Now the wrapper has a purpose again, and it keeps things neat.
2020-03-14 12:55:22 +00:00
Clownacy
05fb5cf106 Fix build error with MinGW 2020-03-13 22:01:02 +00:00
Clownacy
406ff18909 Add CMakeLists.txt and Visual Studio 6 support
The CMake file allows you to compile the accurate branch with
whatever version of Visual Studio you have lying around, without
having to clumbsily convert the VS2003 project.

I've tested this with VS2019, VS2003, and VS6. VS6 is goofy - it's
missing a few types and constants, and it's not smart enough to
realise that ints and longs are the same in ILP32 data models. I've
added a few small hacks to address this. Might undo them. Who knows.

For now, I want to support VS6 because Mint compiled CSE2 with it
before, and because VS6 uses `msvcrt.dll` as its C runtime, which
apparently comes pre-installed in Windows, as opposed to all those
other annoying runtime versions that require they be installed
separately (which is why MinGW targets it specifically).

Also, VS6 *should* give us Win95-compatible builds. The internet says
MSVC2003 is Win95-compatible too, but Mint claims the vanilla EXE
doesn't run on there. I imagine it has something to do with its
static runtime library (VS2003 links the static one by default for
some reason).
2020-03-13 21:35:51 +00:00
Clownacy
e4a20a983e
Similar fixes 2020-02-20 15:59:04 +00:00
Clownacy
ed97e374f8
Fix screen centering in wide/tallscreen
Previously, it would misbehave if the screen is slightly wider than the level
(because it wasn't accounting for the fact that the game hides half of the
border tiles)
2020-02-20 13:11:39 +00:00
Clownacy
a7f1d80a06 Fix compilation with modern Visual Studio 2020-02-13 18:16:01 +00:00
Clownacy
fd19806eaf Travis: Add FIX_BUGS and JAPANESE to matrix
Also changed it to only produce release builds
2020-02-05 21:05:20 +00:00
Clownacy
a762f28837 Note some out-of-bounds array accesses
Thanks, Gabe
2020-02-01 12:45:32 +00:00
Clownacy
c204ba140e Update PHILOSOPHY.md 2020-02-01 11:49:18 +00:00
Clownacy
3597addf51 Add PHILOSOPHY.md 2020-01-30 17:30:37 +00:00
Clownacy
30dced2587 Correct the style of some pointer checks 2020-01-26 13:52:24 +00:00
Clownacy
0bcf978424 Rename HookDirectInputDevice 2020-01-24 21:00:34 +00:00
Clownacy
946d816a3b Add save data to .gitignore 2020-01-24 14:22:05 +00:00
Clownacy
917d69fc4a Move the data folder back to the game folder
The whole 'copy data folder from assets folder to the game folder
when Makefile is ran' thing just made modding annoying.
2020-01-24 13:44:57 +00:00
Clownacy
53f7c02f5f Fix typo in Travis file
I hate learning new languages...
2020-01-23 22:08:01 +00:00
Clownacy
a3bd721df2 Clean-up Travis file 2020-01-23 22:01:30 +00:00
Clownacy
8905a2ee49 Try to get ccache working again 2020-01-23 17:27:44 +00:00
Clownacy
0090c9a226 And again 2020-01-23 17:08:39 +00:00
Clownacy
d24006c966 Try to get environment variables right 2020-01-23 17:07:41 +00:00
Clownacy
7f88a86916 Travis = >:( 2020-01-23 17:05:25 +00:00
Clownacy
2a74ab6d27 Place your bets
Will this random change fix it?
2020-01-23 17:02:14 +00:00
Clownacy
1b64bb71b7 Life is pain 2020-01-23 17:00:12 +00:00
Clownacy
e504f07650 ...Try again 2020-01-23 16:59:20 +00:00
Clownacy
91f71d4030 Try to split 32-bit/64-bit builds 2020-01-23 16:57:58 +00:00
Clownacy
a20b906257 Fix some stupid error that was caused by...
...literally nothing
2020-01-23 16:38:51 +00:00
Clownacy
d4214e6dc9 ??? 2020-01-23 16:27:45 +00:00
Clownacy
057e762279 Screw you Travis 2020-01-23 16:25:31 +00:00
Clownacy
871e443f90 swearing 2020-01-23 16:20:09 +00:00
Clownacy
31fa8f7352 Say it with me: "this is annoying" 2020-01-23 16:19:07 +00:00
Clownacy
ae016bbcf6 ...And again 2020-01-23 16:15:24 +00:00
Clownacy
e45bac46db Clearly I don't understand Bash syntax 2020-01-23 16:14:51 +00:00
Clownacy
cd415916ac Travis: Try to fix WINDRES and 32-bit builds 2020-01-23 16:12:33 +00:00
Clownacy
5ac0f5d160 Install regular make? 2020-01-23 15:55:36 +00:00
Clownacy
c793e302db Dummy out 32-bit for now
Travis's example Windows script is 64-bit-only. I'll hack it up in a
bit.
2020-01-23 15:38:13 +00:00
Clownacy
05e0b49c29 Work already dammit 2020-01-23 15:28:41 +00:00
Clownacy
cbe6262e74 Try to fix whatever syntax error Travis isn't...
...telling me about.

Also this 50 letter limit is stupid
2020-01-23 15:26:25 +00:00
Clownacy
d8d08bf553 Try to get a Travis native Windows build working 2020-01-23 15:21:14 +00:00
Clownacy
d33e007d0f Apparently Travis's 'sudo' is deprecated now? 2020-01-23 15:03:04 +00:00
Clownacy
5fd0b5839b More Travis cleanup 2020-01-23 14:32:29 +00:00
Clownacy
35ac2aead8 Er, don't break the Travis file 2020-01-23 14:25:30 +00:00
Clownacy
55090dc7cc Attempt to build release and debug binaries
Also build static binaries, since that's what's intended for the
Windows builds
2020-01-23 14:23:02 +00:00