1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-15 19:13:07 +01:00
Commit Graph

14 Commits

Author SHA1 Message Date
Linus Unnebäck
4319e57024 use builtin min and max 2015-12-15 09:11:54 +01:00
Michał Janiszewski
98e204552a countof with type safety
For reference see http://www.g-truc.net/post-0708.html and
http://lxr.free-electrons.com/source/include/linux/kernel.h#L54

This will provide a type-safe mechanism for counting elements of array.
If you try passing something which cannot be counted, compiler will
frown at you right away.
2015-12-15 00:28:58 +01:00
Michał Janiszewski
fb9a5833d6 Fix override offsets while loading LanguagePack
When loading language pack, a check is made not to double entries. This
check was wrong, because it tried to use offsets as pointers to strings.

These offsets are later rewritten to actual pointers in remaining part
of LanguagePack::LanguagePack
2015-10-09 20:19:58 +02:00
Michał Janiszewski
6dd04bbb1a Don't copy more memory than we own 2015-10-09 20:19:34 +02:00
IntelOrca
c6b0d0919d fix #1982 2015-09-28 18:10:41 +01:00
IntelOrca
f988f69ae0 implement sub_6D31A6 2015-09-13 03:00:03 +01:00
Michał Janiszewski
17e635b8af In C++11 use actual pointer types instead of C's defines
This is mostly `NULL` -> `nullptr` in cpp files, but I only noticed
because `LanguagePack::GetObjectOverride` and
`LanguagePack::GetScenarioOverride` were returning false instead of real
pointer.

Also fixes some whitespaces, you can `w=1` to github's URL to make it
skip these.
2015-09-10 08:22:36 +02:00
IntelOrca
289555c082 fix #1908 2015-09-09 19:22:41 +01:00
Gymnasiast
188978936b Fix Math.Clamp definition 2015-09-08 21:37:24 +01:00
IntelOrca
fc65a92275 fix object override strings for scenario editor and plugin.dat 2015-09-08 21:37:24 +01:00
IntelOrca
34cd6a9242 fix GCC compile issue 2015-09-08 21:37:22 +01:00
IntelOrca
8085abadd3 add basic support for localisation object string overriding 2015-09-08 21:37:22 +01:00
IntelOrca
7a0478404e add new C++ memory utility functions 2015-09-08 21:37:21 +01:00
IntelOrca
8ec51b6fc1 add FileStream, IStream and IDisposable 2015-09-08 21:37:20 +01:00