1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-20 13:33:02 +01:00
Commit Graph

69 Commits

Author SHA1 Message Date
IntelOrca
40fcfbb405 use localised strings for native file dialogs 2016-03-31 20:41:49 +01:00
IntelOrca
d865e4d453 pass better data in struct to file dialog function 2016-03-31 20:41:47 +01:00
Michał Janiszewski
6b514d1e3a Fix possible issues highlighted at higher warn levels
Mostly possibly uninitialized values and signedness
2016-02-26 12:54:00 +01:00
IntelOrca
c31941c6dc fix #2958: import sc4, sv4 into editor using load landscape dialog 2016-02-16 18:15:26 +00:00
anyc
ffafd07c90 use enum to specify file dialog type 2016-01-29 19:03:09 +01:00
IntelOrca
162710d86a remove strange random game command call from loadsave 2016-01-19 18:04:15 +00:00
Michał Janiszewski
3bf1e0e06d Rename safe_strncpy to safe_strcpy 2016-01-18 20:49:52 +01:00
IntelOrca
3073bc64fd remove rct2_endupdate 2016-01-09 00:25:30 +00:00
Hielke Morsink
3641634aad Prevent extension from showing when saving a park for the first time. 2016-01-05 00:23:51 +01:00
IntelOrca
9b833e5f93 shorten path for scenario select debug 2016-01-02 23:14:41 +00:00
IntelOrca
950722292c use user path for default scenario save location 2016-01-02 21:05:31 +00:00
Hielke Morsink
eadb03426e fix #2620 and preventing names with dots from breaking. 2016-01-02 14:59:16 +01:00
Michał Janiszewski
8a5d066efe Fix strict aliasing violations
Compiler only guarantees proper accesses to variables when using
variable's native type or `char` (i.e. single byte type) [1].

This commit fixes violations of this rule. In most cases changing code
to a simple cast was enough, some required a bit deeper modifications.

This fixes #2596.

[1] http://blog.qt.io/blog/2011/06/10/type-punning-and-strict-aliasing/
2015-12-31 13:27:26 +01:00
Ted John
69f0e9d55d Merge pull request #2398 from Broxzier/comments_and_optimizations
Refactored some util functions and some minor tweaks for saving tracks
2015-12-29 11:31:58 +00:00
Gymnasiast
f87bdb0eda Sort load/save window on open, fixes #2477 2015-12-27 10:28:10 +01:00
Hielke Morsink
90e67772e0 Resolved warnings, and removed duplicated function. 2015-12-01 12:03:34 +01:00
Hielke Morsink
666da74beb Changed missleading variable name from 'filename' to 'path'. 2015-11-29 19:59:15 +01:00
Hielke Morsink
5b1d93805d More consistent use between name and paths. Improved path_get_* functions. 2015-11-29 19:41:06 +01:00
osconnoisseur
b5c04a79e5 Added buttons for "up" and "new file" and fixed #2233 2015-11-11 21:51:21 -06:00
IntelOrca
7f541240e2 fix #2279, make game remember save path rather than filename 2015-11-11 21:37:26 +00:00
Ted John
c70880c0a5 Merge pull request #2251 from Broxzier/fix_filename
Fixed filenames being cut off when there's a dot in them
2015-11-08 19:04:45 +00:00
IntelOrca
48e3d70e57 refactor colour maps 2015-11-08 18:55:32 +00:00
Hielke Morsink
b929a27595 Fixed filenames with dots not being displayed completely. 2015-11-08 18:21:55 +01:00
duncanspumpkin
13e2f8e9ed Fix #2210. Reverts from a0909a2 that cause the up button to load the same directory 2015-11-06 18:02:27 +00:00
IntelOrca
a0909a242d fix several safe_strncpy calls 2015-11-02 21:23:01 +00:00
IntelOrca
45bfdad4e3 fix #1144 2015-11-02 20:43:55 +00:00
Michał Janiszewski
9284930d7e Add safe_strncpy function
safe_strncpy is similar to strncpy, but makes sure buffer is
null-terminated. Update most of project to use this updated function to
prevent illegal memory accesses.
2015-10-30 16:01:00 +01:00
Alexander Overvoorde
01793e11b7 Replace RCT2_GLOBAL magic numbers with address identifiers and string ids 2015-10-29 09:44:46 +01:00
Michał Janiszewski
fcd22dd8ca Memory handling fixes 2015-10-25 01:15:52 +02:00
Michał Janiszewski
79552feb54 Only copy strings when they're different
When called from window_loadsave_scrollmousedown,
window_loadsave_populate_list will try to strncpy a string over itself.
This commit prevents that.
2015-10-23 17:22:31 +02:00
Michał Janiszewski
7d0ce00bab Strip all whitespace 2015-10-20 20:48:51 +02:00
duncanspumpkin
ee1e71f287 Fix loadlandscape breaking enabled tabs
Issue was caused by not calling sub_6DFED0 when loading the landscape. I assume in vanilla this would happen as part of the loading but due to the way loadsave now works it doesn't happen. In the process I also labelled the offset for editor step.
2015-10-15 22:16:27 +01:00
Michał Janiszewski
52252f82b3 assorted fixes 2015-09-07 20:51:21 +02:00
IntelOrca
8c44ddac17 fix 2nd problem of #1848 2015-09-05 20:06:58 +01:00
IntelOrca
bea74ee261 make all file IO utf8 compatible, fixes #1847 2015-08-29 13:13:23 +01:00
Runelaenen
d34a446d61 Easier saving
Replace Save game functionality and add 'save game as' function
2015-08-19 22:02:06 +02:00
IntelOrca
90bf4c6836 fix #1797 2015-08-16 18:42:30 +01:00
IntelOrca
4f8e289e79 finish server list and fix a couple of multiplayer issues 2015-08-16 17:29:47 +01:00
IntelOrca
094cc19411 allow joining of servers in server list window 2015-08-16 16:37:08 +01:00
Michał Janiszewski
7afb7e2dfd Portability fixes 2015-08-04 19:31:21 +02:00
IntelOrca
7fe54661b9 implement utf8, part 21 (more font specific customisation and bug fixes) 2015-08-01 10:21:01 +01:00
Duncan Frost
b94d77ccae Fix issue where saving would close toolbar.
Fixes 1537. Issue was caused by the window order being changed further down a function call. This meant all pointers to windows were invalid.
2015-07-20 20:49:56 +01:00
zsilencer
b876591543 use SDL_RWops for save games 2015-07-11 12:27:46 +01:00
IntelOrca
f906391c9d remove registers from window events and changed to typed signatures 2015-07-10 01:39:16 +01:00
Robert Jordan
a3a993dabd Title Sequence editor 2015-06-24 12:25:54 -04:00
Gymnasiast
a6225ebf06 Add option to select by track type (RCT1 style); correct misspellings of 'separate' 2015-06-24 12:41:19 +02:00
Thomas
2fc23b0084 Add browsing drives on windows 2015-06-22 15:55:57 +02:00
Thomas
21ecd52af1 Fix for travis 2015-06-22 14:17:45 +02:00
Thomas
c7781e272c Make sorting case insensitive 2015-06-22 13:54:09 +02:00
Thomas
ce26812caa Add sorting based on date 2015-06-22 13:49:35 +02:00