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

39 Commits

Author SHA1 Message Date
duncanspumpkin
2d1ed8ce05 Fix interactive console staff set costume command.
After the refactor to GameActions, forgot to actually issue the command after generating it.
2019-02-24 18:10:07 +00:00
Michael Steenbeek
dfa0c528c2 Rename command to forbid_marketing_campaigns
Co-Authored-By: IntelOrca <ted@brambles.org>
2019-02-20 16:49:03 +00:00
Ted John
4013479094 Refactor marketing to be a single vector 2019-02-20 16:49:02 +00:00
duncanspumpkin
8a69b89df6 Move Staff Set Orders into game action framework.
Split up costume and order game commands
2019-02-05 20:38:18 +00:00
Tom Lankhorst
01a52d236c Use vector<string> in InteractiveConsole
Issue #8597 shows Valgrind result indicating a memory leak in
InteractiveConsole. This is fixed in #8619 by ensuring that free() is
called appropriately.
This commit takes that a step further by removing all manual memory
management in favour of using vector<string>.

- argc is now gone in favour of argv.empty()/argv.size()
- argv_t is a vector of strings of utf8's
- console_command_func's signature is changed accordingly
2019-01-24 16:12:49 +01:00
Tom Lankhorst
55af6ad0e1 Free allocated memory when 'argc' == 0 (#8619)
Fixes leak in #8597, InteractiveConsole allocates memory for arguments,
but frees it only if the argument count is greater than zero.
2019-01-21 23:03:12 +00:00
Ted John
92412d4bab Store ride index inside ride struct 2019-01-18 11:46:18 +01:00
Matt
6aee1cba28 Remove deprecated function std::asctime. 2019-01-02 05:35:57 +01:00
Matt
1f20fdf65b Log more replay information to console. 2019-01-02 05:20:10 +01:00
Matt
c7ab757a86 Cleanup. 2018-12-29 23:06:15 +01:00
Matt
df0cc72887 Add normalisation support to remove gaps. 2018-12-29 19:23:27 +01:00
Matt
a6efef1e81 Add support to record and replay game commands/actions. 2018-12-29 19:23:27 +01:00
ζeh Matt
7d19a5bc77 Refactor memcpy to std::memcpy and memset to std::memset (#8408) 2018-12-15 22:23:31 +01:00
Michał Janiszewski
a78e812a64 Add dereference command to aid testing breakpad 2018-11-29 21:40:59 +01:00
TELK
4cc2057b94 Add 'say' command in console (#8259)
* Add 'say' command in console

* Unifying space just before }
2018-11-18 20:38:55 +01:00
Michał Janiszewski
af91a0ef61 Add abort and terminate to console
Often when testing things out there's a need to have a way of inducing a
crash. Rather than trying to figure out what might be the bug that would
cause such conditions on given version, compiler and OS, provide a
simple way to call std::abort() and std::terminate() via the in-game
console.

Additionally, sort the commands.
2018-11-17 00:26:27 +01:00
Hielke Morsink
107faaf821 Add and use game action for setting the climate
Also reordered the registered game actions the same as headers, so they are easier to find.
2018-11-08 22:39:13 +01:00
Michael Steenbeek
f8add7f62e Rename rct_tile_element to TileElement 2018-11-01 13:53:50 +01:00
Michał Janiszewski
a0c9e1b6c7 Update format string for size_t MAX_BANNERS 2018-10-31 12:51:06 +01:00
tombomp
18307e3841 Add a "current_rotation" variable to the console (#8080)
This is a value from 0-3 showing current rotation of main window, 3
being the default and lower going counter clockwise. Possible to set as
well.
2018-10-14 23:44:45 +02:00
Robert Lewicki
694608624d Add save_park command (#8078)
Added save_park command that enable to save current state of the game
using command line.
2018-10-14 22:36:41 +02:00
Gymnasiast
d1b576b4a5 Fix bugs in park fences 2018-09-16 21:53:12 +02:00
Michael Steenbeek
74ccf010e6 Port surface elements to new structure 2018-09-16 21:34:51 +02:00
Linus Unnebäck
fd07be587a Remove Math::Clamp in favour of std::clamp 2018-08-12 16:47:12 +01:00
clang-format
d787872cbe Indent preprocessor directives 2018-07-23 16:00:23 +02:00
clang-format
b02dfdbc93 Binpack function arguments together
Previously when the arguments of a function wouldn't fit on a single line, clang-format would put each argument on its own line instead. By enabling the binpack parameter setting, it tried to fit as many on one line as possible instead.

Co-authored-by: Hielke Morsink <hielke.morsink@gmail.com>
2018-07-23 16:00:22 +02:00
clang-format
95ce592579 Enforce not breaking before assignments and function names
Co-authored-by: Hielke Morsink <hielke.morsink@gmail.com>
2018-07-23 16:00:19 +02:00
Hielke Morsink
472320d8f3 Correct formatting up to the management folder
I went over the commits ab7f22f..8726712 (bulk format commits for game actions to management inclusive) and corrected all mistakes I found. Most of them have to do with arrays missing trailing commas, making clang-format indent the entire array or not add breaks between the values.
2018-07-23 16:00:15 +02:00
clang-format
17d2693422 clang-format interface 2018-07-23 16:00:04 +02:00
Michael Steenbeek
1b08fb4e69 Replace our own integer types with standard ones 2018-06-20 17:30:40 +02:00
Hielke Morsink
0cf256ac9e Ready copyright notice for clang-format
Clang-format sees the text behind `#pragma region` as code and formats it. Instead of stating the copyright and date there, it's now in the comment block right below it. The text "Copyright" is left in the `#pragma region` line, as clang-format sees it as a single identifier.

I took the opportunity to normalize the dates, and add the copyright notice to the source files where it was missing them (except for third-party and the generated resources.h file).
2018-06-15 14:07:34 +02:00
Hielke Morsink
aad1e69d7e Add parentheses to macro arguments (#7686)
This adds parentheses around macro arguments that are either negative or used for calculations inside the macro itself. Doing this avoids getting errors in code that may look right.
2018-06-15 10:54:05 +02:00
Ted John
9a94139242 Fix Linux builds 2018-06-12 21:18:13 +01:00
Ted John
e38f4df575 [wip] Move themes to libopenrct2ui 2018-06-10 23:34:12 +01:00
Hielke Morsink
204dd4439b Mark unused arguments in the libopenrct2 project
For dummy classes and functions with empty bodies I've only commented out the arguments, for all others I used C++17's [[maybe_unused]].
2018-06-06 21:03:11 +02:00
Hielke Morsink
9c8c2a2820 Missing field initializers part 2
This commit tackles the more difficult-to-fix warnings that -Wmissing-field-initializers reported. I've compares the new tables in TrackData with the old ones through a script to make sure they are in fact the same.
2018-06-05 00:18:07 +02:00
Hielke Morsink
5d0022a5cb Remove argument list from zero-initializers with zero/false/nullptr value 2018-06-04 19:50:46 +02:00
Ted John
92f6ac7333 Rename header files to match renamed source files 2018-06-01 09:38:30 +02:00
Ted John
b3c17b215f Use single output folder for msbuild obj files
This requires unique named source files within a project.
2018-06-01 09:37:49 +02:00