1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-16 03:23:15 +01:00
Commit Graph

99 Commits

Author SHA1 Message Date
Ted John
a48976cc6b Fix x86 warning 2016-09-06 22:06:56 +01:00
Ted John
220afe04d5 x64: Fix readentirefile calls 2016-09-06 21:33:15 +01:00
Michał Janiszewski
f8145b6edc Refactor inclusion of addresses.h
addresses.h is now only included when necessary, limiting scope as much
as possible.
2016-09-03 21:25:19 +01:00
Michał Janiszewski
f3fe28e722 Verify sv4/sc4 sizes when loading them 2016-09-01 22:56:30 +02:00
Ted John
8cf7e87b5c Fix many warnings for x64 2016-08-27 23:32:15 +01:00
Michał Janiszewski
b66853383e Add more checks to object loading 2016-07-15 18:50:15 +01:00
Ted John
dca816cfd3 Merge pull request #4024 from IntelOrca/refactor/object-list
Refactor and improve the object system:
- Objects are now exported to user directory under 'object'.
- Object directories are scanned recursively.
- Improves reliability of object loading and handling of bad objects.
- Improve performance of object scanning.
- Only load new objects when loading a new game.
- Improve changing language experience.
2016-07-11 23:45:45 +01:00
Michał Janiszewski
ef09dcd64a Add another assert to decode_chunk_rle_with_size 2016-07-11 22:52:43 +01:00
Michał Janiszewski
639f19adbf Fix define checks in project 2016-07-09 10:05:12 +02:00
Ted John
09782e980c implement saving of objects and fix other bugs 2016-07-08 22:58:38 +01:00
Sijmen Schoon
e882bfe736 Change strdup to _strdup 2016-07-06 18:50:30 +02:00
Sijmen Schoon
fcf4008395 Remember previous save/load location
Works for games, landscapes, scenarios and tracks (but this is commented out due to tracks not being separated or something?)
2016-07-06 18:22:08 +02:00
Michał Janiszewski
da08b963c9 Check RLE chunk size 2016-06-23 21:50:23 +01:00
Michał Janiszewski
bee6bcd1c7 Verify size in sawyercoding_read_chunk 2016-06-23 19:00:54 +01:00
Michał Janiszewski
644a36a310 Fixes to -Wall compilation
By default, not all warnings are enabled. This change makes sure that
the project compiles correctly with following options turned on:

    -Wall -Wno-unused-but-set-variable -Wno-missing-braces \
    -Wno-unknown-pragmas -Wno-unused-function
2016-06-20 13:46:27 +01:00
Ted John
1761907f57 handle bad map data and close connection 2016-06-09 18:37:12 +01:00
Michał Janiszewski
1508e49a28 Change macro to assert_struct_size 2016-06-03 11:29:50 +02:00
Michał Janiszewski
60630b9ad7 Drop PACKED attribute 2016-06-03 10:55:21 +02:00
Michał Janiszewski
df3030e4a9 Provide static_assert for hard-coded struct sizes. 2016-06-03 10:55:21 +02:00
Michał Janiszewski
3907fcd9d2 Explicitly pack structs 2016-06-03 10:55:21 +02:00
CraigCraig
3f9afb9744 Various Spellchecks (#3741) 2016-05-26 09:49:19 +02:00
Hielke Morsink
1089f02e15 Moved logically string compare function to utils 2016-05-22 21:48:14 +02:00
Ted John
8d4e4ed0e9 remove unread RCT2_GLOBALs 2016-05-17 23:39:37 +01:00
Hielke Morsink
d7aacfcde6 Fixed warning in sawyerencoding.c 2016-05-15 01:10:37 +02:00
Michał Janiszewski
90bcca11d2 More sawyercoding optimisations 2016-05-14 11:54:19 +02:00
Michał Janiszewski
9cd762b1a6 Use memset/memcpy functions for RLE chunk decoding
Reduces time spent in `decode_chunk_rle` by 4-5x.
2016-05-14 11:12:14 +02:00
janisozaur
658e877955 Name all the typdef-ed structs (#3581) 2016-05-12 22:57:40 +01:00
Ted John
4298f416d2 fix #3558: safely read chunks from S6 files
It appears many saved games have been saved with excess uncompressed data that overflows the S6 structure. This may have been caused by a save bug in an earlier version of OpenRCT2. This will now cap the uncompressed data to the amount expected.
2016-05-10 21:39:12 +01:00
janisozaur
68bad6505c Add and correct licence headers to all sources (#3108) 2016-05-04 18:24:41 +01:00
Ted John
cf7b81fd3a start moving RCT1 importer to C++ 2016-04-22 18:24:54 +01:00
Gymnasiast
2d3dfd8834 Move RCT1 file version detection to its own function 2016-04-22 18:23:46 +01:00
Michał Janiszewski
843014eac2 Silence compiler warning
Though this really should be taken care of properly, see
https://stackoverflow.com/questions/14562845/why-does-passing-char-as-const-char-generate-a-warning
2016-03-19 12:56:35 +01:00
IntelOrca
1daa657657 fix #3091: Korean words corrupted if over byte limit 2016-03-10 18:48:00 +00:00
Michał Janiszewski
016d26976e Add a note about low-hanging optimisation fruit 2016-02-15 00:17:15 +01:00
Michał Janiszewski
f447b9665a Use GCC's __builtin_ffs for bitscanforward impl 2016-02-15 00:05:33 +01:00
Michał Janiszewski
b89282cc2f Fix zlib inflate on broken builders 2016-01-24 21:36:14 +01:00
Michał Janiszewski
2439ba5b9c Fallback to non-compressed sv6 on broken builders 2016-01-24 21:01:31 +01:00
Michał Janiszewski
08fc5f817a Disable using RLE when saving for network 2016-01-20 15:30:59 +01:00
Michał Janiszewski
753d430eaa Add zlib-based compression and decompression 2016-01-20 15:30:59 +01:00
IntelOrca
24a796c3bc fix #2778: encode_chunk_repeat reads out of range memory 2016-01-19 17:54:51 +00:00
Ted John
5ef00393a4 Merge pull request #2739 from janisozaur/evergreen-gardens
Assert for evergreen gardens
2016-01-19 12:36:41 +00:00
Michał Janiszewski
3bf1e0e06d Rename safe_strncpy to safe_strcpy 2016-01-18 20:49:52 +01:00
Michał Janiszewski
5bc330f8db Minor fixes, mostly posix.c 2016-01-18 20:48:41 +01:00
Michał Janiszewski
f35fac6030 Update assert condition 2016-01-16 18:10:44 +01:00
Michał Janiszewski
2b29f252e5 Assert for evergreen gardens 2016-01-16 00:19:08 +01:00
IntelOrca
6a768c4a3c redo entire scenario highscore load / saving
- load and save highscores to new file format (highscores.dat)
- scan scenarios from RCT2 data and user data
- load highscores from legacy file (scores.dat)
- fix various issues with new scenario select window
2016-01-02 21:04:10 +00:00
Hielke Morsink
bc2ac2e28b Split extension setter into two functions 2016-01-02 20:45:00 +01:00
Hielke Morsink
f31a5f2248 More secure checks for removing and setting file extensions. 2016-01-02 18:57:11 +01:00
Hielke Morsink
eadb03426e fix #2620 and preventing names with dots from breaking. 2016-01-02 14:59:16 +01:00
Michał Janiszewski
36de7a9027 Fix warnings
Some off-by-one errors, truncation warning fix, main() in posix.c no
longer a stub.
2015-12-29 16:09:36 +01:00