1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-08-30 01:49:10 +00:00

Compare commits

..

144 Commits

Author SHA1 Message Date
rubidium
87f89ddf7c (svn r11613) -Release: 0.6.0-beta2.
The second beta with quite a lot of bugfixes since beta1 and a few smaller features.
2007-12-09 21:37:46 +00:00
rubidium
f854b129af (svn r11612) -Change: update some documentation. 2007-12-09 21:23:20 +00:00
glx
6a83f9141b (svn r11611) -Codechange: it is now possible to use a define to enable asserts and show them in crash.log for MSVC release builds 2007-12-09 21:20:21 +00:00
glx
46c0edc80b (svn r11610) -Cleanup (r8572): remove orphan comment 2007-12-09 20:20:52 +00:00
rubidium
6aaa72c918 (svn r11609) -Fix [FS#1524]: wrong error messages were shown when trying to build some industries in the scenario editor. 2007-12-09 18:51:25 +00:00
rubidium
c3ea7e4dc4 (svn r11608) -Fix: do not trigger industries, but only the industry's tiles. 2007-12-09 18:27:40 +00:00
skidd13
f20e414e2e (svn r11607) -Codechange: Enumify the industry widgets
-Feature: Enable doubleclick in the found new industries window to build an industries
2007-12-09 17:07:50 +00:00
rubidium
079c0fd66a (svn r11606) -Revert (r11584): since FS#1482 is solved, we do not need the extra checking and such anymore. 2007-12-09 15:17:49 +00:00
rubidium
5dc0e86d1b (svn r11605) -Fix [FS#1482, FS#1523]: wrong count of Kirby trains when a ship was build. 2007-12-09 15:15:26 +00:00
smatz
5cd0013e5c (svn r11604) -Fix: canal tiles were not marked dirty when surrounding tile got flooded, causing glitches 2007-12-08 21:57:24 +00:00
smatz
dfba33819b (svn r11603) -Fix [FS#1481]: make price for railtype conversion more realistic 2007-12-08 19:53:30 +00:00
bjarni
58b4a981e1 (svn r11602) -Change: [OSX] changed default PPC SDK to 10.4 (from 10.3) when building universal binaries
10.5 support needs this and it will not break 10.3 support
2007-12-08 18:53:49 +00:00
smatz
2a62aa1ccd (svn r11601) -Codechange: more strict break conditions for _userstring, assert when it overflows anyway (eg. code change without proper check change) 2007-12-08 18:50:39 +00:00
glx
b47bce651e (svn r11600) -Cleanup: remove extra out-of-memory checks, since it's now done in *allocT functions. 2007-12-08 15:47:23 +00:00
bjarni
2256d9d378 (svn r11599) -Change: [OSX] 10.4 will now use quickdraw for window mode instead of quartz
The reason is that quickdraw is way faster (try fast forward)
  10.5 will still use quartz as it can't handle quickdraw.
2007-12-08 15:21:37 +00:00
rubidium
625a4f8e9a (svn r11598) -Change [FS#1518]: some tooltips of the main toolbar did not 'enumerate' all options in a drop down menu. 2007-12-08 14:54:43 +00:00
rubidium
f1e4914b5f (svn r11597) -Change: replace all remaining instances of (re|m|c)alloc with (Re|M|C)allocT and add a check for out-of-memory situations to the *allocT functions. 2007-12-08 14:50:41 +00:00
belugas
73c58d8a40 (svn r11596) -Codechange: Use the Window member HandleButtonClick and remove its now useless counterpart function 2007-12-08 03:10:50 +00:00
belugas
b23f824f18 (svn r11595) -Codechange: add a new member to Window struct, based on its function counterpart HandleButtonClick. 2007-12-08 02:55:47 +00:00
glx
04f0700357 (svn r11594) -Fix: don't allow changing network only patches settings from console when not in network game 2007-12-08 01:36:40 +00:00
belugas
af4d07b978 (svn r11593) -Cleanup: remove some forgotten pieces of evidence of a mischief 2007-12-08 01:30:18 +00:00
belugas
8c89641dbe (svn r11592) -Codechange: Use the Window member RaiseButtons and remove the now useless RaiseWindowButtons function 2007-12-08 01:20:47 +00:00
belugas
6fb71047d6 (svn r11591) -Codechange: remove now unused widget accessors. 2007-12-08 01:02:19 +00:00
glx
8aaa4e7da6 (svn r11590) -Fix (r11193): IsSlopeRefused() result was half wrong 2007-12-07 21:16:38 +00:00
rubidium
cbb2d39860 (svn r11589) -Fix [FS#1514]: when ship depots got destroyed they always returned to water, even when it should've been canals. 2007-12-07 21:14:54 +00:00
glx
c21f588a14 (svn r11588) -Codechange: use the new member introduced in r11551 2007-12-07 18:05:49 +00:00
skidd13
98bd772119 (svn r11587) -Fix (r11457): The one way road button wasn't reset on abort 2007-12-07 17:51:27 +00:00
glx
10e17c30a3 (svn r11586) -Fix: make another widget 'accessor' function const when it should be const. 2007-12-07 17:42:15 +00:00
skidd13
7159007a35 (svn r11585) -Codechange: Enumify the widgets of the newGRF gui and a slight cleanup there 2007-12-07 12:22:34 +00:00
rubidium
42dbdbb7f9 (svn r11584) -Change: add some extra checking in the hope to find the cause of FS#1482. 2007-12-06 22:29:47 +00:00
rubidium
dd68a34e26 (svn r11583) -Fix [FS#1484]: windows could get completely missing when one resized the window to something very small. 2007-12-06 20:55:48 +00:00
smatz
720854ed16 (svn r11582) -Fix: tiles were not marked dirty in some cases when removing a lock 2007-12-06 20:48:15 +00:00
rubidium
3d38b2c8ba (svn r11581) -Codechange: add some missing cargo classes and some documentation. 2007-12-06 20:36:46 +00:00
skidd13
2c3c6593d4 (svn r11580) -Feature: Memorise the resizing of the build bridge selection window during runtime 2007-12-06 18:29:31 +00:00
belugas
6c70cf2d82 (svn r11579) -Revert(r11578): some cases of key propagation are not handled correctly.
A better solution will be deviced, but not now.  Let's not cause a ton of bug reports
2007-12-06 15:58:39 +00:00
belugas
7edf28529d (svn r11578) -Codechange: Introduce the window default flag WDF_TEXTENTRY which specifies that the window holding it is actually one that enables an edit box.
Use this flag when dispatching a key event instead of using some hard coded window IDs.
This should ease a little bit the creation of new edit aware windows.
2007-12-06 02:31:47 +00:00
smatz
49d632c31b (svn r11577) -Fix: invalidate 'list trains/roadvehs/ships/planes' widgets when station part is added/removed 2007-12-05 19:13:42 +00:00
smatz
eda5921284 (svn r11576) -Codechange: enumerize and comment station GUI 2007-12-05 17:08:10 +00:00
smatz
079482f0a2 (svn r11575) -Fix [FS#1502]: widget numbers of StationViewWindow were incorrect at some places 2007-12-05 16:55:33 +00:00
smatz
c65c14f06b (svn r11574) -Fix: flood train stations when there are no trains on border tiles too (when non-uniform stations are OFF) 2007-12-05 00:16:20 +00:00
rubidium
8c5c0e9367 (svn r11573) -Codechange: pause games that miss GRFs by default and throw some warnings and disclaimers when you want to unpause it. 2007-12-04 22:50:07 +00:00
glx
46441ac31c (svn r11572) -Fix [FS#1494]: reinitialise windows system before loading a savegame 2007-12-04 22:22:50 +00:00
rubidium
02c46026b3 (svn r11571) -Fix [FS#1493]: road vehicle getting to the wrong side of a station when trying to overtake in there. 2007-12-04 21:53:09 +00:00
smatz
ddc8f2d16f (svn r11570) -Fix: do not flood rail station tiles when there is a vehicle on it (when non-uniform stations are ON) 2007-12-04 21:39:03 +00:00
rubidium
5f576e12aa (svn r11569) -Fix [FS#1480]: full paths sometimes did not work correctly. 2007-12-04 18:42:08 +00:00
belugas
5847abc9f8 (svn r11568) -Codechange: Use bit shifts instead of values for flags. It helps readability a little bit. 2007-12-04 17:51:50 +00:00
glx
0f43982c72 (svn r11567) -Fix [FS#1512] (r11011): break the chain before moving a vehicle after another in the same chain 2007-12-04 15:32:54 +00:00
smatz
05fca79cf0 (svn r11565) -Revert: part of r11564 2007-12-03 22:40:18 +00:00
skidd13
82913a2134 (svn r11564) -Codechange: Increase the usage of the for_each_bit macro and rename it fitting to the naming style 2007-12-03 09:19:19 +00:00
skidd13
1a43c6a6f6 (svn r11563) -Codechange: Align the preprocessor code in stdafx.h with tabs 2007-12-02 21:43:16 +00:00
rubidium
fe76841255 (svn r11562) -Fix [FS#1503] (r11546): aircraft sometimes stopped mid-air when the airport got destroyed. 2007-12-02 21:35:44 +00:00
glx
164d0a4710 (svn r11561) -Fix [FS#1504] (r11463): group list was not updated when removing the last group 2007-12-02 20:13:12 +00:00
rubidium
b7d8681129 (svn r11560) -Codechange: replace 'custom' version of FindLastBit with the generic. 2007-12-02 19:23:46 +00:00
rubidium
faf096f506 (svn r11559) -Fix [FS#1505]: overflow when drawing graphics with high company values. 2007-12-02 19:21:56 +00:00
rubidium
b5a902703e (svn r11557) -Codechange: send and store the passwords a little more secure to/in the servers.
Each server and game yield a (usually) different 'salt'. This salt is used by the clients to hash their passwords. This way the passwords are not sent in clear text and it is not trivial to use those hashes on other servers.
NOTE: It is still NOT safe to use your trusted passwords and it will not stop people from being able to 'hijack' your password, it only makes it harder to do and certainly much less trivial than just dumping passwords from the memory.
2007-12-02 15:12:19 +00:00
rubidium
d9081ad3f5 (svn r11556) -Feature: allow setting a default password for new companies in network games. 2007-12-02 14:48:26 +00:00
rubidium
527b72749d (svn r11555) -Codechange: use the new members introduced in r11551. 2007-12-02 14:29:48 +00:00
rubidium
50fced3c66 (svn r11554) -Codechange: be more consistent with the naming of the widget functions. 2007-12-02 13:32:41 +00:00
rubidium
b20b2f4ec8 (svn r11553) -Fix: make a few widget 'accessor' function const when they should be const. 2007-12-02 12:10:48 +00:00
miham
4e574cab45 (svn r11552) -Update: WebTranslator2 update to 2007-12-02 12:31:46
czech      - 1 fixed by Hadez (1)
french     - 15 fixed by glx (15)
galician   - 2 fixed by Condex (2)
italian    - 15 fixed by lorenzodv (15)
norwegian_bokmal - 6 fixed by jhsoby (6)
russian    - 7 fixed by Smoky555 (7)
slovenian  - 1 fixed by Necrolyte (1)
spanish    - 1 fixed by eusebio (1)
2007-12-02 11:32:24 +00:00
belugas
e2b4afaa4b (svn r11551) -Codechange: Introduction of widget control members on struct Window. These "new" members have the exact same functionalities as their pure functions "genitors"
Ex: "Window::SetWidgetLoweredState(byte widget_index, bool lowered_stat)"  is the member corresponding to "SetWindowWidgetLoweredState(Window *w, byte widget_index, bool lowered_stat)"
2007-12-02 00:59:48 +00:00
skidd13
7be55559b8 (svn r11550) -Fix (r11547): Updated the data files regarding to r11549 2007-12-02 00:53:01 +00:00
rubidium
08ab4e1850 (svn r11547) -Add: signal selection GUI for the ones that really like to use that over CTRL. Patch by BigBB. 2007-12-01 21:40:18 +00:00
belugas
0feaee4124 (svn r11546) -Fix[FS#1496]: If ever the air/heli port is suddenly not available while the "chopper" is descending, just go back into flying.
The code should have been better written, but in respect of newgrf_port branch, i prefer minimalist intervention
2007-12-01 14:04:16 +00:00
belugas
4f030bbfff (svn r11545) -Revert(r11543): The result is not what was expected. Looks like more work might be needed 2007-12-01 02:59:22 +00:00
glx
da9f06252b (svn r11544) -Fix [FS#1501]: revert r11453 as it translated cargo when it should not 2007-12-01 02:47:10 +00:00
belugas
aa0d37854d (svn r11543) -Codechange: Give a more adequate message when trying to place an industry required to be built over a house on any other type of tiles.
In reference to FS#1492, and other "bugs" like that one
2007-12-01 01:31:05 +00:00
bjarni
6b68c6557b (svn r11542) -Fix r11540: [OSX] presumed 10.3 style strings when using GetCurrentLocale nomatter what OSX the target was 2007-11-30 14:49:13 +00:00
bjarni
7162b8ddb3 (svn r11541) -Fix: [OSX] detect statvfs at runtime (based on OSX version) instead of compile time
This should prevent a crash on OSX 10.3 with the precompiled binaries (in the load/save windows)
2007-11-30 14:42:16 +00:00
bjarni
5fcbb8f59b (svn r11540) -Fix: [OSX] Don't try to compile the quartz video driver on OSX 10.3. It will fail 2007-11-30 13:26:24 +00:00
skidd13
4704d4619b (svn r11539) -Feature: Make the bridge selection window resizable 2007-11-29 18:27:39 +00:00
skidd13
6e511188ae (svn r11538) -Codechange: Rewrite GetNthSetBit in a more uncontroversial way and add its documentation 2007-11-28 21:59:06 +00:00
rubidium
981865dbcc (svn r11537) -Codechange: make it much harder to 'accidentally' add savegame conversion code after the window and cache initializations. 2007-11-28 15:42:52 +00:00
belugas
440608a6f0 (svn r11536) -Codechange: Align some elements of the _tree_layout_sprite table a little better looking for the eye 2007-11-28 00:41:20 +00:00
miham
34edc93f2a (svn r11535) -Update: WebTranslator2 update to 2007-11-27 20:21:42
ukrainian  - 1 fixed by mad (1)
2007-11-27 19:22:08 +00:00
belugas
b10eea628d (svn r11534) -Feature(newgrf): Implement property 23h for Industries.
This will add a cost to the removal of an industry using the cheat magic bulldozer.
Note that the removal of regular or newgrf industries without specified removal cost will have no cost applied to.
This is a difference from original spec, where a default base cost is added.
2007-11-27 17:13:49 +00:00
belugas
1682d5d679 (svn r11533) -Codechange: Rename some unclear clear_x prices member names.
While at it, remove one unused entry on the clear_price_table array.
It is based on ground type, and the unused one was referencing a non existing one.
2007-11-27 16:02:13 +00:00
belugas
9402d4054a (svn r11532) -Feature[newgrf]: Add decrement(0x0D) / increment(0x0E) production operations from result of production callback cb29/35.
Only var 0x93 will be affected by these operations
2007-11-27 04:16:08 +00:00
rubidium
8c5814156f (svn r11531) -Fix [FS#1459]: version determination did stall (read: never finish) when both svn and git were not installed. 2007-11-26 23:28:29 +00:00
smatz
6f7d37d3d3 (svn r11530) -Codechange: do not update Tpool->first_free_index for PoolItems allocated on stack 2007-11-26 22:56:30 +00:00
miham
a7d4334664 (svn r11529) -Update: WebTranslator2 update to 2007-11-26 21:13:37
brazilian_portuguese - 1 fixed by fukumori (1)
catalan    - 1 fixed, 2 changed by arnaullv (3)
dutch      - 1 fixed by habell (1)
french     - 1 fixed, 1 changed by glx (2)
italian    - 1 fixed by lorenzodv (1)
lithuanian - 4 fixed by Domas (4)
slovak     - 1 fixed, 1 changed by lengyel (2)
ukrainian  - 5 fixed by mad (5)
2007-11-26 20:14:20 +00:00
maedhros
8e273e0f88 (svn r11528) -Fix (r11500): With smooth economy enabled, industries that should only decrease production would always increase it when more than 60% was transported. 2007-11-26 19:23:53 +00:00
skidd13
71c10f7df7 (svn r11527) -Codechange: Split the bitmath functions of to their own files 2007-11-26 17:50:22 +00:00
skidd13
734b22e070 (svn r11526) -Codechange: Rename the function delta fitting to the naming style 2007-11-26 16:01:29 +00:00
rubidium
d736a04b59 (svn r11525) -Fix: do not do all kinds of 'updates' for town, waypoint, station and other signs when you haven't converted the map to the 'current' format as that means you are going to read data in the 'old' format when you assume that it is in the 'current' format. 2007-11-25 20:20:16 +00:00
rubidium
77b6a2674e (svn r11524) -Fix [FS#1485]: assertion when tram reversed at a station. 2007-11-25 19:45:09 +00:00
skidd13
bdc7fd2d76 (svn r11523) -Codechange: Move the CHANCE macros to core/random_func.cpp cause they depend on Random()
-Codechange: Convert the CHANCE macros to functions and rename them fitting to the naming style
2007-11-25 15:35:25 +00:00
skidd13
2bf2be987d (svn r11522) -Fix: The scrollbar of the network gui could run out of bounds 2007-11-25 15:17:16 +00:00
egladil
1d5010edf9 (svn r11521) -Codechange: [OSX] Check what the running os version is in a cleaner way. 2007-11-25 14:43:16 +00:00
egladil
9aaa455e5d (svn r11520) -Fix: [OSX] The cocoa video driver let the mouse cursor escape the window when using rmb scrolling. Thanks ln- for pointing this out and providing a fix. 2007-11-25 12:58:32 +00:00
smatz
d061d985d6 (svn r11519) -Codechange: enumerization and cleanup of NetworkLobbyWindow in network_gui.cpp 2007-11-25 11:36:45 +00:00
smatz
2cd25ed2ca (svn r11518) -Codechange: enforce (by assert) unused parameters of widgets to be zero. Better readability of DrawWindowWidgets(), too 2007-11-25 00:41:31 +00:00
smatz
72eb6ae278 (svn r11517) -Codechange: better cleanup of NetworkStartServerWindow in network_gui.cpp 2007-11-24 21:49:49 +00:00
smatz
a62e07b08e (svn r11516) -Codechange: cleanup of NetworkGameWindow in network_gui.cpp 2007-11-24 21:41:59 +00:00
smatz
5dfead8b5c (svn r11515) -Codechange: cleanup of NetworkStartServerWindow in network_gui.cpp 2007-11-24 18:09:02 +00:00
rubidium
bd8bf99139 (svn r11514) -Change: implement the automatic multiplier handler for NewGRF industries. 2007-11-24 14:03:47 +00:00
smatz
cbd1c05218 (svn r11513) -Codechange: enumerize some depot GUI actions 2007-11-24 13:50:29 +00:00
rubidium
6cf5e4cf05 (svn r11512) -Change: make the subsidy window able to resize to something smaller than 640x127 (especially the 640 part) when the screen is really too small. 2007-11-24 13:00:32 +00:00
rubidium
f27acfdf78 (svn r11511) -Revert parts of r11505: forgot that CTRL might be used for other features, like adjacent stations or signals. 2007-11-24 12:36:52 +00:00
skidd13
bf959f926f (svn r11510) -Codechange: merge the IS_*INSIDE* functions and rename them fitting to the naming style 2007-11-24 10:38:43 +00:00
rubidium
64246a2775 (svn r11509) -Fix: off-by-one error in some sprite numbers; increase sprite number counter before loading the next sprite instead of after doing so. 2007-11-24 10:19:56 +00:00
egladil
fcbfba1e17 (svn r11508) -Cleanup: Removed unused headers from the cocoa video driver. 2007-11-24 09:55:17 +00:00
rubidium
221e9271c5 (svn r11507) -Fix [FS#1463]: signs totally illegible when transparant signs is turned on and zoomed out more than one level. 2007-11-24 09:27:20 +00:00
rubidium
9a70ec1cb2 (svn r11506) -Fix [FS#1471]: selling vehicles could cause the window of others to scroll to that location. 2007-11-24 09:14:58 +00:00
rubidium
81c7ba42af (svn r11505) -Fix/Feature: make CTRL work on all road/rail construction options that 'work' with the 'Bulldozer' button instead of only a few. 2007-11-24 08:56:29 +00:00
rubidium
ea072322fa (svn r11504) -Fix [FS#1467]: removing docks/ship depots could result in non-canal water where canals should have been build. 2007-11-24 08:45:04 +00:00
glx
c8add52504 (svn r11502) -Fix (r11144): don't do standard production change if callbacks 29/35 failed
-Fix (r11144): disable smooth economy for industries using callbacks 29/35
2007-11-23 16:50:54 +00:00
egladil
2e0dd78ccf (svn r11501) -Fix: [OSX] This remedies a problem with right click scrolling that was introduced in r11492. 2007-11-23 13:45:59 +00:00
belugas
536be43411 (svn r11500) -Codechange: Smooth economy fine-tuning, making industries more responsive. Patch by Sirkoz. 2007-11-23 12:12:07 +00:00
glx
ee81e00082 (svn r11499) -Fix (r11144): mul/div factor were wrong (off by two) 2007-11-23 04:17:41 +00:00
egladil
2ebf50e421 (svn r11498) -Add [FS#1411]: [OSX] Added support for using Quartz instead of Quickdraw in windowed mode on OS X 10.4 and higher. Based on a patch by blackis. 2007-11-23 02:44:05 +00:00
rubidium
9d3cc5b271 (svn r11495) -Fix (r11493): some compilers fail to show warnings when they should. 2007-11-22 22:54:49 +00:00
glx
b979995795 (svn r11494) -Fix [FS#1461] (r11450): cargo translation table was now loaded too late ;) 2007-11-22 22:37:06 +00:00
rubidium
64a4ac3444 (svn r11493) -Fix [FS#1472]: game crashing on savegame load because it tried to render some part of the window before the savegame conversion was done. 2007-11-22 22:34:30 +00:00
egladil
3ad488e98f (svn r11492) -Codechange: [OSX] Split the cocoa video driver into several files. The reason for this is that the fullscreen and windowed mode api are separate from each other in OS X and thus the driver actual is two drivers in one. This split is to make the code more readable and to prepare for replacing the Quickdraw windowed mode code which uses apis deprecated as of OS X 10.5 (and maybe earlier). 2007-11-22 21:48:17 +00:00
miham
2653d94bcb (svn r11491) -Update: WebTranslator2 update to 2007-11-22 20:55:02
brazilian_portuguese - 5 fixed by tucalipe (5)
catalan    - 5 fixed by arnaullv (5)
czech      - 5 fixed by Hadez (5)
danish     - 6 fixed, 3 changed by MiR (9)
dutch      - 5 fixed by habell (5)
french     - 5 fixed by glx (5)
italian    - 2 fixed by lorenzodv (2)
japanese   - 5 fixed by ickoonite (5)
korean     - 58 fixed by leejaeuk5 (58)
slovak     - 5 fixed, 86 changed by lengyel (91)
slovenian  - 5 fixed by Necrolyte (5)
spanish    - 5 fixed by eusebio (5)
swedish    - 5 fixed by daishan (5)
turkish    - 5 fixed by jnmbk (5)
2007-11-22 19:55:54 +00:00
skidd13
737aec4db6 (svn r11490) -Codechange: Split the math functions to their own header
-Codechange: Replace the rest of the math macros with functions
2007-11-22 18:01:51 +00:00
skidd13
1d56af1d33 (svn r11489) -Fix r11488: Somehow the code was added multiple times 2007-11-21 19:18:34 +00:00
skidd13
83601671c7 (svn r11488) -Codechange: Spilt the random functions out to seperate file
-Codechange: Make the mersenne twister more readable
-Codechange: Unify the seeding process of random
2007-11-21 19:13:38 +00:00
smatz
d53bfd8f2f (svn r11487) -Fix (r11435): move the list of vehicles a bit higher in the player GUI 2007-11-21 13:50:36 +00:00
glx
b168ae34be (svn r11486) -Fix [FS#1457]: industry count was wrong in smallmap 2007-11-21 13:46:29 +00:00
skidd13
a91c2a4c39 (svn r11485) -Codechange: Remove the doubled function ToggleBitT and rename the remaining to fit with the naming style 2007-11-20 14:11:19 +00:00
skidd13
eeaa348f8b (svn r11484) -Codechange: Remove the doubled function SetBitT and rename the remaining to fit with the naming style 2007-11-20 13:35:54 +00:00
skidd13
b8885630aa (svn r11483) -Codechange: Replace codeparts with functions that do the same to increase readability 2007-11-20 12:57:24 +00:00
skidd13
5c31a973a1 (svn r11482) -Codechange: Remove the doubled function ClrBitT and rename the remaining to fit with the naming style 2007-11-19 21:32:20 +00:00
skidd13
71c4325c50 (svn r11481) -Codechange: Rename the HASBIT function to fit with the naming style 2007-11-19 21:02:30 +00:00
skidd13
58bb5c7525 (svn r11480) -Codechange: Rename the function ALIGN fitting to the naming style
This fixes also FS#1450
2007-11-19 20:40:14 +00:00
skidd13
d076ea8697 (svn r11479) -Codechange: Move the BIGMUL functions to the file of their usage
-Codechange: Rename the BIGMUL functions to the fitting naming style
2007-11-19 20:18:27 +00:00
rubidium
e815dae3c6 (svn r11478) -Fix: two small layout issues with the vehicle grouping GUI. 2007-11-19 19:54:23 +00:00
rubidium
a4df4728fc (svn r11477) -Fix [FS#1451]: a road vehicle must not show that it is driving max speed when it is standing still waiting for the vehicle in from of it. 2007-11-19 18:58:32 +00:00
skidd13
50bfe1a19d (svn r11476) -Codechange: rename the function myabs to abs to get rid of an unneeded define 2007-11-19 18:58:04 +00:00
skidd13
8be526e499 (svn r11475) -Codechange: rename clamp and clampu to Clamp and ClampU to fit with the coding style 2007-11-19 18:38:10 +00:00
belugas
006acff183 (svn r11474) -Feature: Allow to resize on creation the smallmap gui in order to show all the types industry available.
-Feature: Allow to enable/disable individually or all at once, the industries shown on small map.
This will permit to easily find those that are of some interest for the player.
Heavily based on gule's patch
2007-11-19 04:34:40 +00:00
belugas
fb0674ee2b (svn r11473) -Codechange: Replace two more instances of widget/smalltype numbers by enum(-a) values 2007-11-19 01:16:53 +00:00
belugas
51bb4a9dc8 (svn r11472) -Codechange: Give enuma for both the widget numbers and the used smallmap currently used type 2007-11-19 00:57:56 +00:00
smatz
2686901d84 (svn r11471) -Codechange: one more variable retyped to enum ViewportHighlightMode 2007-11-18 23:13:53 +00:00
glx
6097c07e4b (svn r11470) -Codechange: add git detection to MSVC (michi_cc) 2007-11-18 22:39:02 +00:00
glx
400ca1dae5 (svn r11469) -Fix (r11051): only consider changes in src when detecting modified (M) version 2007-11-18 22:37:44 +00:00
glx
272a21077d (svn r11468) -Fix (r11330): rev number detection didn't work for git with msys/mingw 2007-11-18 20:38:24 +00:00
rubidium
e15a5365d1 (svn r11467) -Fix [FS#1450]: OpenBSD has ALIGN already defined, causing compilation failures. 2007-11-18 20:21:41 +00:00
smatz
96d156944f (svn r11466) -Fix (r11339): operator priority problem resulting in problematic autoroad placement in some cases 2007-11-18 20:10:07 +00:00
smatz
cd3c16d789 (svn r11465) -Fix: more user-friedly placement in X and Y directions (most noticeable with autoroad) 2007-11-18 20:05:44 +00:00
rubidium
92e0bf68e3 (svn r11464) -Fix: some issue that made OpenTTD on MorphOS seriously unplayable. 2007-11-18 18:28:32 +00:00
rubidium
dc81ea6454 (svn r11463) -Fix: some OSes seem not to handle allocating 0 bytes in the same manner as others do. 2007-11-18 16:41:25 +00:00
241 changed files with 9381 additions and 6280 deletions

View File

@@ -105,14 +105,14 @@ else
# Are we a git dir?
ifeq ($(shell if test -d $(SRC_DIR)/../.git; then echo 1; fi), 1)
# Find the revision like: gXXXXM-branch
REV := g$(shell if head=`LC_ALL=C git rev-parse --verify HEAD 2>/dev/null`; then echo "$$head" | cut -c1-8; fi)$(shell if git diff-index HEAD | read dummy; then echo M; fi)$(shell git branch|grep '[*]' | sed 's/\* /-/;s/^-master$$//')
REV_NR := $(shell echo `LC_ALL=C cd "$(SRC_DIR)/.." && git log --pretty=format:%s src | grep "^(svn r[0-9]*)" | head -n 1 | sed "s/.*(svn r\([0-9]*\)).*/\1/"` )
REV := g$(shell if head=`LC_ALL=C git rev-parse --verify HEAD 2>/dev/null`; then echo "$$head" | cut -c1-8; fi)$(shell if cd "$(SRC_DIR)/.." && git diff-index HEAD src | read dummy; then echo M; fi)$(shell git branch|grep '[*]' | sed 's/\* /-/;s/^-master$$//')
REV_NR := $(shell LC_ALL=C cd "$(SRC_DIR)/.." && git log --pretty=format:%s src | grep -m 1 "^(svn r[0-9]*)" | sed "s/.*(svn r\([0-9]*\)).*/\1/" )
else
# Are we a hg (Mercurial) dir?
ifeq ($(shell if test -d $(SRC_DIR)/../.hg; then echo 1; fi), 1)
# Find the revision like: hXXXXM-branch
REV := h$(shell if head=`LC_ALL=C hg tip 2>/dev/null`; then echo "$$head" | head -n 1 | cut -c19-26; fi)$(shell if hg status $(SRC_DIR) | grep -v '^?' | read dummy; then echo M; fi)$(shell hg branch | sed 's/^/-/;s/^-default$$//')
REV_NR := $(shell LC_ALL=C hg log -k "svn" -l 1 --template "{desc}\n" $(SRC_DIR) | grep "^(svn r[0-9]*)" | head -n 1 | sed "s/.*(svn r\([0-9]*\)).*/\1/" )
REV_NR := $(shell LC_ALL=C hg log -k "svn" -l 1 --template "{desc}\n" $(SRC_DIR) | grep -m 1 "^(svn r[0-9]*)" | sed "s/.*(svn r\([0-9]*\)).*/\1/" )
endif
endif
endif

Binary file not shown.

Binary file not shown.

View File

@@ -1,3 +1,48 @@
0.6.0-beta2 (2007-12-09)
------------------------------------------------------------------------
- Feature: Allow setting a default password for new companies in network games (r11556)
- Feature: Signal selection GUI for the ones that really like to use that over CTRL (r11547)
- Feature: Make the bridge selection window resizable (r11539)
- Feature: [OSX] Added support for using Quartz instead of Quickdraw in windowed mode on OS X 10.4 and higher (r11496)
- Feature: Allow to resize on creation the smallmap gui in order to show all the types industry available, allow to enable/disable individually or all at once, the industries shown on small map (r11474)
- Codechange: Send and store the passwords a little more secure to/in the servers (r11557)
- Fix: Wrong error messages were shown when trying to build some industries in the scenario editor [FS#1524] (r11609)
- Fix: [NewGRF] Do not trigger industries, but only the industry's tiles (r11608)
- Fix: Wrong count of Kirby trains when a ship was build [FS#1482] (r11605)
- Fix: Tiles were not marked dirty in some cases when removing a lock or flooding (r11582, r11604)
- Fix: Make price for railtype conversion more realistic; conversion should not be more expensive than removing and rebuilding [FS#1481] (r11603)
- Fix: Do not allow changing network only patches settings from console when not in network game (r11594)
- Fix: IsSlopeRefused() result was half wrong causing banks to be built on wrong places (r11590)
- Fix: When ship depots got destroyed they always returned to water, even when it should have been canals [FS#1514] (r11589)
- Fix: The one way road button wasn't reset on abort (r11587)
- Fix: Windows could get completely missing when one resized the window to something very small [FS#1484] (r11583)
- Fix: Invalidate 'list trains/roadvehs/ships/planes' widgets when station part is added/removed so it does not become glitchy (r11577)
- Fix: Flood train stations when there are no trains on border tiles too (r11574, r11570)
- Fix: Reinitialise windows system before loading a savegame because not doing so can cause crashes [FS#1494] (r11572)
- Fix: Road vehicle getting to the wrong side of a station when trying to overtake in there [FS#1493] (r11571)
- Fix: Full paths sometimes did not work correctly [FS#1480] (r11568)
- Fix: Break the chain before moving a vehicle after another in the same chain instead of causing an infinite loop [FS#1512] (r11566)
- Fix: Aircraft sometimes stopped mid-air when the airport got destroyed [FS#1503] (r11562)
- Fix: Group list was not updated when removing the last group [FS#1504] (r11561)
- Fix: Overflow when drawing graphics with high company values [FS#1505] (r11558)
- Fix: If ever the air/heliport is suddenly not available while the "chopper" is descending, just go back into flying instead of stopping mid air [FS#1496] (r11546)
- Fix: Cargo translation was sometimes done when it should not be done [FS#1501] (r11544)
- Fix: [OSX] Detect statvfs at runtime (based on OSX version) instead of compile time. This should prevent a crash on OSX 10.3 with the precompiled binaries (in the load/save windows) (r11541)
- Fix: [OSX] Do not try to compile the quartz video driver on OSX 10.3 as it will fail (r11540)
- Fix: Do not do all kinds of 'updates' for town, waypoint, station and other signs when you have not converted the map to the 'current' format as that means you are going to read data in the 'old' format when you assume that it is in the 'current' format, which is eventually going to break (r11525)
- Fix: Assertion when tram reversed at a station [FS#1485] (r11524)
- Fix: The scrollbar of the network gui could run out of bounds (r11522)
- Fix: [OSX] The cocoa video driver let the mouse cursor escape the window when using rmb scrolling (r11520)
- Fix: Signs totally illegible when transparant signs is turned on and zoomed out more than one level [FS#1463] (r11507)
- Fix: Selling vehicles could cause the window of others to scroll to that location [FS#1471] (r11506)
- Fix: Do not do standard production change if callbacks 29/35 failed, disable smooth economy for industries using callbacks 29/35 (r11502)
- Fix: Two small layout issues with the vehicle grouping GUI (r11478)
- Fix: A road vehicle must not show that it is driving max speed when it is standing still waiting for the vehicle in from of it [FS#1451] (r11477)
- Fix: OpenBSD has ALIGN already defined, causing compilation failures [FS#1450] (r11467)
- Fix: Operator priority problem resulting in problematic autoroad placement in some cases (r11466)
0.6.0-beta1 (2007-11-18)
------------------------------------------------------------------------
- Feature: Make news messages related to the industry (production) changes better configurable; you can now disable news messages popping up for industries you are not servicing (r11442)
@@ -32,7 +77,7 @@
- Feature: New sign editor features including switching to previous/next sign (r10401)
- Feature: Disallow (in the GUI) the building of infrastructure you do not have available vehicles for. This means that the airport building button is disabled till you can actually build aircraft. The game itself will not disallow you to build the infrastructure and this "new" behaviour can be overridden with a patch setting [FS#669] (r10353)
- Feature: Add the possibility of automatically filling in timetables based on the times from the first (or subsequent) run-throughs (r10331)
- Feature: Option to select the "default" rail type when you start a new game or load a game. This is done either static, i.e. rail, electrified rail, monorail and maglev, or dynamic which takes either the first or last available railtype or the railtype that is used most on the map [FS#812] (r10329)
- Feature: Option to select the "default" rail type when you start a new game or load a game. This is done either static, i.e. rail, electrified rail, monorail and maglev, or dynamic which takes either the first or last available railtype or the railtype that is used most on the map [FS#812] (r10329)
- Feature: Give a better explanation why the loading of a savegame failed and do not crash on loading savegames that were altered by patches or branches [FS#917] (r10300)
- Feature: A sticky button for the client list window [FS#885] (r10293)
- Feature: Allow double-clicking on certain places: add NewGRF window, build-vehicle and town-action (r10265, r10267)
@@ -384,7 +429,7 @@
- Fix: Draw canal edges under buoys that are in a canal (r8635)
- Fix: Buoys on canal tiles do not flood anymore (r8620)
- Fix: Store the ownership of a water tile in the buoy tile and set the ownership of the water tile when the buoy is removed. Prevents certain abuses (r8619)
- Fix: When the currently selected player in the performance details window is no longer active, choose the first active player instead of the first player as that may also be inactive [FS#582] (r8612)
- Fix: When the currently selected player in the performance details window is no longer active, choose the first active player instead of the first player as that may also be inactive [FS#582] (r8612)
- Fix: Road vehicle very close after another (slower) road vehicle gets its speed reset to 0 when entering a tunnel, which causes a traffic jam outside of the tunnel (r8609)
- Fix: Bridges do not get destroyed when the bridge head gets flooded and there is a vehicle on the bridge [FS#564] (r8593)
- Fix: Road Vehicles now can obtain a slot even if the station is very spread out [FS#577] (r8536)
@@ -1028,7 +1073,7 @@
- Feature: scrolling credits list (in alphabetical order)
- Feature: Train window now shows the number of vehicles per row (mpetrov)
- Feature: [ 1039061 ] Swiss town-names (vulvulune)
- Feature: [ 1090950 ] Adding 16:10 resolutions for mainly laptops (doode)
- Feature: [ 1090950 ] Adding 16:10 resolutions for mainly laptops (doode)
- Feature: [ 1098254 ] (dis)Allow Shares. Add patch options to allow buying/selling of shares (Hackykid)
- Fix: [ 1031451 ] Catchment area shows when buying sign
- Fix: [ 1040119 ] Flood and wagons in depot

View File

@@ -5,7 +5,7 @@ log() {
}
set_default() {
released_version="0.6.0-beta1"
released_version="0.6.0-beta2"
ignore_extra_parameters="0"
# We set all kinds of defaults for params. Later on the user can override
@@ -1976,7 +1976,7 @@ make_sed() {
ppc=`$cc_host -dumpmachine | egrep "powerpc|ppc"`
if [ -n "$ppc" ]; then
T_CFLAGS="$CFLAGS -DFOUR_BYTE_BOOL"
osx_sysroot_version=10.3.9
osx_sysroot_version=10.4u
else
T_CFLAGS="$CFLAGS"
osx_sysroot_version=10.4u

View File

@@ -945,6 +945,7 @@
</tr>
</table>
</li>
<li>m4: Owner of the water</li>
<li>m6 bits 7..6 : Possibility of a bridge above, in the <a href="#bridge_direction">direction specified</a></li>
<li>m6 bits 1..0 : <a href="#tropic_zone">Tropic zone definition</a></li>
</ul>

View File

@@ -194,8 +194,8 @@ the array so you can quickly see what is used and what is not.
<td class="bits">XXXX XXXX</td>
<td class="bits"><span class="free">OOOO OOOO OOOO OOOO</span></td>
<td class="bits"><span class="free">OOOO OOOO</span></td>
<td class="bits"><span class="free">OOOO OOOO</span></td>
<td class="bits"><span class="free">OOOO OO</span>XX</td>
<td class="bits">XXXX XXXX</td>
<td class="bits">XXXX XXXX</td>
<td class="bits">XX<span class="free">OO OO</span>XX</td>
<td class="bits"><span class="free">OOOO OOOO</span></td>
</tr>

View File

@@ -15,15 +15,16 @@ Bugs for 0.6.0-beta1
------------------------------------------------------------------------
URL: http://bugs.openttd.org
- 1434 Network game crashes when player builds SH40
- 1519 Full screen issues in windows
- 1495 Long vehicles block multistop station
- 1487 Ending_year is never written to
- 1473 Train not going to available platform
- 1404 Spinner widget interprets one click as many
- 1401 Crash while scrolling screen
- 1386 Mac OS X fails to compile out of the box on 10.5
- 1264 Autoreplace for multiple NewGRF DMU sets fails
- 1200 Illegal names skip comparisons for uniquity
- 1141 [OSX] Not smooth moving map with touchpad
- 1109 [OSX] Choppy mouse cursor movement in fullscreen mode
- 1094 Foundations showing on 'build on slopes'
- 1074 Large slowdown when building tracks
- 1072 Text overflows in several windows
- 716 Train crash in depot with long long tracks

View File

@@ -4,6 +4,12 @@ openttd (0.6~svn) unstable; urgency=low
-- Matthijs Kooijman <m.kooijman@student.utwente.nl> Mon, 26 Feb 2007 21:07:05 +0100
openttd (0.6.0~beta2-1) unstable; urgency=low
* New upstream release.
-- Matthijs Kooijman <m.kooijman@student.utwente.nl> Sun, 09 Dec 2007 22:05:05 +0100
openttd (0.6.0~beta1-1) unstable; urgency=low
* New upstream release.

View File

@@ -1,6 +1,6 @@
!define APPNAME "OpenTTD" ; Define application name
!define APPVERSION "0.6.0" ; Define application version
!define INSTALLERVERSION 39 ; NEED TO UPDATE THIS FOR EVERY RELEASE!!!
!define INSTALLERVERSION 40 ; NEED TO UPDATE THIS FOR EVERY RELEASE!!!
!define APPURLLINK "http://www.openttd.org"
!define APPNAMEANDVERSION "${APPNAME} ${APPVERSION}-beta1"

View File

@@ -41,6 +41,12 @@ Sub UpdateFiles(version)
revision = Mid(OExec.StdOut.ReadLine(), 7)
revision = Mid(revision, 1, InStr(revision, ")") - 1)
End If
Case "g" ' git
Set oExec = WshShell.Exec("git log --pretty=format:%s --grep=" & Chr(34) & "^(svn r[0-9]*)" & Chr(34) & " -1 ../src")
if Err.Number = 0 Then
revision = Mid(oExec.StdOut.ReadLine(), 7)
revision = Mid(revision, 1, InStr(revision, ")") - 1)
End If
End Select
UpdateFile revision, version, cur_date, "../src/rev.cpp"
@@ -118,25 +124,49 @@ Function DetermineSVNVersion()
version = version & Replace(url, "/", "-")
End If
Else
' svn detection failed, reset error and try mercurial (hg)
' svn detection failed, reset error and try git
Err.Clear
Set oExec = WshShell.Exec("hg tip")
Set oExec = WshShell.Exec("git rev-parse --verify --short=8 HEAD")
If Err.Number = 0 Then
version = "h" & Mid(OExec.StdOut.ReadLine(), 19, 8)
Set oExec = WshShell.Exec("hg status ../src")
If Err.Number = 0 Then
Do
line = OExec.StdOut.ReadLine()
If Mid(line, 1, 1) <> "?" Then
version = version & "M"
Exit Do
End If
Loop While Not OExec.StdOut.atEndOfStream
version = "g" & oExec.StdOut.ReadLine()
Set oExec = WshShell.Exec("git diff-index --exit-code --quiet HEAD ../src")
Do While oExec.Status = 0 And Err.Number = 0
Loop
If Err.Number = 0 And oExec.ExitCode = 1 Then
version = version & "M"
End If
Set oExec = WshShell.Exec("hg branch")
Set oExec = WshShell.Exec("git symbolic-ref HEAD")
If Err.Number = 0 Then
line = OExec.StdOut.ReadLine()
If line <> "default" Then version = version & "-" & line
line = oExec.StdOut.ReadLine()
line = Mid(line, InStrRev(line, "/")+1)
If line <> "master" Then
version = version & "-" & line
End If
End If
Else
' try mercurial (hg)
Err.Clear
Set oExec = WshShell.Exec("hg tip")
If Err.Number = 0 Then
version = "h" & Mid(OExec.StdOut.ReadLine(), 19, 8)
Set oExec = WshShell.Exec("hg status ../src")
If Err.Number = 0 Then
Do
line = OExec.StdOut.ReadLine()
If Mid(line, 1, 1) <> "?" Then
version = version & "M"
Exit Do
End If
Loop While Not OExec.StdOut.atEndOfStream
End If
Set oExec = WshShell.Exec("hg branch")
If Err.Number = 0 Then
line = OExec.StdOut.ReadLine()
If line <> "default" Then
version = version & "-" & line
End If
End If
End If
End If
End If
@@ -164,7 +194,7 @@ Function IsCachedVersion(version)
End Function
Dim version
version = "0.6.0-beta1"
version = "0.6.0-beta2"
If Not (IsCachedVersion(version) And FSO.FileExists("../src/rev.cpp") And FSO.FileExists("../src/ottdres.rc")) Then
UpdateFiles version
End If

View File

@@ -30,7 +30,7 @@
OmitFramePointers="TRUE"
OptimizeForProcessor="1"
AdditionalIncludeDirectories="..\objs\langs"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;;WITH_ASSERT"
StringPooling="TRUE"
ExceptionHandling="TRUE"
RuntimeLibrary="0"
@@ -197,6 +197,12 @@
<File
RelativePath=".\..\src\console_cmds.cpp">
</File>
<File
RelativePath=".\..\src\core\bitmath_func.cpp">
</File>
<File
RelativePath=".\..\src\core\random_func.cpp">
</File>
<File
RelativePath=".\..\src\currency.cpp">
</File>
@@ -257,9 +263,6 @@
<File
RelativePath=".\..\src\md5.cpp">
</File>
<File
RelativePath=".\..\src\mersenne.cpp">
</File>
<File
RelativePath=".\..\src\minilzo.cpp">
</File>
@@ -426,6 +429,15 @@
<File
RelativePath=".\..\src\console.h">
</File>
<File
RelativePath=".\..\src\core\bitmath_func.hpp">
</File>
<File
RelativePath=".\..\src\core\math_func.hpp">
</File>
<File
RelativePath=".\..\src\core\random_func.hpp">
</File>
<File
RelativePath=".\..\src\currency.h">
</File>
@@ -657,6 +669,9 @@
<File
RelativePath=".\..\src\station.h">
</File>
<File
RelativePath=".\..\src\station_gui.h">
</File>
<File
RelativePath=".\..\src\stdafx.h">
</File>

View File

@@ -30,7 +30,7 @@
OmitFramePointers="TRUE"
OptimizeForProcessor="1"
AdditionalIncludeDirectories="..\objs\langs"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;;WITH_ASSERT"
StringPooling="TRUE"
ExceptionHandling="TRUE"
RuntimeLibrary="0"

View File

@@ -61,7 +61,7 @@
FavorSizeOrSpeed="2"
OmitFramePointers="true"
AdditionalIncludeDirectories="..\objs\langs"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;;WITH_ASSERT"
StringPooling="true"
ExceptionHandling="1"
RuntimeLibrary="0"
@@ -272,7 +272,7 @@
FavorSizeOrSpeed="2"
OmitFramePointers="true"
AdditionalIncludeDirectories="..\objs\langs"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;;WITH_ASSERT"
StringPooling="true"
ExceptionHandling="1"
RuntimeLibrary="0"
@@ -495,6 +495,14 @@
RelativePath=".\..\src\console_cmds.cpp"
>
</File>
<File
RelativePath=".\..\src\core\bitmath_func.cpp"
>
</File>
<File
RelativePath=".\..\src\core\random_func.cpp"
>
</File>
<File
RelativePath=".\..\src\currency.cpp"
>
@@ -575,10 +583,6 @@
RelativePath=".\..\src\md5.cpp"
>
</File>
<File
RelativePath=".\..\src\mersenne.cpp"
>
</File>
<File
RelativePath=".\..\src\minilzo.cpp"
>
@@ -799,6 +803,18 @@
RelativePath=".\..\src\console.h"
>
</File>
<File
RelativePath=".\..\src\core\bitmath_func.hpp"
>
</File>
<File
RelativePath=".\..\src\core\math_func.hpp"
>
</File>
<File
RelativePath=".\..\src\core\random_func.hpp"
>
</File>
<File
RelativePath=".\..\src\currency.h"
>
@@ -1107,6 +1123,10 @@
RelativePath=".\..\src\station.h"
>
</File>
<File
RelativePath=".\..\src\station_gui.h"
>
</File>
<File
RelativePath=".\..\src\stdafx.h"
>

View File

@@ -61,7 +61,7 @@
FavorSizeOrSpeed="2"
OmitFramePointers="true"
AdditionalIncludeDirectories="..\objs\langs"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;;WITH_ASSERT"
StringPooling="true"
ExceptionHandling="1"
RuntimeLibrary="0"
@@ -272,7 +272,7 @@
FavorSizeOrSpeed="2"
OmitFramePointers="true"
AdditionalIncludeDirectories="..\objs\langs"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;;WITH_ASSERT"
StringPooling="true"
ExceptionHandling="1"
RuntimeLibrary="0"

View File

@@ -62,7 +62,7 @@
FavorSizeOrSpeed="2"
OmitFramePointers="true"
AdditionalIncludeDirectories="..\objs\langs"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;;WITH_ASSERT"
StringPooling="true"
ExceptionHandling="1"
RuntimeLibrary="0"
@@ -270,7 +270,7 @@
FavorSizeOrSpeed="2"
OmitFramePointers="true"
AdditionalIncludeDirectories="..\objs\langs"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;;WITH_ASSERT"
StringPooling="true"
ExceptionHandling="1"
RuntimeLibrary="0"
@@ -492,6 +492,14 @@
RelativePath=".\..\src\console_cmds.cpp"
>
</File>
<File
RelativePath=".\..\src\core\bitmath_func.cpp"
>
</File>
<File
RelativePath=".\..\src\core\random_func.cpp"
>
</File>
<File
RelativePath=".\..\src\currency.cpp"
>
@@ -572,10 +580,6 @@
RelativePath=".\..\src\md5.cpp"
>
</File>
<File
RelativePath=".\..\src\mersenne.cpp"
>
</File>
<File
RelativePath=".\..\src\minilzo.cpp"
>
@@ -796,6 +800,18 @@
RelativePath=".\..\src\console.h"
>
</File>
<File
RelativePath=".\..\src\core\bitmath_func.hpp"
>
</File>
<File
RelativePath=".\..\src\core\math_func.hpp"
>
</File>
<File
RelativePath=".\..\src\core\random_func.hpp"
>
</File>
<File
RelativePath=".\..\src\currency.h"
>
@@ -1104,6 +1120,10 @@
RelativePath=".\..\src\station.h"
>
</File>
<File
RelativePath=".\..\src\station_gui.h"
>
</File>
<File
RelativePath=".\..\src\stdafx.h"
>

View File

@@ -62,7 +62,7 @@
FavorSizeOrSpeed="2"
OmitFramePointers="true"
AdditionalIncludeDirectories="..\objs\langs"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;;WITH_ASSERT"
StringPooling="true"
ExceptionHandling="1"
RuntimeLibrary="0"
@@ -270,7 +270,7 @@
FavorSizeOrSpeed="2"
OmitFramePointers="true"
AdditionalIncludeDirectories="..\objs\langs"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;;WITH_ASSERT"
StringPooling="true"
ExceptionHandling="1"
RuntimeLibrary="0"

View File

@@ -1,6 +1,6 @@
OpenTTD README
Last updated: 2007-11-18
Release version: 0.6.0-beta1
Last updated: 2007-12-09
Release version: 0.6.0-beta2
------------------------------------------------------------------------

View File

@@ -10,6 +10,8 @@ cargotype.cpp
command.cpp
console.cpp
console_cmds.cpp
core/bitmath_func.cpp
core/random_func.cpp
currency.cpp
date.cpp
debug.cpp
@@ -30,7 +32,6 @@ helpers.cpp
landscape.cpp
map.cpp
md5.cpp
mersenne.cpp
minilzo.cpp
misc.cpp
mixer.cpp
@@ -108,6 +109,9 @@ cargopacket.h
cargotype.h
command.h
console.h
core/bitmath_func.hpp
core/math_func.hpp
core/random_func.hpp
currency.h
date.h
debug.h
@@ -185,6 +189,7 @@ sound.h
sprite.h
spritecache.h
station.h
station_gui.h
stdafx.h
string.h
texteff.hpp
@@ -477,7 +482,11 @@ sound/null_s.cpp
#end
#if COCOA
video/cocoa_v.mm
video/cocoa/cocoa_v.mm
video/cocoa/event.mm
video/cocoa/fullscreen.mm
video/cocoa/wnd_quartz.mm
video/cocoa/wnd_quickdraw.mm
sound/cocoa_s.cpp
os/macosx/splash.cpp
#end

View File

@@ -146,7 +146,7 @@ static EngineID AiChooseTrainToBuild(RailType railtype, Money money, byte flag,
if (!IsCompatibleRail(rvi->railtype, railtype) ||
rvi->railveh_type == RAILVEH_WAGON ||
(rvi->railveh_type == RAILVEH_MULTIHEAD && flag & 1) ||
!HASBIT(e->player_avail, _current_player) ||
!HasBit(e->player_avail, _current_player) ||
e->reliability < 0x8A3D) {
continue;
}
@@ -174,7 +174,7 @@ static EngineID AiChooseRoadVehToBuild(CargoID cargo, Money money, TileIndex til
int32 rating;
CommandCost ret;
if (!HASBIT(e->player_avail, _current_player) || e->reliability < 0x8A3D) {
if (!HasBit(e->player_avail, _current_player) || e->reliability < 0x8A3D) {
continue;
}
@@ -209,7 +209,7 @@ static EngineID AiChooseAircraftToBuild(Money money, byte flag)
const Engine* e = GetEngine(i);
CommandCost ret;
if (!HASBIT(e->player_avail, _current_player) || e->reliability < 0x8A3D) {
if (!HasBit(e->player_avail, _current_player) || e->reliability < 0x8A3D) {
continue;
}
@@ -643,7 +643,7 @@ static bool AiCheckIfRouteIsGood(Player *p, FoundRoute *fr, byte bitmask)
if (p->ai.route_type_mask != 0 &&
!(p->ai.route_type_mask & bitmask) &&
!CHANCE16(1, 5)) {
!Chance16(1, 5)) {
return false;
}
@@ -698,11 +698,11 @@ static void AiWantLongIndustryRoute(Player *p)
for (;;) {
// look for one from the subsidy list
AiFindSubsidyIndustryRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 60, 90 + 1)) break;
if (IsInsideMM(fr.distance, 60, 90 + 1)) break;
// try a random one
AiFindRandomIndustryRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 60, 90 + 1)) break;
if (IsInsideMM(fr.distance, 60, 90 + 1)) break;
// only test 60 times
if (--i == 0) return;
@@ -801,11 +801,11 @@ static void AiWantMediumIndustryRoute(Player *p)
for (;;) {
// look for one from the subsidy list
AiFindSubsidyIndustryRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 40, 60 + 1)) break;
if (IsInsideMM(fr.distance, 40, 60 + 1)) break;
// try a random one
AiFindRandomIndustryRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 40, 60 + 1)) break;
if (IsInsideMM(fr.distance, 40, 60 + 1)) break;
// only test 60 times
if (--i == 0) return;
@@ -869,11 +869,11 @@ static void AiWantShortIndustryRoute(Player *p)
for (;;) {
// look for one from the subsidy list
AiFindSubsidyIndustryRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 15, 40 + 1)) break;
if (IsInsideMM(fr.distance, 15, 40 + 1)) break;
// try a random one
AiFindRandomIndustryRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 15, 40 + 1)) break;
if (IsInsideMM(fr.distance, 15, 40 + 1)) break;
// only test 60 times
if (--i == 0) return;
@@ -937,11 +937,11 @@ static void AiWantMailRoute(Player *p)
for (;;) {
// look for one from the subsidy list
AiFindSubsidyPassengerRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 60, 110 + 1)) break;
if (IsInsideMM(fr.distance, 60, 110 + 1)) break;
// try a random one
AiFindRandomPassengerRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 60, 110 + 1)) break;
if (IsInsideMM(fr.distance, 60, 110 + 1)) break;
// only test 60 times
if (--i == 0) return;
@@ -1038,11 +1038,11 @@ static void AiWantPassengerRoute(Player *p)
for (;;) {
// look for one from the subsidy list
AiFindSubsidyPassengerRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 0, 55 + 1)) break;
if (IsInsideMM(fr.distance, 0, 55 + 1)) break;
// try a random one
AiFindRandomPassengerRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 0, 55 + 1)) break;
if (IsInsideMM(fr.distance, 0, 55 + 1)) break;
// only test 60 times
if (--i == 0) return;
@@ -1126,11 +1126,11 @@ static void AiWantLongRoadIndustryRoute(Player *p)
for (;;) {
// look for one from the subsidy list
AiFindSubsidyIndustryRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 35, 55 + 1)) break;
if (IsInsideMM(fr.distance, 35, 55 + 1)) break;
// try a random one
AiFindRandomIndustryRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 35, 55 + 1)) break;
if (IsInsideMM(fr.distance, 35, 55 + 1)) break;
// only test 60 times
if (--i == 0) return;
@@ -1182,11 +1182,11 @@ static void AiWantMediumRoadIndustryRoute(Player *p)
for (;;) {
// look for one from the subsidy list
AiFindSubsidyIndustryRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 15, 40 + 1)) break;
if (IsInsideMM(fr.distance, 15, 40 + 1)) break;
// try a random one
AiFindRandomIndustryRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 15, 40 + 1)) break;
if (IsInsideMM(fr.distance, 15, 40 + 1)) break;
// only test 60 times
if (--i == 0) return;
@@ -1238,11 +1238,11 @@ static void AiWantLongRoadPassengerRoute(Player *p)
for (;;) {
// look for one from the subsidy list
AiFindSubsidyPassengerRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 55, 180 + 1)) break;
if (IsInsideMM(fr.distance, 55, 180 + 1)) break;
// try a random one
AiFindRandomPassengerRoute(&fr);
if (IS_INT_INSIDE(fr.distance, 55, 180 + 1)) break;
if (IsInsideMM(fr.distance, 55, 180 + 1)) break;
// only test 60 times
if (--i == 0) return;
@@ -1407,11 +1407,11 @@ static void AiWantPassengerAircraftRoute(Player *p)
// look for one from the subsidy list
AiFindSubsidyPassengerRoute(&fr);
if (IS_INT_INSIDE(fr.distance, min_squares, max_squares + 1)) break;
if (IsInsideMM(fr.distance, min_squares, max_squares + 1)) break;
// try a random one
AiFindRandomPassengerRoute(&fr);
if (IS_INT_INSIDE(fr.distance, min_squares, max_squares + 1)) break;
if (IsInsideMM(fr.distance, min_squares, max_squares + 1)) break;
// only test 60 times
if (--i == 0) return;
@@ -1452,7 +1452,7 @@ static void AiWantPassengerAircraftRoute(Player *p)
* Also, non-full load is more resistant against starving (by building better stations
* or using exclusive rights)
*/
p->ai.num_want_fullload = CHANCE16(1, 5); // 20% chance
p->ai.num_want_fullload = Chance16(1, 5); // 20% chance
// p->ai.loco_id = INVALID_VEHICLE;
p->ai.order_list_blocks[0] = 0;
p->ai.order_list_blocks[1] = 1;
@@ -1646,13 +1646,15 @@ clear_town_stuff:;
rating += _cleared_town_rating;
}
} else if (p->mode == 2) {
// Rail
/* Rail */
if (IsTileType(c, MP_RAILWAY)) return CMD_ERROR;
j = p->attr;
k = 0;
// Build the rail
/* Build the rail
* note: FOR_EACH_SET_BIT cannot be used here
*/
for (i = 0; i != 6; i++, j >>= 1) {
if (j & 1) {
k = i;
@@ -2412,7 +2414,7 @@ static EngineID AiFindBestWagon(CargoID cargo, RailType railtype)
if (!IsCompatibleRail(rvi->railtype, railtype) ||
rvi->railveh_type != RAILVEH_WAGON ||
!HASBIT(e->player_avail, _current_player)) {
!HasBit(e->player_avail, _current_player)) {
continue;
}
@@ -2854,7 +2856,6 @@ static bool AiCheckRoadFinished(Player *p)
TileIndex tile;
DiagDirection dir = p->ai.cur_dir_a;
uint32 bits;
int i;
are.dest = p->ai.cur_tile_b;
tile = TILE_MASK(p->ai.cur_tile_a + TileOffsByDiagDir(dir));
@@ -2865,7 +2866,8 @@ static bool AiCheckRoadFinished(Player *p)
are.best_dist = (uint)-1;
for_each_bit(i, bits) {
uint i;
FOR_EACH_SET_BIT(i, bits) {
FollowTrack(tile, 0x3000 | TRANSPORT_ROAD, ROADTYPES_ROAD, (DiagDirection)_dir_by_track[i], (TPFEnumProc*)AiEnumFollowRoad, NULL, &are);
}
@@ -3366,7 +3368,7 @@ static CommandCost AiDoBuildDefaultAirportBlock(TileIndex tile, const AiDefaultB
CommandCost total_cost, ret;
for (; p->mode == 0; p++) {
if (!HASBIT(avail_airports, p->attr)) return CMD_ERROR;
if (!HasBit(avail_airports, p->attr)) return CMD_ERROR;
ret = DoCommand(TILE_MASK(tile + ToTileIndexDiff(p->tileoffs)), p->attr, 0, flag | DC_AUTO | DC_NO_WATER, CMD_BUILD_AIRPORT);
if (CmdFailed(ret)) return CMD_ERROR;
total_cost.AddCost(ret);
@@ -3847,7 +3849,7 @@ static void AiHandleTakeover(Player *p)
return;
}
SETBIT(p->bankrupt_asked, best_pl->index);
SetBit(p->bankrupt_asked, best_pl->index);
if (best_pl->index == _local_player) {
p->bankrupt_timeout = 4440;

View File

@@ -250,7 +250,7 @@ EngineID AiNew_PickVehicle(Player *p)
// Is it availiable?
// Also, check if the reliability of the vehicle is above the AI_VEHICLE_MIN_RELIABILTY
if (!HASBIT(e->player_avail, _current_player) || e->reliability * 100 < AI_VEHICLE_MIN_RELIABILTY << 16) continue;
if (!HasBit(e->player_avail, _current_player) || e->reliability * 100 < AI_VEHICLE_MIN_RELIABILTY << 16) continue;
/* Rate and compare the engine by speed & capacity */
rating = rvi->max_speed * rvi->capacity;

View File

@@ -411,7 +411,7 @@ static int32 AyStar_AiPathFinder_CalculateG(AyStar *aystar, AyStarNode *current,
if (PathFinderInfo->rail_or_road) {
Foundation f = GetRailFoundation(parent_tileh, (TrackBits)(1 << AiNew_GetRailDirection(parent->path.parent->node.tile, parent->path.node.tile, current->tile)));
// Maybe is BRIDGE_NO_FOUNDATION a bit strange here, but it contains just the right information..
if (IsInclinedFoundation(f) || (!IsFoundation(f) && HASBIT(BRIDGE_NO_FOUNDATION, parent_tileh))) {
if (IsInclinedFoundation(f) || (!IsFoundation(f) && HasBit(BRIDGE_NO_FOUNDATION, parent_tileh))) {
res += AI_PATHFINDER_TILE_GOES_UP_PENALTY;
} else {
res += AI_PATHFINDER_FOUNDATION_PENALTY;
@@ -419,7 +419,7 @@ static int32 AyStar_AiPathFinder_CalculateG(AyStar *aystar, AyStarNode *current,
} else {
if (!IsRoad(parent->path.node.tile) || !IsTileType(parent->path.node.tile, MP_TUNNELBRIDGE)) {
Foundation f = GetRoadFoundation(parent_tileh, (RoadBits)AiNew_GetRoadDirection(parent->path.parent->node.tile, parent->path.node.tile, current->tile));
if (IsInclinedFoundation(f) || (!IsFoundation(f) && HASBIT(BRIDGE_NO_FOUNDATION, parent_tileh))) {
if (IsInclinedFoundation(f) || (!IsFoundation(f) && HasBit(BRIDGE_NO_FOUNDATION, parent_tileh))) {
res += AI_PATHFINDER_TILE_GOES_UP_PENALTY;
} else {
res += AI_PATHFINDER_FOUNDATION_PENALTY;
@@ -444,13 +444,13 @@ static int32 AyStar_AiPathFinder_CalculateG(AyStar *aystar, AyStarNode *current,
res += AI_PATHFINDER_BRIDGE_PENALTY * GetBridgeLength(current->tile, parent->path.node.tile);
// Check if we are going up or down, first for the starting point
// In user_data[0] is at the 8th bit the direction
if (!HASBIT(BRIDGE_NO_FOUNDATION, parent_tileh)) {
if (!HasBit(BRIDGE_NO_FOUNDATION, parent_tileh)) {
if (IsLeveledFoundation(GetBridgeFoundation(parent_tileh, (Axis)((current->user_data[0] >> 8) & 1)))) {
res += AI_PATHFINDER_BRIDGE_GOES_UP_PENALTY;
}
}
// Second for the end point
if (!HASBIT(BRIDGE_NO_FOUNDATION, tileh)) {
if (!HasBit(BRIDGE_NO_FOUNDATION, tileh)) {
if (IsLeveledFoundation(GetBridgeFoundation(tileh, (Axis)((current->user_data[0] >> 8) & 1)))) {
res += AI_PATHFINDER_BRIDGE_GOES_UP_PENALTY;
}

View File

@@ -291,7 +291,7 @@ CommandCost CmdBuildAircraft(TileIndex tile, uint32 flags, uint32 p1, uint32 p2)
return_cmd_error(STR_00E1_TOO_MANY_VEHICLES_IN_GAME);
}
UnitID unit_num = HASBIT(p2, 0) ? 0 : GetFreeUnitNumber(VEH_AIRCRAFT);
UnitID unit_num = HasBit(p2, 0) ? 0 : GetFreeUnitNumber(VEH_AIRCRAFT);
if (unit_num > _patches.max_aircraft)
return_cmd_error(STR_00E1_TOO_MANY_VEHICLES_IN_GAME);
@@ -364,7 +364,7 @@ CommandCost CmdBuildAircraft(TileIndex tile, uint32 flags, uint32 p1, uint32 p2)
v->cargo_type = cargo;
if (HASBIT(EngInfo(p1)->callbackmask, CBM_VEHICLE_REFIT_CAPACITY)) {
if (HasBit(EngInfo(p1)->callbackmask, CBM_VEHICLE_REFIT_CAPACITY)) {
callback = GetVehicleCallback(CBID_VEHICLE_REFIT_CAPACITY, 0, 0, v->engine_type, v);
}
@@ -418,7 +418,7 @@ CommandCost CmdBuildAircraft(TileIndex tile, uint32 flags, uint32 p1, uint32 p2)
u->random_bits = VehicleRandomBits();
v->vehicle_flags = 0;
if (e->flags & ENGINE_EXCLUSIVE_PREVIEW) SETBIT(v->vehicle_flags, VF_BUILT_AS_PROTOTYPE);
if (e->flags & ENGINE_EXCLUSIVE_PREVIEW) SetBit(v->vehicle_flags, VF_BUILT_AS_PROTOTYPE);
UpdateAircraftCache(v);
@@ -568,13 +568,13 @@ CommandCost CmdSendAircraftToHangar(TileIndex tile, uint32 flags, uint32 p1, uin
if (v->type != VEH_AIRCRAFT || !CheckOwnership(v->owner) || v->IsInDepot()) return CMD_ERROR;
if (v->current_order.type == OT_GOTO_DEPOT && !(p2 & DEPOT_LOCATE_HANGAR)) {
if (!!(p2 & DEPOT_SERVICE) == HASBIT(v->current_order.flags, OFB_HALT_IN_DEPOT)) {
if (!!(p2 & DEPOT_SERVICE) == HasBit(v->current_order.flags, OFB_HALT_IN_DEPOT)) {
/* We called with a different DEPOT_SERVICE setting.
* Now we change the setting to apply the new one and let the vehicle head for the same hangar.
* Note: the if is (true for requesting service == true for ordered to stop in hangar) */
if (flags & DC_EXEC) {
CLRBIT(v->current_order.flags, OFB_PART_OF_ORDERS);
TOGGLEBIT(v->current_order.flags, OFB_HALT_IN_DEPOT);
ClrBit(v->current_order.flags, OFB_PART_OF_ORDERS);
ToggleBit(v->current_order.flags, OFB_HALT_IN_DEPOT);
InvalidateWindowWidget(WC_VEHICLE_VIEW, v->index, STATUS_BAR);
}
return CommandCost();
@@ -606,7 +606,7 @@ CommandCost CmdSendAircraftToHangar(TileIndex tile, uint32 flags, uint32 p1, uin
v->current_order.type = OT_GOTO_DEPOT;
v->current_order.flags = OF_NON_STOP;
if (!(p2 & DEPOT_SERVICE)) SETBIT(v->current_order.flags, OFB_HALT_IN_DEPOT);
if (!(p2 & DEPOT_SERVICE)) SetBit(v->current_order.flags, OFB_HALT_IN_DEPOT);
v->current_order.refit_cargo = CT_INVALID;
v->current_order.dest = next_airport_index;
InvalidateWindowWidget(WC_VEHICLE_VIEW, v->index, STATUS_BAR);
@@ -650,7 +650,7 @@ CommandCost CmdRefitAircraft(TileIndex tile, uint32 flags, uint32 p1, uint32 p2)
/* Check the refit capacity callback */
uint16 callback = CALLBACK_FAILED;
if (HASBIT(EngInfo(v->engine_type)->callbackmask, CBM_VEHICLE_REFIT_CAPACITY)) {
if (HasBit(EngInfo(v->engine_type)->callbackmask, CBM_VEHICLE_REFIT_CAPACITY)) {
/* Back up the existing cargo type */
CargoID temp_cid = v->cargo_type;
byte temp_subtype = v->cargo_subtype;
@@ -833,12 +833,12 @@ static void SetAircraftPosition(Vehicle *v, int x, int y, int z)
Vehicle *u = v->Next();
int safe_x = clamp(x, 0, MapMaxX() * TILE_SIZE);
int safe_y = clamp(y - 1, 0, MapMaxY() * TILE_SIZE);
int safe_x = Clamp(x, 0, MapMaxX() * TILE_SIZE);
int safe_y = Clamp(y - 1, 0, MapMaxY() * TILE_SIZE);
u->x_pos = x;
u->y_pos = y - ((v->z_pos-GetSlopeZ(safe_x, safe_y)) >> 3);;
safe_y = clamp(u->y_pos, 0, MapMaxY() * TILE_SIZE);
safe_y = Clamp(u->y_pos, 0, MapMaxY() * TILE_SIZE);
u->z_pos = GetSlopeZ(safe_x, safe_y);
u->cur_image = v->cur_image;
@@ -1042,7 +1042,17 @@ static bool AircraftController(Vehicle *v)
tile = st->xy;
/* Jump into our "holding pattern" state machine if possible */
if (v->u.air.pos >= afc->nofelements) v->u.air.pos = v->u.air.previous_pos = AircraftGetEntryPoint(v, afc);
if (v->u.air.pos >= afc->nofelements) {
v->u.air.pos = v->u.air.previous_pos = AircraftGetEntryPoint(v, afc);
} else if (v->u.air.targetairport != v->current_order.dest) {
/* If not possible, just get out of here fast */
v->u.air.state = FLYING;
UpdateAircraftCache(v);
AircraftNextAirportPos_and_Order(v);
/* get aircraft back on running altitude */
SetAircraftPosition(v, v->x_pos, v->y_pos, GetAircraftFlyingAltitude(v));
return false;
}
}
/* get airport moving data */
@@ -1112,7 +1122,7 @@ static bool AircraftController(Vehicle *v)
}
/* Get distance from destination pos to current pos. */
uint dist = myabs(x + amd->x - v->x_pos) + myabs(y + amd->y - v->y_pos);
uint dist = abs(x + amd->x - v->x_pos) + abs(y + amd->y - v->y_pos);
/* Need exact position? */
if (!(amd->flag & AMED_EXACTPOS) && dist <= (amd->flag & AMED_SLOWTURN ? 8U : 4U)) return true;
@@ -1255,7 +1265,7 @@ static void HandleCrashedAircraft(Vehicle *v)
if (v->u.air.crashed_counter < 650) {
uint32 r;
if (CHANCE16R(1,32,r)) {
if (Chance16R(1,32,r)) {
static const DirDiff delta[] = {
DIRDIFF_45LEFT, DIRDIFF_SAME, DIRDIFF_SAME, DIRDIFF_45RIGHT
};
@@ -1680,7 +1690,7 @@ static void AircraftEventHandler_HeliTakeOff(Vehicle *v, const AirportFTAClass *
if (v->owner == _local_player && (
EngineHasReplacementForPlayer(p, v->engine_type, v->group_id) ||
((p->engine_renew && v->age - v->max_age > p->engine_renew_months * 30) &&
HASBIT(GetEngine(v->engine_type)->player_avail, _local_player))
HasBit(GetEngine(v->engine_type)->player_avail, _local_player))
)) {
_current_player = _local_player;
DoCommandP(v->tile, v->index, DEPOT_SERVICE | DEPOT_LOCATE_HANGAR, NULL, CMD_SEND_AIRCRAFT_TO_HANGAR | CMD_SHOW_NO_ERROR);
@@ -1957,10 +1967,10 @@ static bool FreeTerminal(Vehicle *v, byte i, byte last_terminal)
{
Station *st = GetStation(v->u.air.targetairport);
for (; i < last_terminal; i++) {
if (!HASBIT(st->airport_flags, _airport_terminal_flag[i])) {
if (!HasBit(st->airport_flags, _airport_terminal_flag[i])) {
/* TERMINAL# HELIPAD# */
v->u.air.state = _airport_terminal_state[i]; // start moving to that terminal/helipad
SETBIT(st->airport_flags, _airport_terminal_flag[i]); // occupy terminal/helipad
SetBit(st->airport_flags, _airport_terminal_flag[i]); // occupy terminal/helipad
return true;
}
}

View File

@@ -431,18 +431,6 @@ static const char* const _airport_heading_strings[] = {
"DUMMY" // extra heading for 255
};
static uint AirportBlockToString(uint32 block)
{
uint i = 0;
if (block & 0xffff0000) { block >>= 16; i += 16; }
if (block & 0x0000ff00) { block >>= 8; i += 8; }
if (block & 0x000000f0) { block >>= 4; i += 4; }
if (block & 0x0000000c) { block >>= 2; i += 2; }
if (block & 0x00000002) { i += 1; }
return i;
}
static void AirportPrintOut(uint nofelements, const AirportFTA *layout, bool full_report)
{
if (!full_report) printf("(P = Current Position; NP = Next Position)\n");
@@ -453,7 +441,7 @@ static void AirportPrintOut(uint nofelements, const AirportFTA *layout, bool ful
byte heading = (current->heading == 255) ? MAX_HEADINGS + 1 : current->heading;
printf("\tPos:%2d NPos:%2d Heading:%15s Block:%2d\n", current->position,
current->next_position, _airport_heading_strings[heading],
AirportBlockToString(current->block));
FindLastBit(current->block));
} else {
printf("P:%2d NP:%2d", current->position, current->next_position);
}
@@ -488,14 +476,14 @@ uint32 GetValidAirports()
{
uint32 mask = 0;
if (_cur_year < 1960 || _patches.always_small_airport) SETBIT(mask, 0); // small airport
if (_cur_year >= 1955) SETBIT(mask, 1); // city airport
if (_cur_year >= 1963) SETBIT(mask, 2); // heliport
if (_cur_year >= 1980) SETBIT(mask, 3); // metropolitan airport
if (_cur_year >= 1990) SETBIT(mask, 4); // international airport
if (_cur_year >= 1983) SETBIT(mask, 5); // commuter airport
if (_cur_year >= 1976) SETBIT(mask, 6); // helidepot
if (_cur_year >= 2002) SETBIT(mask, 7); // intercontinental airport
if (_cur_year >= 1980) SETBIT(mask, 8); // helistation
if (_cur_year < 1960 || _patches.always_small_airport) SetBit(mask, 0); // small airport
if (_cur_year >= 1955) SetBit(mask, 1); // city airport
if (_cur_year >= 1963) SetBit(mask, 2); // heliport
if (_cur_year >= 1980) SetBit(mask, 3); // metropolitan airport
if (_cur_year >= 1990) SetBit(mask, 4); // international airport
if (_cur_year >= 1983) SetBit(mask, 5); // commuter airport
if (_cur_year >= 1976) SetBit(mask, 6); // helidepot
if (_cur_year >= 2002) SetBit(mask, 7); // intercontinental airport
if (_cur_year >= 1980) SetBit(mask, 8); // helistation
return mask;
}

View File

@@ -101,7 +101,7 @@ static void BuildAirToolbWndProc(Window *w, WindowEvent *e)
break;
case WE_ABORT_PLACE_OBJ:
RaiseWindowButtons(w);
w->RaiseButtons();
w = FindWindowById(WC_BUILD_STATION, 0);
if (w != 0)
@@ -145,9 +145,9 @@ static void BuildAirportPickerWndProc(Window *w, WindowEvent *e)
{
switch (e->event) {
case WE_CREATE:
SetWindowWidgetLoweredState(w, 16, !_station_show_coverage);
SetWindowWidgetLoweredState(w, 17, _station_show_coverage);
LowerWindowWidget(w, _selected_airport_type + 7);
w->SetWidgetLoweredState(16, !_station_show_coverage);
w->SetWidgetLoweredState(17, _station_show_coverage);
w->LowerWidget(_selected_airport_type + 7);
break;
case WE_PAINT: {
@@ -159,10 +159,10 @@ static void BuildAirportPickerWndProc(Window *w, WindowEvent *e)
avail_airports = GetValidAirports();
RaiseWindowWidget(w, _selected_airport_type + 7);
if (!HASBIT(avail_airports, 0) && _selected_airport_type == AT_SMALL) _selected_airport_type = AT_LARGE;
if (!HASBIT(avail_airports, 1) && _selected_airport_type == AT_LARGE) _selected_airport_type = AT_SMALL;
LowerWindowWidget(w, _selected_airport_type + 7);
w->RaiseWidget(_selected_airport_type + 7);
if (!HasBit(avail_airports, 0) && _selected_airport_type == AT_SMALL) _selected_airport_type = AT_LARGE;
if (!HasBit(avail_airports, 1) && _selected_airport_type == AT_LARGE) _selected_airport_type = AT_SMALL;
w->LowerWidget(_selected_airport_type + 7);
/* 'Country Airport' starts at widget 7, and if its bit is set, it is
* available, so take its opposite value to set the disabled state.
@@ -170,7 +170,7 @@ static void BuildAirportPickerWndProc(Window *w, WindowEvent *e)
* XXX TODO : all airports should be held in arrays, with all relevant data.
* This should be part of newgrf-airports, i suppose
*/
for (i = 0; i < 9; i++) SetWindowWidgetDisabledState(w, i + 7, !HASBIT(avail_airports, i));
for (i = 0; i < 9; i++) w->SetWidgetDisabledState(i + 7, !HasBit(avail_airports, i));
// select default the coverage area to 'Off' (16)
airport = GetAirport(_selected_airport_type);
@@ -190,16 +190,16 @@ static void BuildAirportPickerWndProc(Window *w, WindowEvent *e)
case WE_CLICK: {
switch (e->we.click.widget) {
case 7: case 8: case 9: case 10: case 11: case 12: case 13: case 14: case 15:
RaiseWindowWidget(w, _selected_airport_type + 7);
w->RaiseWidget(_selected_airport_type + 7);
_selected_airport_type = e->we.click.widget - 7;
LowerWindowWidget(w, _selected_airport_type + 7);
w->LowerWidget(_selected_airport_type + 7);
SndPlayFx(SND_15_BEEP);
SetWindowDirty(w);
break;
case 16: case 17:
_station_show_coverage = (e->we.click.widget != 16);
SetWindowWidgetLoweredState(w, 16, !_station_show_coverage);
SetWindowWidgetLoweredState(w, 17, _station_show_coverage);
w->SetWidgetLoweredState(16, !_station_show_coverage);
w->SetWidgetLoweredState(17, _station_show_coverage);
SndPlayFx(SND_15_BEEP);
SetWindowDirty(w);
break;

View File

@@ -17,7 +17,7 @@
uint CountArticulatedParts(EngineID engine_type, bool purchase_window)
{
if (!HASBIT(EngInfo(engine_type)->callbackmask, CBM_VEHICLE_ARTIC_ENGINE)) return 0;
if (!HasBit(EngInfo(engine_type)->callbackmask, CBM_VEHICLE_ARTIC_ENGINE)) return 0;
Vehicle *v = NULL;;
if (!purchase_window) {
@@ -41,7 +41,7 @@ void AddArticulatedParts(Vehicle **vl, VehicleType type)
const Vehicle *v = vl[0];
Vehicle *u = vl[0];
if (!HASBIT(EngInfo(v->engine_type)->callbackmask, CBM_VEHICLE_ARTIC_ENGINE)) return;
if (!HasBit(EngInfo(v->engine_type)->callbackmask, CBM_VEHICLE_ARTIC_ENGINE)) return;
for (uint i = 1; i < MAX_UVALUE(EngineID); i++) {
uint16 callback = GetVehicleCallback(CBID_VEHICLE_ARTIC_ENGINE, i, 0, v->engine_type, v);
@@ -56,7 +56,7 @@ void AddArticulatedParts(Vehicle **vl, VehicleType type)
u = u->Next();
EngineID engine_type = GetFirstEngineOfType(type) + GB(callback, 0, 7);
bool flip_image = HASBIT(callback, 7);
bool flip_image = HasBit(callback, 7);
/* get common values from first engine */
u->direction = v->direction;

View File

@@ -189,9 +189,9 @@ static CommandCost ReplaceVehicle(Vehicle **w, byte flags, Money total_cost)
}
}
if (new_v->type == VEH_TRAIN && HASBIT(old_v->u.rail.flags, VRF_REVERSE_DIRECTION) && !IsMultiheaded(new_v) && !(new_v->Next() != NULL && IsArticulatedPart(new_v->Next()))) {
if (new_v->type == VEH_TRAIN && HasBit(old_v->u.rail.flags, VRF_REVERSE_DIRECTION) && !IsMultiheaded(new_v) && !(new_v->Next() != NULL && IsArticulatedPart(new_v->Next()))) {
// we are autorenewing to a single engine, so we will turn it as the old one was turned as well
SETBIT(new_v->u.rail.flags, VRF_REVERSE_DIRECTION);
SetBit(new_v->u.rail.flags, VRF_REVERSE_DIRECTION);
}
if (old_v->type == VEH_TRAIN && !IsFrontEngine(old_v)) {

View File

@@ -164,7 +164,7 @@ static void GenerateReplaceVehList(Window *w, bool draw_left)
if (!EnginesGotCargoInCommon(e, WP(w, replaceveh_d).sel_engine[0])) continue; // the engines needs to be able to carry the same cargo
/* Road vehicles can't be replaced by trams and vice-versa */
if (type == VEH_ROAD && HASBIT(EngInfo(WP(w, replaceveh_d).sel_engine[0])->misc_flags, EF_ROAD_TRAM) != HASBIT(EngInfo(e)->misc_flags, EF_ROAD_TRAM)) continue;
if (type == VEH_ROAD && HasBit(EngInfo(WP(w, replaceveh_d).sel_engine[0])->misc_flags, EF_ROAD_TRAM) != HasBit(EngInfo(e)->misc_flags, EF_ROAD_TRAM)) continue;
if (e == WP(w, replaceveh_d).sel_engine[0]) continue; // we can't replace an engine into itself (that would be autorenew)
}
@@ -249,7 +249,7 @@ static void ReplaceVehicleWndProc(Window *w, WindowEvent *e)
* Either list is empty
* or The selected replacement engine has a replacement (to prevent loops)
* or The right list (new replacement) has the existing replacement vehicle selected */
SetWindowWidgetDisabledState(w, 4,
w->SetWidgetDisabledState(4,
selected_id[0] == INVALID_ENGINE ||
selected_id[1] == INVALID_ENGINE ||
EngineReplacementForPlayer(p, selected_id[1], selected_group) != INVALID_ENGINE ||
@@ -258,7 +258,7 @@ static void ReplaceVehicleWndProc(Window *w, WindowEvent *e)
/* Disable the "Stop Replacing" button if:
* The left list (existing vehicle) is empty
* or The selected vehicle has no replacement set up */
SetWindowWidgetDisabledState(w, 6,
w->SetWidgetDisabledState(6,
selected_id[0] == INVALID_ENGINE ||
!EngineHasReplacementForPlayer(p, selected_id[0], selected_group));

View File

@@ -41,7 +41,7 @@ protected:
if (name == NULL) return;
this->name = strdup(name);
#if !defined(NDEBUG)
#if !defined(NDEBUG) || defined(WITH_ASSERT)
/* NDEBUG disables asserts and gives a warning: unused variable 'P' */
std::pair<Blitters::iterator, bool> P =
#endif /* !NDEBUG */

View File

@@ -354,7 +354,7 @@ bool BmpReadBitmap(BmpBuffer *buffer, BmpInfo *info, BmpData *data)
{
assert(info != NULL && data != NULL);
data->bitmap = (byte*)calloc(info->width * info->height, ((info->bpp == 24) ? 3 : 1) * sizeof(byte));
data->bitmap = CallocT<byte>(info->width * info->height * ((info->bpp == 24) ? 3 : 1));
if (data->bitmap == NULL) return false;
/* Load image */

View File

@@ -18,12 +18,18 @@
#include "bridge.h"
static struct BridgeData {
uint8 last_size;
uint count;
TileIndex start_tile;
TileIndex end_tile;
byte type;
byte indexes[MAX_BRIDGES];
uint8 type;
uint8 indexes[MAX_BRIDGES];
Money costs[MAX_BRIDGES];
BridgeData()
: last_size(4)
, count(0)
{};
} _bridgedata;
void CcBuildBridge(bool success, TileIndex tile, uint32 p1, uint32 p2)
@@ -39,26 +45,52 @@ static void BuildBridge(Window *w, int i)
CMD_BUILD_BRIDGE | CMD_MSG(STR_5015_CAN_T_BUILD_BRIDGE_HERE));
}
/* Names of the build bridge selection window */
enum BuildBridgeSelectionWidgets {
BBSW_CLOSEBOX = 0,
BBSW_CAPTION,
BBSW_BRIDGE_LIST,
BBSW_SCROLLBAR,
BBSW_RESIZEBOX
};
static void BuildBridgeWndProc(Window *w, WindowEvent *e)
{
switch (e->event) {
case WE_PAINT:
case WE_CREATE:
w->resize.step_height = 22;
w->vscroll.count = _bridgedata.count;
if (_bridgedata.last_size <= 4) {
w->vscroll.cap = 4;
} else {
/* Resize the bridge selection window if we used a bigger one the last time */
w->vscroll.cap = (w->vscroll.count > _bridgedata.last_size) ? _bridgedata.last_size : w->vscroll.count;
ResizeWindow(w, 0, (w->vscroll.cap - 4) * w->resize.step_height);
w->widget[BBSW_BRIDGE_LIST].data = (w->vscroll.cap << 8) + 1;
}
break;
case WE_PAINT: {
DrawWindowWidgets(w);
for (uint i = 0; i < 4 && i + w->vscroll.pos < _bridgedata.count; i++) {
uint y = 15;
for (uint i = 0; (i < w->vscroll.cap) && ((i + w->vscroll.pos) < _bridgedata.count); i++) {
const Bridge *b = &_bridge[_bridgedata.indexes[i + w->vscroll.pos]];
SetDParam(2, _bridgedata.costs[i + w->vscroll.pos]);
SetDParam(1, b->speed * 10 / 16);
SetDParam(0, b->material);
DrawSprite(b->sprite, b->pal, 3, 15 + i * 22);
DrawString(44, 15 + i * 22 , STR_500D, TC_FROMSTRING);
DrawSprite(b->sprite, b->pal, 3, y);
DrawString(44, y, STR_500D, TC_FROMSTRING);
y += w->resize.step_height;
}
break;
}
case WE_KEYPRESS: {
uint i = e->we.keypress.keycode - '1';
const uint8 i = e->we.keypress.keycode - '1';
if (i < 9 && i < _bridgedata.count) {
e->we.keypress.cont = false;
BuildBridge(w, i);
@@ -68,44 +100,61 @@ static void BuildBridgeWndProc(Window *w, WindowEvent *e)
}
case WE_CLICK:
if (e->we.click.widget == 2) {
uint ind = ((int)e->we.click.pt.y - 14) / 22;
if (ind < 4 && (ind += w->vscroll.pos) < _bridgedata.count)
BuildBridge(w, ind);
if (e->we.click.widget == BBSW_BRIDGE_LIST) {
uint ind = ((int)e->we.click.pt.y - 14) / w->resize.step_height;
if (ind < w->vscroll.cap) {
ind += w->vscroll.pos;
if (ind < _bridgedata.count) {
BuildBridge(w, ind);
}
}
}
break;
case WE_RESIZE:
w->vscroll.cap += e->we.sizing.diff.y / (int)w->resize.step_height;
w->widget[BBSW_BRIDGE_LIST].data = (w->vscroll.cap << 8) + 1;
SetVScrollCount(w, _bridgedata.count);
_bridgedata.last_size = w->vscroll.cap;
break;
}
}
/* Widget definition for the rail bridge selection window */
static const Widget _build_bridge_widgets[] = {
{ WWT_CLOSEBOX, RESIZE_NONE, 7, 0, 10, 0, 13, STR_00C5, STR_018B_CLOSE_WINDOW},
{ WWT_CAPTION, RESIZE_NONE, 7, 11, 199, 0, 13, STR_100D_SELECT_RAIL_BRIDGE, STR_018C_WINDOW_TITLE_DRAG_THIS},
{ WWT_MATRIX, RESIZE_NONE, 7, 0, 187, 14, 101, 0x401, STR_101F_BRIDGE_SELECTION_CLICK},
{ WWT_SCROLLBAR, RESIZE_NONE, 7, 188, 199, 14, 101, 0x0, STR_0190_SCROLL_BAR_SCROLLS_LIST},
{ WWT_CLOSEBOX, RESIZE_NONE, 7, 0, 10, 0, 13, STR_00C5, STR_018B_CLOSE_WINDOW}, // BBSW_CLOSEBOX
{ WWT_CAPTION, RESIZE_NONE, 7, 11, 199, 0, 13, STR_100D_SELECT_RAIL_BRIDGE, STR_018C_WINDOW_TITLE_DRAG_THIS}, // BBSW_CAPTION
{ WWT_MATRIX, RESIZE_BOTTOM, 7, 0, 187, 14, 101, 0x401, STR_101F_BRIDGE_SELECTION_CLICK}, // BBSW_BRIDGE_LIST
{ WWT_SCROLLBAR, RESIZE_BOTTOM, 7, 188, 199, 14, 89, 0x0, STR_0190_SCROLL_BAR_SCROLLS_LIST}, // BBSW_SCROLLBAR
{ WWT_RESIZEBOX, RESIZE_TB, 7, 188, 199, 90, 101, 0x0, STR_RESIZE_BUTTON}, // BBSW_RESIZEBOX
{ WIDGETS_END},
};
/* Window definition for the rail bridge selection window */
static const WindowDesc _build_bridge_desc = {
WDP_AUTO, WDP_AUTO, 200, 102, 200, 102,
WC_BUILD_BRIDGE, WC_BUILD_TOOLBAR,
WDF_STD_TOOLTIPS | WDF_STD_BTN | WDF_DEF_WIDGET,
WDF_STD_TOOLTIPS | WDF_STD_BTN | WDF_DEF_WIDGET | WDF_RESIZABLE,
_build_bridge_widgets,
BuildBridgeWndProc
};
/* Widget definition for the road bridge selection window */
static const Widget _build_road_bridge_widgets[] = {
{ WWT_CLOSEBOX, RESIZE_NONE, 7, 0, 10, 0, 13, STR_00C5, STR_018B_CLOSE_WINDOW},
{ WWT_CAPTION, RESIZE_NONE, 7, 11, 199, 0, 13, STR_1803_SELECT_ROAD_BRIDGE, STR_018C_WINDOW_TITLE_DRAG_THIS},
{ WWT_MATRIX, RESIZE_NONE, 7, 0, 187, 14, 101, 0x401, STR_101F_BRIDGE_SELECTION_CLICK},
{ WWT_SCROLLBAR, RESIZE_NONE, 7, 188, 199, 14, 101, 0x0, STR_0190_SCROLL_BAR_SCROLLS_LIST},
{ WWT_CLOSEBOX, RESIZE_NONE, 7, 0, 10, 0, 13, STR_00C5, STR_018B_CLOSE_WINDOW}, // BBSW_CLOSEBOX
{ WWT_CAPTION, RESIZE_NONE, 7, 11, 199, 0, 13, STR_1803_SELECT_ROAD_BRIDGE, STR_018C_WINDOW_TITLE_DRAG_THIS}, // BBSW_CAPTION
{ WWT_MATRIX, RESIZE_BOTTOM, 7, 0, 187, 14, 101, 0x401, STR_101F_BRIDGE_SELECTION_CLICK}, // BBSW_BRIDGE_LIST
{ WWT_SCROLLBAR, RESIZE_BOTTOM, 7, 188, 199, 14, 89, 0x0, STR_0190_SCROLL_BAR_SCROLLS_LIST}, // BBSW_SCROLLBAR
{ WWT_RESIZEBOX, RESIZE_TB, 7, 188, 199, 90, 101, 0x0, STR_RESIZE_BUTTON}, // BBSW_RESIZEBOX
{ WIDGETS_END},
};
/* Window definition for the road bridge selection window */
static const WindowDesc _build_road_bridge_desc = {
WDP_AUTO, WDP_AUTO, 200, 102, 200, 102,
WC_BUILD_BRIDGE, WC_BUILD_TOOLBAR,
WDF_STD_TOOLTIPS | WDF_STD_BTN | WDF_DEF_WIDGET,
WDF_STD_TOOLTIPS | WDF_STD_BTN | WDF_DEF_WIDGET | WDF_RESIZABLE,
_build_road_bridge_widgets,
BuildBridgeWndProc
};
@@ -113,52 +162,46 @@ static const WindowDesc _build_road_bridge_desc = {
void ShowBuildBridgeWindow(TileIndex start, TileIndex end, byte bridge_type)
{
uint j = 0;
CommandCost ret;
StringID errmsg;
DeleteWindowById(WC_BUILD_BRIDGE, 0);
_bridgedata.type = bridge_type;
_bridgedata.start_tile = start;
_bridgedata.end_tile = end;
errmsg = INVALID_STRING_ID;
// only query bridge building possibility once, result is the same for all bridges!
// returns CMD_ERROR on failure, and price on success
ret = DoCommand(end, start, (bridge_type << 8), DC_AUTO | DC_QUERY_COST, CMD_BUILD_BRIDGE);
/* only query bridge building possibility once, result is the same for all bridges!
* returns CMD_ERROR on failure, and price on success */
StringID errmsg = INVALID_STRING_ID;
CommandCost ret = DoCommand(end, start, (bridge_type << 8), DC_AUTO | DC_QUERY_COST, CMD_BUILD_BRIDGE);
uint8 j = 0;
if (CmdFailed(ret)) {
errmsg = _error_message;
} else {
// check which bridges can be built
// get absolute bridge length
// length of the middle parts of the bridge
int bridge_len = GetBridgeLength(start, end);
// total length of bridge
int tot_bridgedata_len = bridge_len + 2;
/* check which bridges can be built
* get absolute bridge length
* length of the middle parts of the bridge */
const uint bridge_len = GetBridgeLength(start, end);
/* total length of bridge */
const uint tot_bridgedata_len = CalcBridgeLenCostFactor(bridge_len + 2);
tot_bridgedata_len = CalcBridgeLenCostFactor(tot_bridgedata_len);
for (bridge_type = 0; bridge_type != MAX_BRIDGES; bridge_type++) { // loop for all bridgetypes
/* loop for all bridgetypes */
for (bridge_type = 0; bridge_type != MAX_BRIDGES; bridge_type++) {
if (CheckBridge_Stuff(bridge_type, bridge_len)) {
/* bridge is accepted, add to list */
const Bridge *b = &_bridge[bridge_type];
// bridge is accepted, add to list
// add to terraforming & bulldozing costs the cost of the bridge itself (not computed with DC_QUERY_COST)
/* Add to terraforming & bulldozing costs the cost of the
* bridge itself (not computed with DC_QUERY_COST) */
_bridgedata.costs[j] = ret.GetCost() + (((int64)tot_bridgedata_len * _price.build_bridge * b->price) >> 8);
_bridgedata.indexes[j] = bridge_type;
j++;
}
}
_bridgedata.count = j;
}
_bridgedata.count = j;
if (j != 0) {
Window *w = AllocateWindowDesc((_bridgedata.type & 0x80) ? &_build_road_bridge_desc : &_build_bridge_desc);
w->vscroll.cap = 4;
w->vscroll.count = (byte)j;
AllocateWindowDesc((_bridgedata.type & 0x80) ? &_build_road_bridge_desc : &_build_bridge_desc);
} else {
ShowErrorMessage(errmsg, STR_5015_CAN_T_BUILD_BRIDGE_HERE, TileX(end) * TILE_SIZE, TileY(end) * TILE_SIZE);
}

View File

@@ -22,7 +22,7 @@
static inline bool IsBridge(TileIndex t)
{
assert(IsTileType(t, MP_TUNNELBRIDGE));
return HASBIT(_m[t].m5, 7);
return HasBit(_m[t].m5, 7);
}
/**
@@ -126,7 +126,7 @@ static inline TransportType GetBridgeTransportType(TileIndex t)
static inline bool HasBridgeSnowOrDesert(TileIndex t)
{
assert(IsBridgeTile(t));
return HASBIT(_m[t].m4, 7);
return HasBit(_m[t].m4, 7);
}
@@ -184,7 +184,7 @@ uint GetBridgeHeight(TileIndex tile);
static inline void ClearSingleBridgeMiddle(TileIndex t, Axis a)
{
assert(MayHaveBridgeAbove(t));
CLRBIT(_m[t].m6, 6 + a);
ClrBit(_m[t].m6, 6 + a);
}
@@ -208,7 +208,7 @@ static inline void ClearBridgeMiddle(TileIndex t)
static inline void SetBridgeMiddle(TileIndex t, Axis a)
{
assert(MayHaveBridgeAbove(t));
SETBIT(_m[t].m6, 6 + a);
SetBit(_m[t].m6, 6 + a);
}
/**

View File

@@ -722,7 +722,7 @@ static void GenerateBuildRoadVehList(Window *w)
for (eid = ROAD_ENGINES_INDEX; eid < ROAD_ENGINES_INDEX + NUM_ROAD_ENGINES; eid++) {
if (!IsEngineBuildable(eid, VEH_ROAD, _local_player)) continue;
if (!HASBIT(bv->filter.roadtypes, HASBIT(EngInfo(eid)->misc_flags, EF_ROAD_TRAM) ? ROADTYPE_TRAM : ROADTYPE_ROAD)) continue;
if (!HasBit(bv->filter.roadtypes, HasBit(EngInfo(eid)->misc_flags, EF_ROAD_TRAM) ? ROADTYPE_TRAM : ROADTYPE_ROAD)) continue;
EngList_Add(&bv->eng_list, eid);
if (eid == bv->sel_engine) sel_id = eid;
@@ -888,7 +888,7 @@ static void DrawBuildVehicleWindow(Window *w)
const buildvehicle_d *bv = &WP(w, buildvehicle_d);
uint max = min(w->vscroll.pos + w->vscroll.cap, EngList_Count(&bv->eng_list));
SetWindowWidgetDisabledState(w, BUILD_VEHICLE_WIDGET_BUILD, w->window_number <= VEH_END);
w->SetWidgetDisabledState(BUILD_VEHICLE_WIDGET_BUILD, w->window_number <= VEH_END);
SetVScrollCount(w, EngList_Count(&bv->eng_list));
SetDParam(0, bv->filter.railtype + STR_881C_NEW_RAIL_VEHICLES); // This should only affect rail vehicles

View File

@@ -37,7 +37,7 @@ void SetupCargoForClimate(LandscapeID l)
if (cl < lengthof(_default_cargo)) {
/* Copy the indexed cargo */
_cargo[i] = _default_cargo[cl];
SETBIT(_cargo_mask, i);
SetBit(_cargo_mask, i);
continue;
}
@@ -48,7 +48,7 @@ void SetupCargoForClimate(LandscapeID l)
_cargo[i] = _default_cargo[j];
/* Populate the available cargo mask */
SETBIT(_cargo_mask, i);
SetBit(_cargo_mask, i);
break;
}
}

View File

@@ -438,20 +438,19 @@ CommandCost CmdPurchaseLandArea(TileIndex tile, uint32 flags, uint32 p1, uint32
MarkTileDirtyByTile(tile);
}
return cost.AddCost(_price.purchase_land * 10);
return cost.AddCost(_price.clear_roughland * 10);
}
static CommandCost ClearTile_Clear(TileIndex tile, byte flags)
{
static const Money* clear_price_table[] = {
&_price.clear_1,
&_price.purchase_land,
&_price.clear_2,
&_price.clear_3,
&_price.purchase_land,
&_price.purchase_land,
&_price.clear_2, // XXX unused?
&_price.clear_grass,
&_price.clear_roughland,
&_price.clear_rocks,
&_price.clear_fields,
&_price.clear_roughland,
&_price.clear_roughland,
};
CommandCost price;
@@ -484,7 +483,7 @@ CommandCost CmdSellLandArea(TileIndex tile, uint32 flags, uint32 p1, uint32 p2)
if (flags & DC_EXEC) DoClearSquare(tile);
return CommandCost(- _price.purchase_land * 2);
return CommandCost(- _price.clear_roughland * 2);
}

View File

@@ -609,6 +609,9 @@ bool DoCommandP(TileIndex tile, uint32 p1, uint32 p2, CommandCallback *callback,
return true;
}
#endif /* ENABLE_NETWORK */
#ifdef DEBUG_DUMP_COMMANDS
debug_dump_commands("ddc:cmd:%d;%d;%d;%d;%d;%d;%d;%s\n", _date, _date_fract, (int)_current_player, tile, p1, p2, cmd, _cmd_text);
#endif /* DUMP_COMMANDS */
/* update last build coordinate of player. */
if (tile != 0 && IsValidPlayer(_current_player)) {

View File

@@ -305,12 +305,12 @@ void IConsoleSwitch()
w->height = _screen.height / 3;
w->width = _screen.width;
_iconsole_mode = ICONSOLE_OPENED;
SETBIT(_no_scroll, SCROLL_CON); // override cursor arrows; the gamefield will not scroll
SetBit(_no_scroll, SCROLL_CON); // override cursor arrows; the gamefield will not scroll
} break;
case ICONSOLE_OPENED: case ICONSOLE_FULL:
DeleteWindowById(WC_CONSOLE, 0);
_iconsole_mode = ICONSOLE_CLOSED;
CLRBIT(_no_scroll, SCROLL_CON);
ClrBit(_no_scroll, SCROLL_CON);
break;
}
@@ -356,7 +356,7 @@ static void IConsoleHistoryNavigate(int direction)
_iconsole_historypos = i;
IConsoleClearCommand();
/* copy history to 'command prompt / bash' */
assert(_iconsole_history[i] != NULL && IS_INT_INSIDE(i, 0, ICON_HISTORY_SIZE));
assert(_iconsole_history[i] != NULL && IsInsideMM(i, 0, ICON_HISTORY_SIZE));
ttd_strlcpy(_iconsole_cmdline.buf, _iconsole_history[i], _iconsole_cmdline.maxlength);
UpdateTextBufferSize(&_iconsole_cmdline);
}

View File

@@ -233,7 +233,7 @@ static const FiosItem* GetFiosItem(const char* file)
if (file == endptr || *endptr != '\0') i = -1;
}
return IS_INT_INSIDE(i, 0, _fios_num) ? &_fios_list[i] : NULL;
return IsInsideMM(i, 0, _fios_num) ? &_fios_list[i] : NULL;
}
@@ -1326,6 +1326,8 @@ DEF_CONSOLE_HOOK(ConHookRconPW)
return true;
}
extern void HashCurrentCompanyPassword();
/* Also use from within player_gui to change the password graphically */
bool NetworkChangeCompanyPassword(byte argc, char *argv[])
{
@@ -1346,8 +1348,11 @@ bool NetworkChangeCompanyPassword(byte argc, char *argv[])
ttd_strlcpy(_network_player_info[_local_player].password, argv[0], sizeof(_network_player_info[_local_player].password));
if (!_network_server)
if (!_network_server) {
SEND_COMMAND(PACKET_CLIENT_SET_PASSWORD)(_network_player_info[_local_player].password);
} else {
HashCurrentCompanyPassword();
}
IConsolePrintF(_icolour_warn, "'company_pw' changed to: %s", _network_player_info[_local_player].password);

71
src/core/bitmath_func.cpp Normal file
View File

@@ -0,0 +1,71 @@
/* $Id$ */
/** @file bitmath_func.cpp */
#include "../stdafx.h"
#include "bitmath_func.hpp"
const uint8 _ffb_64[64] = {
0, 0, 1, 0, 2, 0, 1, 0,
3, 0, 1, 0, 2, 0, 1, 0,
4, 0, 1, 0, 2, 0, 1, 0,
3, 0, 1, 0, 2, 0, 1, 0,
5, 0, 1, 0, 2, 0, 1, 0,
3, 0, 1, 0, 2, 0, 1, 0,
4, 0, 1, 0, 2, 0, 1, 0,
3, 0, 1, 0, 2, 0, 1, 0,
};
/**
* Search the first set bit in a 32 bit variable.
*
* This algorithm is a static implementation of a log
* conguence search algorithm. It checks the first half
* if there is a bit set search there further. And this
* way further. If no bit is set return 0.
*
* @param x The value to search
* @return The position of the first bit set
*/
uint8 FindFirstBit(uint32 x)
{
if (x == 0) return 0;
/* The macro FIND_FIRST_BIT is better to use when your x is
not more than 128. */
uint8 pos = 0;
if ((x & 0x0000ffff) == 0) { x >>= 16; pos += 16; }
if ((x & 0x000000ff) == 0) { x >>= 8; pos += 8; }
if ((x & 0x0000000f) == 0) { x >>= 4; pos += 4; }
if ((x & 0x00000003) == 0) { x >>= 2; pos += 2; }
if ((x & 0x00000001) == 0) { pos += 1; }
return pos;
}
/**
* Search the last set bit in a 32 bit variable.
*
* This algorithm is a static implementation of a log
* conguence search algorithm. It checks the second half
* if there is a bit set search there further. And this
* way further. If no bit is set return 0.
*
* @param x The value to search
* @return The position of the last bit set
*/
uint8 FindLastBit(uint32 x)
{
if (x == 0) return 0;
uint8 pos = 0;
if ((x & 0xffff0000) != 0) { x >>= 16; pos += 16; }
if ((x & 0x0000ff00) != 0) { x >>= 8; pos += 8; }
if ((x & 0x000000f0) != 0) { x >>= 4; pos += 4; }
if ((x & 0x0000000c) != 0) { x >>= 2; pos += 2; }
if ((x & 0x00000002) != 0) { pos += 1; }
return pos;
}

279
src/core/bitmath_func.hpp Normal file
View File

@@ -0,0 +1,279 @@
/* $Id$ */
/** @file bitmath_func.hpp */
#ifndef BITMATH_FUNC_HPP
#define BITMATH_FUNC_HPP
/**
* Fetch n bits from x, started at bit s.
*
* This function can be used to fetch n bits from the value x. The
* s value set the startposition to read. The startposition is
* count from the LSB and starts at 0. The result starts at a
* LSB, as this isn't just an and-bitmask but also some
* bit-shifting operations. GB(0xFF, 2, 1) will so
* return 0x01 (0000 0001) instead of
* 0x04 (0000 0100).
*
* @param x The value to read some bits.
* @param s The startposition to read some bits.
* @param n The number of bits to read.
* @return The selected bits, aligned to a LSB.
*/
template<typename T> static inline uint GB(const T x, const uint8 s, const uint8 n)
{
return (x >> s) & ((1U << n) - 1);
}
/** Set n bits from x starting at bit s to d
*
* This function sets n bits from x which started as bit s to the value of
* d. The parameters x, s and n works the same as the parameters of
* #GB. The result is saved in x again. Unused bits in the window
* provided by n are set to 0 if the value of b isn't "big" enough.
* This is not a bug, its a feature.
*
* @note Parameter x must be a variable as the result is saved there.
* @note To avoid unexpecting results the value of b should not use more
* space as the provided space of n bits (log2)
* @param x The variable to change some bits
* @param s The startposition for the new bits
* @param n The size/window for the new bits
* @param d The actually new bits to save in the defined position.
* @return The new value of x
*/
template<typename T, typename U> static inline T SB(T& x, const uint8 s, const uint8 n, const U d)
{
x &= (T)(~(((1U << n) - 1) << s));
x |= (T)(d << s);
return x;
}
/** Add i to n bits of x starting at bit s.
*
* This add the value of i on n bits of x starting at bit s. The parameters x,
* s, i are similar to #GB besides x must be a variable as the result are
* saved there. An overflow does not affect the following bits of the given
* bit window and is simply ignored.
*
* @note Parameter x must be a variable as the result is saved there.
* @param x The variable to add some bits at some position
* @param s The startposition of the addition
* @param n The size/window for the addition
* @param i The value to add at the given startposition in the given window.
* @return The new value of x
*/
template<typename T, typename U> static inline T AB(T& x, const uint8 s, const uint8 n, const U i)
{
const T mask = (T)(((1U << n) - 1) << s);
x = (T)((x & ~mask) | ((x + (i << s)) & mask));
return x;
}
/**
* Checks if a bit in a value is set.
*
* This function checks if a bit inside a value is set or not.
* The y value specific the position of the bit, started at the
* LSB and count from 0.
*
* @param x The value to check
* @param y The position of the bit to check, started from the LSB
* @return True if the bit is set, false else.
*/
template<typename T> static inline bool HasBit(const T x, const uint8 y)
{
return (x & ((T)1U << y)) != 0;
}
/**
* Check several bits in a value.
*
* This macro checks if a value contains at least one bit of an other
* value.
*
* @param x The first value
* @param y The second value
* @return True if at least one bit is set in both values, false else.
*/
#define HASBITS(x, y) ((x) & (y))
/**
* Set a bit in a variable.
*
* This function sets a bit in a variable. The variable is changed
* and the value is also returned. Parameter y defines the bit and
* starts at the LSB with 0.
*
* @param x The variable to set a bit
* @param y The bit position to set
* @return The new value of the old value with the bit set
*/
template<typename T> static inline T SetBit(T& x, const uint8 y)
{
return x = (T)(x | (T)(1U << y));
}
/**
* Sets several bits in a variable.
*
* This macro sets several bits in a variable. The bits to set are provided
* by a value. The new value is also returned.
*
* @param x The variable to set some bits
* @param y The value with set bits for setting them in the variable
* @return The new value of x
*/
#define SETBITS(x, y) ((x) |= (y))
/**
* Clears a bit in a variable.
*
* This function clears a bit in a variable. The variable is
* changed and the value is also returned. Parameter y defines the bit
* to clear and starts at the LSB with 0.
*
* @param x The variable to clear the bit
* @param y The bit position to clear
* @return The new value of the old value with the bit cleared
*/
template<typename T> static inline T ClrBit(T& x, const uint8 y)
{
return x = (T)(x & ~((T)1U << y));
}
/**
* Clears several bits in a variable.
*
* This macro clears several bits in a variable. The bits to clear are
* provided by a value. The new value is also returned.
*
* @param x The variable to clear some bits
* @param y The value with set bits for clearing them in the variable
* @return The new value of x
*/
#define CLRBITS(x, y) ((x) &= ~(y))
/**
* Toggles a bit in a variable.
*
* This function toggles a bit in a variable. The variable is
* changed and the value is also returned. Parameter y defines the bit
* to toggle and starts at the LSB with 0.
*
* @param x The varliable to toggle the bit
* @param y The bit position to toggle
* @return The new value of the old value with the bit toggled
*/
template<typename T> static inline T ToggleBit(T& x, const uint8 y)
{
return x = (T)(x ^ (T)(1U << y));
}
/** Lookup table to check which bit is set in a 6 bit variable */
extern const uint8 _ffb_64[64];
/**
* Returns the first occure of a bit in a 6-bit value (from right).
*
* Returns the position of the first bit that is not zero, counted from the
* LSB. Ie, 110100 returns 2, 000001 returns 0, etc. When x == 0 returns
* 0.
*
* @param x The 6-bit value to check the first zero-bit
* @return The first position of a bit started from the LSB or 0 if x is 0.
*/
#define FIND_FIRST_BIT(x) _ffb_64[(x)]
/**
* Finds the position of the first bit in an integer.
*
* This function returns the position of the first bit set in the
* integer. It does only check the bits of the bitmask
* 0x3F3F (0011111100111111) and checks only the
* bits of the bitmask 0x3F00 if and only if the
* lower part 0x00FF is 0. This results the bits at 0x00C0 must
* be also zero to check the bits at 0x3F00.
*
* @param value The value to check the first bits
* @return The position of the first bit which is set
* @see FIND_FIRST_BIT
*/
static inline uint8 FindFirstBit2x64(const int value)
{
if ((value & 0xFF) == 0) {
return FIND_FIRST_BIT((value >> 8) & 0x3F) + 8;
} else {
return FIND_FIRST_BIT(value & 0x3F);
}
}
uint8 FindFirstBit(uint32 x);
uint8 FindLastBit(uint32 x);
/**
* Clear the first bit in an integer.
*
* This function returns a value where the first bit (from LSB)
* is cleared.
* So, 110100 returns 110000, 000001 returns 000000, etc.
*
* @param value The value to clear the first bit
* @return The new value with the first bit cleared
*/
template<typename T> static inline T KillFirstBit(T value)
{
return value &= (T)(value - 1);
}
/**
* Counts the number of set bits in a variable.
*
* @param value the value to count the number of bits in.
* @return the number of bits.
*/
template<typename T> static inline uint CountBits(T value)
{
uint num;
/* This loop is only called once for every bit set by clearing the lowest
* bit in each loop. The number of bits is therefore equal to the number of
* times the loop was called. It was found at the following website:
* http://graphics.stanford.edu/~seander/bithacks.html */
for (num = 0; value != 0; num++) {
value &= (T)(value - 1);
}
return num;
}
/**
* ROtate x Left by n
*
* @note Assumes a byte has 8 bits
* @param x The value which we want to rotate
* @param n The number how many we waht to rotate
* @return A bit rotated number
*/
template<typename T> static inline T ROL(const T x, const uint8 n)
{
return (T)(x << n | x >> (sizeof(x) * 8 - n));
}
/**
* ROtate x Right by n
*
* @note Assumes a byte has 8 bits
* @param x The value which we want to rotate
* @param n The number how many we waht to rotate
* @return A bit rotated number
*/
template<typename T> static inline T ROR(const T x, const uint8 n)
{
return (T)(x >> n | x << (sizeof(x) * 8 - n));
}
#endif /* BITMATH_FUNC_HPP */

214
src/core/math_func.hpp Normal file
View File

@@ -0,0 +1,214 @@
/* $Id */
/** @file math_func.hpp */
#ifndef MATH_FUNC_HPP
#define MATH_FUNC_HPP
#ifdef min
#undef min
#endif
#ifdef max
#undef max
#endif
#ifdef abs
#undef abs
#endif
/**
* Returns the maximum of two values.
*
* This function returns the greater value of two given values.
* If they are equal the value of a is returned.
*
* @param a The first value
* @param b The second value
* @return The greater value or a if equals
*/
template<typename T> static inline T max(const T a, const T b)
{
return (a >= b) ? a : b;
}
/**
* Returns the minimum of two values.
*
* This function returns the smaller value of two given values.
* If they are equal the value of b is returned.
*
* @param a The first value
* @param b The second value
* @return The smaller value or b if equals
*/
template<typename T> static inline T min(const T a, const T b)
{
return (a < b) ? a : b;
}
/**
* Returns the minimum of two integer.
*
* This function returns the smaller value of two given integers.
*
* @param a The first integer
* @param b The second integer
* @return The smaller value
*/
static inline int min(const int a, const int b)
{
return (a < b) ? a : b;
}
/**
* Returns the minimum of two unsigned integers.
*
* This function returns the smaller value of two given unsigned integers.
*
* @param a The first unsigned integer
* @param b The second unsigned integer
* @return The smaller value
*/
static inline uint minu(const uint a, const uint b)
{
return (a < b) ? a : b;
}
/**
* Returns the absolute value of (scalar) variable.
*
* @note assumes variable to be signed
* @param a The value we want to unsign
* @return The unsigned value
*/
template <typename T> static inline T abs(const T a)
{
return (a < (T)0) ? -a : a;
}
/**
* Return the smallest multiple of n equal or greater than x
*
* @note n must be a power of 2
* @param x The min value
* @param n The base of the number we are searching
* @return The smallest multiple of n equal or greater than x
*/
template<typename T> static inline T Align(const T x, uint n)
{
n--;
return (T)((x + n) & ~(n));
}
/**
* Clamp an integer between an interval.
*
* This function returns a value which is between the given interval of
* min and max. If the given value is in this interval the value itself
* is returned otherwise the border of the interval is returned, according
* which side of the interval was 'left'.
*
* @note The min value must be less or equal of max or you get some
* unexpected results.
* @param a The value to clamp/truncate.
* @param min The minimum of the interval.
* @param max the maximum of the interval.
* @returns A value between min and max which is closest to a.
* @see ClampU(uint, uint, uint)
*/
static inline int Clamp(const int a, const int min, const int max)
{
if (a <= min) return min;
if (a >= max) return max;
return a;
}
/**
* Clamp an unsigned integer between an interval.
*
* This function returns a value which is between the given interval of
* min and max. If the given value is in this interval the value itself
* is returned otherwise the border of the interval is returned, according
* which side of the interval was 'left'.
*
* @note The min value must be less or equal of max or you get some
* unexpected results.
* @param a The value to clamp/truncate.
* @param min The minimum of the interval.
* @param max the maximum of the interval.
* @returns A value between min and max which is closest to a.
* @see Clamp(int, int, int)
*/
static inline uint ClampU(const uint a, const uint min, const uint max)
{
if (a <= min) return min;
if (a >= max) return max;
return a;
}
/**
* Reduce a signed 64-bit int to a signed 32-bit one
*
* This function clamps a 64-bit integer to a 32-bit integer.
* If the 64-bit value is smaller than the smallest 32-bit integer
* value 0x80000000 this value is returned (the left one bit is the sign bit).
* If the 64-bit value is greater than the greatest 32-bit integer value 0x7FFFFFFF
* this value is returned. In all other cases the 64-bit value 'fits' in a
* 32-bits integer field and so the value is casted to int32 and returned.
*
* @param a The 64-bit value to clamps
* @return The 64-bit value reduced to a 32-bit value
* @see Clamp(int, int, int)
*/
static inline int32 ClampToI32(const int64 a)
{
if (a <= (int32)0x80000000) return 0x80000000;
if (a >= (int32)0x7FFFFFFF) return 0x7FFFFFFF;
return (int32)a;
}
/**
* Returns the (absolute) difference between two (scalar) variables
*
* @param a The first scalar
* @param b The second scalar
* @return The absolute difference between the given scalars
*/
template <typename T> static inline T Delta(const T a, const T b) {
return (a < b) ? b - a : a - b;
}
/**
* Checks if a value is between a window started at some base point.
*
* This function checks if the value x is between the value of base
* and base+size. If x equals base this returns true. If x equals
* base+size this returns false.
*
* @param x The value to check
* @param base The base value of the interval
* @param size The size of the interval
* @return True if the value is in the interval, false else.
*/
template<typename T> static inline bool IsInsideBS(const T x, const uint base, const uint size)
{
return (uint)(x - base) < size;
}
/**
* Checks if a value is in an interval.
*
* Returns true if a value is in the interval of [min, max).
*
* @param a The value to check
* @param min The minimum of the interval
* @param max The maximum of the interval
* @see IsInsideBS()
*/
template<typename T> static inline bool IsInsideMM(const T x, const uint min, const uint max)
{
return (uint)(x - min) < (max - min);
}
#endif /* MATH_FUNC_HPP */

155
src/core/random_func.cpp Normal file
View File

@@ -0,0 +1,155 @@
/* $Id$ */
/** @file random_func.cpp */
#include "../stdafx.h"
#include "../macros.h"
#include "../variables.h"
#include "random_func.hpp"
uint32 InteractiveRandom()
{
const uint32 s = _random_seeds[1][0];
const uint32 t = _random_seeds[1][1];
_random_seeds[1][0] = s + ROR(t ^ 0x1234567F, 7) + 1;
return _random_seeds[1][1] = ROR(s, 3) - 1;
}
uint InteractiveRandomRange(uint max)
{
return GB(InteractiveRandom(), 0, 16) * max >> 16;
}
#ifdef MERSENNE_TWISTER
// Source code for Mersenne Twister.
// A Random number generator with much higher quality random numbers.
#define N (624) // length of _mt_state vector
#define M (397) // a period parameter
#define K (0x9908B0DFU) // a magic constant
#define hiBit(u) ((u) & 0x80000000U) // mask all but highest bit of u
#define loBit(u) ((u) & 0x00000001U) // mask all but lowest bit of u
#define loBits(u) ((u) & 0x7FFFFFFFU) // mask the highest bit of u
#define mixBits(u, v) (hiBit(u)|loBits(v)) // move hi bit of u to hi bit of v
static uint32 _mt_state[N+1]; // _mt_state vector + 1 extra to not violate ANSI C
static uint32 *_mt_next; // _mt_next random value is computed from here
static int _mt_left = -1; // can *_mt_next++ this many times before reloading
void SetRandomSeed(register uint32 seed)
{
register uint32 *s = _mt_state;
_mt_left = 0;
seed |= 1U;
seed &= 0xFFFFFFFFU;
*s = seed;
for (register uint i = N; i != 0; i--) {
seed *= 69069U;
*s++;
*s = seed & 0xFFFFFFFFU;
}
}
static uint32 ReloadRandom()
{
if (_mt_left < -1) SetRandomSeed(4357U);
_mt_left = N - 1;
_mt_next = _mt_state + 1;
register uint32 *p0 = _mt_state;
register uint32 *p2 = _mt_state + 2;
register uint32 *pM = _mt_state + M;
register uint32 s0 = _mt_state[0];
register uint32 s1 = _mt_state[1];
register uint i = 0;
for (i = (N - M + 1); i != 0; i--) {
s0 = s1;
s1 = *p2;
*p0 = *pM ^ (mixBits(s0, s1) >> 1) ^ (loBit(s1) ? K : 0U);
*p0++;
*p2++;
*pM++;
}
pM = _mt_state;
for (i = M; i != 0; i--) {
s0 = s1;
s1 = *p2;
*p0 = *pM ^ (mixBits(s0, s1) >> 1) ^ (loBit(s1) ? K : 0U);
*p0++;
*p2++;
*pM++;
}
s1 = _mt_state[0];
*p0 = *pM ^ (mixBits(s0, s1) >> 1) ^ (loBit(s1) ? K : 0U);
s1 ^= (s1 >> 11);
s1 ^= (s1 << 7) & 0x9D2C5680U;
s1 ^= (s1 << 15) & 0xEFC60000U;
s1 ^= (s1 >> 18);
return s1;
}
uint32 Random()
{
_mt_left--;
if (_mt_left < 0) return ReloadRandom();
uint32 y = *_mt_next;
*_mt_next++;
y ^= (y >> 11);
y ^= (y << 7) & 0x9D2C5680U;
y ^= (y << 15) & 0xEFC60000U;
y ^= (y >> 18);
return y;
}
#else /* MERSENNE_TWISTER */
void SetRandomSeed(uint32 seed)
{
_random_seeds[0][0] = seed;
_random_seeds[0][1] = seed;
_random_seeds[1][0] = seed * 0x1234567;
_random_seeds[1][1] = _random_seeds[1][0];
}
#ifdef RANDOM_DEBUG
#include "network/network_data.h"
uint32 DoRandom(int line, const char *file)
{
if (_networking && (DEREF_CLIENT(0)->status != STATUS_INACTIVE || !_network_server))
printf("Random [%d/%d] %s:%d\n",_frame_counter, (byte)_current_player, file, line);
#else /* RANDOM_DEBUG */
uint32 Random()
{
#endif /* RANDOM_DEBUG */
const uint32 s = _random_seeds[0][0];
const uint32 t = _random_seeds[0][1];
_random_seeds[0][0] = s + ROR(t ^ 0x1234567F, 7) + 1;
return _random_seeds[0][1] = ROR(s, 3) - 1;
}
#endif /* MERSENNE_TWISTER */
#if defined(RANDOM_DEBUG) && !defined(MERSENNE_TWISTER)
uint DoRandomRange(uint max, int line, const char *file)
{
return GB(DoRandom(line, file), 0, 16) * max >> 16;
}
#else /* RANDOM_DEBUG & !MERSENNE_TWISTER */
uint RandomRange(uint max)
{
return GB(Random(), 0, 16) * max >> 16;
}
#endif /* RANDOM_DEBUG & !MERSENNE_TWISTER */

98
src/core/random_func.hpp Normal file
View File

@@ -0,0 +1,98 @@
/* $Id$ */
/** @file random_func.h */
#ifndef RANDOM_FUNC_HPP
#define RANDOM_FUNC_HPP
/**************
* Warning: DO NOT enable this unless you understand what it does
*
* If enabled, in a network game all randoms will be dumped to the
* stdout if the first client joins (or if you are a client). This
* is to help finding desync problems.
*
* Warning: DO NOT enable this unless you understand what it does
**************/
//#define RANDOM_DEBUG
// Enable this to produce higher quality random numbers.
// Doesn't work with network yet.
// #define MERSENNE_TWISTER
void SetRandomSeed(uint32 seed);
#ifdef RANDOM_DEBUG
#define Random() DoRandom(__LINE__, __FILE__)
uint32 DoRandom(int line, const char *file);
#define RandomRange(max) DoRandomRange(max, __LINE__, __FILE__)
uint DoRandomRange(uint max, int line, const char *file);
#else
uint32 Random();
uint RandomRange(uint max);
#endif
uint32 InteractiveRandom(); // Used for random sequences that are not the same on the other end of the multiplayer link
uint InteractiveRandomRange(uint max);
/**
* Checks if a given randomize-number is below a given probability.
*
* This function is used to check if the given probability by the fraction of (a/b)
* is greater than low 16 bits of the given randomize-number v.
*
* Do not use this function twice on the same random 16 bits as it will yield
* the same result. One can use a random number for two calls to Chance16I,
* where one call sends the low 16 bits and the other the high 16 bits.
*
* @param a The numerator of the fraction
* @param b The denominator of the fraction, must of course not be null
* @param r The given randomize-number
* @return True if v is less or equals (a/b)
*/
static inline bool Chance16I(const uint a, const uint b, const uint32 r)
{
assert(b != 0);
return (uint16)r < (uint16)((a << 16) / b);
}
/**
* Flips a coin with a given probability.
*
* This macro can be used to get true or false randomized according to a
* given probability. The parameter a and b create a percent value with
* (a/b). The macro returns true in (a/b) percent.
*
* @see Chance16I()
* @param a The numerator of the fraction
* @param b The denominator of the fraction
* @return True in (a/b) percent
*/
static inline bool Chance16(const uint a, const uint b)
{
return Chance16I(a, b, Random());
}
/**
* Flips a coin with a given probability and saves the randomize-number in a variable.
*
* This function uses the same parameters as Chance16. The third parameter
* must be a variable the randomize-number from Random() is saved in.
*
* The low 16 bits of r will already be used and can therefor not be passed to
* Chance16I. One can only send the high 16 bits to Chance16I.
*
* @see Chance16I()
* @param a The numerator of the fraction
* @param b The denominator of the fraction
* @param r The variable to save the randomize-number from Random()
* @return True in (a/b) percent
*/
static inline bool Chance16R(const uint a, const uint b, uint32 &r)
{
r = Random();
return Chance16I(a, b, r);
}
#endif /* RANDOM_FUNC_HPP */

View File

@@ -51,7 +51,7 @@ void ShowDepotWindow(TileIndex tile, VehicleType type);
*/
static inline Date GetServiceIntervalClamped(uint index)
{
return (_patches.servint_ispercent) ? clamp(index, MIN_SERVINT_PERCENT, MAX_SERVINT_PERCENT) : clamp(index, MIN_SERVINT_DAYS, MAX_SERVINT_DAYS);
return (_patches.servint_ispercent) ? Clamp(index, MIN_SERVINT_PERCENT, MAX_SERVINT_PERCENT) : Clamp(index, MIN_SERVINT_DAYS, MAX_SERVINT_DAYS);
}
/**

View File

@@ -216,7 +216,7 @@ static void DrawDepotWindow(Window *w)
uint16 boxes_in_each_row = w->widget[DEPOT_WIDGET_MATRIX].data & 0xFF;
/* setup disabled buttons */
SetWindowWidgetsDisabledState(w, !IsTileOwner(tile, _local_player),
w->SetWidgetsDisabledState(!IsTileOwner(tile, _local_player),
DEPOT_WIDGET_STOP_ALL,
DEPOT_WIDGET_START_ALL,
DEPOT_WIDGET_SELL,
@@ -290,14 +290,14 @@ struct GetDepotVehiclePtData {
Vehicle *wagon;
};
enum {
MODE_ERROR = 1,
MODE_DRAG_VEHICLE = 0,
MODE_SHOW_VEHICLE = -1,
MODE_START_STOP = -2,
enum DepotGUIAction {
MODE_ERROR,
MODE_DRAG_VEHICLE,
MODE_SHOW_VEHICLE,
MODE_START_STOP,
};
static int GetVehicleFromDepotWndPt(const Window *w, int x, int y, Vehicle **veh, GetDepotVehiclePtData *d)
static DepotGUIAction GetVehicleFromDepotWndPt(const Window *w, int x, int y, Vehicle **veh, GetDepotVehiclePtData *d)
{
Vehicle **vl = WP(w, depot_d).vehicle_list;
uint xt, row, xm = 0, ym = 0;
@@ -411,10 +411,10 @@ static void DepotClick(Window *w, int x, int y)
{
GetDepotVehiclePtData gdvp;
Vehicle *v = NULL;
int mode = GetVehicleFromDepotWndPt(w, x, y, &v, &gdvp);
DepotGUIAction mode = GetVehicleFromDepotWndPt(w, x, y, &v, &gdvp);
/* share / copy orders */
if (_thd.place_mode && mode <= 0) {
if (_thd.place_mode != VHM_NONE && mode != MODE_ERROR) {
_place_clicked_vehicle = (WP(w, depot_d).type == VEH_TRAIN ? gdvp.head : v);
return;
}
@@ -724,7 +724,7 @@ static void CreateDepotListWindow(Window *w, VehicleType type)
+ (type == VEH_TRAIN ? 1 : w->hscroll.cap); // number of boxes in each row. Trains always have just one
SetWindowWidgetsHiddenState(w, type != VEH_TRAIN,
w->SetWidgetsHiddenState(type != VEH_TRAIN,
DEPOT_WIDGET_H_SCROLL,
DEPOT_WIDGET_SELL_CHAIN,
WIDGET_LIST_END);
@@ -794,10 +794,10 @@ static void DepotWndProc(Window *w, WindowEvent *e)
break;
case DEPOT_WIDGET_CLONE: // Clone button
InvalidateWidget(w, DEPOT_WIDGET_CLONE);
ToggleWidgetLoweredState(w, DEPOT_WIDGET_CLONE);
w->InvalidateWidget(DEPOT_WIDGET_CLONE);
w->ToggleWidgetLoweredState(DEPOT_WIDGET_CLONE);
if (IsWindowWidgetLowered(w, DEPOT_WIDGET_CLONE)) {
if (w->IsWidgetLowered(DEPOT_WIDGET_CLONE)) {
static const CursorID clone_icons[] = {
SPR_CURSOR_CLONE_TRAIN, SPR_CURSOR_CLONE_ROADVEH,
SPR_CURSOR_CLONE_SHIP, SPR_CURSOR_CLONE_AIRPLANE
@@ -855,8 +855,8 @@ static void DepotWndProc(Window *w, WindowEvent *e)
} break;
case WE_ABORT_PLACE_OBJ: {
RaiseWindowWidget(w, DEPOT_WIDGET_CLONE);
InvalidateWidget(w, DEPOT_WIDGET_CLONE);
w->RaiseWidget(DEPOT_WIDGET_CLONE);
w->InvalidateWidget(DEPOT_WIDGET_CLONE);
} break;
/* check if a vehicle in a depot was clicked.. */
@@ -864,7 +864,7 @@ static void DepotWndProc(Window *w, WindowEvent *e)
const Vehicle *v = _place_clicked_vehicle;
/* since OTTD checks all open depot windows, we will make sure that it triggers the one with a clicked clone button */
if (v != NULL && IsWindowWidgetLowered(w, DEPOT_WIDGET_CLONE)) {
if (v != NULL && w->IsWidgetLowered(DEPOT_WIDGET_CLONE)) {
_place_clicked_vehicle = NULL;
HandleCloneVehClick(v, w);
}
@@ -906,17 +906,17 @@ static void DepotWndProc(Window *w, WindowEvent *e)
} break;
case DEPOT_WIDGET_SELL: case DEPOT_WIDGET_SELL_CHAIN:
if (!IsWindowWidgetDisabled(w, DEPOT_WIDGET_SELL) &&
if (!w->IsWidgetDisabled(DEPOT_WIDGET_SELL) &&
WP(w, depot_d).sel != INVALID_VEHICLE) {
Vehicle *v;
uint command;
int sell_cmd;
bool is_engine;
if (IsWindowWidgetDisabled(w, e->we.click.widget)) return;
if (w->IsWidgetDisabled(e->we.click.widget)) return;
if (WP(w, depot_d).sel == INVALID_VEHICLE) return;
HandleButtonClick(w, e->we.click.widget);
w->HandleButtonClick(e->we.click.widget);
v = GetVehicle(WP(w, depot_d).sel);
WP(w, depot_d).sel = INVALID_VEHICLE;

View File

@@ -159,13 +159,13 @@ static void SetDisasterVehiclePos(Vehicle *v, int x, int y, byte z)
EndVehicleMove(v);
if ((u = v->Next()) != NULL) {
int safe_x = clamp(x, 0, MapMaxX() * TILE_SIZE);
int safe_y = clamp(y - 1, 0, MapMaxY() * TILE_SIZE);
int safe_x = Clamp(x, 0, MapMaxX() * TILE_SIZE);
int safe_y = Clamp(y - 1, 0, MapMaxY() * TILE_SIZE);
BeginVehicleMove(u);
u->x_pos = x;
u->y_pos = y - 1 - (max(z - GetSlopeZ(safe_x, safe_y), 0U) >> 3);
safe_y = clamp(u->y_pos, 0, MapMaxY() * TILE_SIZE);
safe_y = Clamp(u->y_pos, 0, MapMaxY() * TILE_SIZE);
u->z_pos = GetSlopeZ(safe_x, safe_y);
u->direction = v->direction;
@@ -202,7 +202,7 @@ static void DisasterTick_Zeppeliner(Vehicle *v)
v->tick_counter++;
if (v->current_order.dest < 2) {
if (HASBIT(v->tick_counter, 0)) return;
if (HasBit(v->tick_counter, 0)) return;
GetNewVehiclePosResult gp = GetNewVehiclePos(v);
@@ -305,13 +305,13 @@ static void DisasterTick_Ufo(Vehicle *v)
uint dist;
byte z;
v->u.disaster.image_override = (HASBIT(++v->tick_counter, 3)) ? SPR_UFO_SMALL_SCOUT_DARKER : SPR_UFO_SMALL_SCOUT;
v->u.disaster.image_override = (HasBit(++v->tick_counter, 3)) ? SPR_UFO_SMALL_SCOUT_DARKER : SPR_UFO_SMALL_SCOUT;
if (v->current_order.dest == 0) {
/* Fly around randomly */
int x = TileX(v->dest_tile) * TILE_SIZE;
int y = TileY(v->dest_tile) * TILE_SIZE;
if (delta(x, v->x_pos) + delta(y, v->y_pos) >= TILE_SIZE) {
if (Delta(x, v->x_pos) + Delta(y, v->y_pos) >= TILE_SIZE) {
v->direction = GetDirectionTowards(v, x, y);
GetNewVehiclePosResult gp = GetNewVehiclePos(v);
SetDisasterVehiclePos(v, gp.x, gp.y, v->z_pos);
@@ -340,7 +340,7 @@ static void DisasterTick_Ufo(Vehicle *v)
return;
}
dist = delta(v->x_pos, u->x_pos) + delta(v->y_pos, u->y_pos);
dist = Delta(v->x_pos, u->x_pos) + Delta(v->y_pos, u->y_pos);
if (dist < TILE_SIZE && !(u->vehstatus & VS_HIDDEN) && u->breakdown_ctr == 0) {
u->breakdown_ctr = 3;
@@ -400,7 +400,7 @@ static void DisasterTick_Airplane(Vehicle *v)
{
v->tick_counter++;
v->u.disaster.image_override =
(v->current_order.dest == 1 && HASBIT(v->tick_counter, 2)) ? SPR_F_15_FIRING : 0;
(v->current_order.dest == 1 && HasBit(v->tick_counter, 2)) ? SPR_F_15_FIRING : 0;
GetNewVehiclePosResult gp = GetNewVehiclePos(v);
SetDisasterVehiclePos(v, gp.x, gp.y, v->z_pos);
@@ -473,7 +473,7 @@ static void DisasterTick_Helicopter(Vehicle *v)
{
v->tick_counter++;
v->u.disaster.image_override =
(v->current_order.dest == 1 && HASBIT(v->tick_counter, 2)) ? SPR_AH_64A_FIRING : 0;
(v->current_order.dest == 1 && HasBit(v->tick_counter, 2)) ? SPR_AH_64A_FIRING : 0;
GetNewVehiclePosResult gp = GetNewVehiclePos(v);
SetDisasterVehiclePos(v, gp.x, gp.y, v->z_pos);
@@ -539,7 +539,7 @@ static void DisasterTick_Helicopter(Vehicle *v)
static void DisasterTick_Helicopter_Rotors(Vehicle *v)
{
v->tick_counter++;
if (HASBIT(v->tick_counter, 0)) return;
if (HasBit(v->tick_counter, 0)) return;
if (++v->cur_image > SPR_ROTOR_MOVING_3) v->cur_image = SPR_ROTOR_MOVING_1;
@@ -567,7 +567,7 @@ static void DisasterTick_Big_Ufo(Vehicle *v)
if (v->current_order.dest == 1) {
int x = TileX(v->dest_tile) * TILE_SIZE + TILE_SIZE / 2;
int y = TileY(v->dest_tile) * TILE_SIZE + TILE_SIZE / 2;
if (delta(v->x_pos, x) + delta(v->y_pos, y) >= 8) {
if (Delta(v->x_pos, x) + Delta(v->y_pos, y) >= 8) {
v->direction = GetDirectionTowards(v, x, y);
GetNewVehiclePosResult gp = GetNewVehiclePos(v);
@@ -585,7 +585,7 @@ static void DisasterTick_Big_Ufo(Vehicle *v)
FOR_ALL_VEHICLES(u) {
if (u->type == VEH_TRAIN || u->type == VEH_ROAD) {
if (delta(u->x_pos, v->x_pos) + delta(u->y_pos, v->y_pos) <= 12 * TILE_SIZE) {
if (Delta(u->x_pos, v->x_pos) + Delta(u->y_pos, v->y_pos) <= 12 * TILE_SIZE) {
u->breakdown_ctr = 5;
u->breakdown_delay = 0xF0;
}
@@ -617,7 +617,7 @@ static void DisasterTick_Big_Ufo(Vehicle *v)
} else if (v->current_order.dest == 0) {
int x = TileX(v->dest_tile) * TILE_SIZE;
int y = TileY(v->dest_tile) * TILE_SIZE;
if (delta(x, v->x_pos) + delta(y, v->y_pos) >= TILE_SIZE) {
if (Delta(x, v->x_pos) + Delta(y, v->y_pos) >= TILE_SIZE) {
v->direction = GetDirectionTowards(v, x, y);
GetNewVehiclePosResult gp = GetNewVehiclePos(v);
SetDisasterVehiclePos(v, gp.x, gp.y, v->z_pos);
@@ -667,7 +667,7 @@ static void DisasterTick_Big_Ufo_Destroyer(Vehicle *v)
if (v->current_order.dest == 0) {
u = GetVehicle(v->u.disaster.big_ufo_destroyer_target);
if (delta(v->x_pos, u->x_pos) > TILE_SIZE) return;
if (Delta(v->x_pos, u->x_pos) > TILE_SIZE) return;
v->current_order.dest = 1;
CreateEffectVehicleRel(u, 0, 7, 8, EV_EXPLOSION_LARGE);
@@ -709,13 +709,13 @@ static void DisasterTick_Submarine(Vehicle *v)
return;
}
if (!HASBIT(v->tick_counter, 0)) return;
if (!HasBit(v->tick_counter, 0)) return;
tile = v->tile + TileOffsByDiagDir(DirToDiagDir(v->direction));
if (IsValidTile(tile)) {
TrackdirBits r = (TrackdirBits)GetTileTrackStatus(tile, TRANSPORT_WATER, 0);
if (TrackdirBitsToTrackBits(r) == TRACK_BIT_ALL && !CHANCE16(1, 90)) {
if (TrackdirBitsToTrackBits(r) == TRACK_BIT_ALL && !Chance16(1, 90)) {
GetNewVehiclePosResult gp = GetNewVehiclePos(v);
SetDisasterVehiclePos(v, gp.x, gp.y, v->z_pos);
return;
@@ -825,7 +825,7 @@ static void Disaster_Airplane_Init()
FOR_ALL_INDUSTRIES(i) {
if ((GetIndustrySpec(i->type)->behaviour & INDUSTRYBEH_AIRPLANE_ATTACKS) &&
(found == NULL || CHANCE16(1, 2))) {
(found == NULL || Chance16(1, 2))) {
found = i;
}
}
@@ -861,7 +861,7 @@ static void Disaster_Helicopter_Init()
FOR_ALL_INDUSTRIES(i) {
if ((GetIndustrySpec(i->type)->behaviour & INDUSTRYBEH_CHOPPER_ATTACKS) &&
(found == NULL || CHANCE16(1, 2))) {
(found == NULL || Chance16(1, 2))) {
found = i;
}
}
@@ -930,7 +930,7 @@ static void Disaster_Small_Submarine_Init()
r = Random();
x = TileX(r) * TILE_SIZE + TILE_SIZE / 2;
if (HASBIT(r, 31)) {
if (HasBit(r, 31)) {
y = MapMaxX() * TILE_SIZE - TILE_SIZE / 2 - 1;
dir = DIR_NW;
} else {
@@ -955,7 +955,7 @@ static void Disaster_Big_Submarine_Init()
r = Random();
x = TileX(r) * TILE_SIZE + TILE_SIZE / 2;
if (HASBIT(r, 31)) {
if (HasBit(r, 31)) {
y = MapMaxX() * TILE_SIZE - TILE_SIZE / 2 - 1;
dir = DIR_NW;
} else {

View File

@@ -16,6 +16,7 @@
#include "sound.h"
#include "command.h"
#include "variables.h"
#include "water.h"
static void ShowBuildDockStationPicker();
static void ShowBuildDocksDepotPicker();
@@ -127,7 +128,7 @@ static void BuildDocksToolbWndProc(Window *w, WindowEvent *e)
switch (e->event) {
case WE_PAINT:
DrawWindowWidgets(w);
SetWindowWidgetsDisabledState(w, !CanBuildVehicleInfrastructure(VEH_SHIP), 7, 8, 9, WIDGET_LIST_END);
w->SetWidgetsDisabledState(!CanBuildVehicleInfrastructure(VEH_SHIP), 7, 8, 9, WIDGET_LIST_END);
break;
case WE_CLICK:
@@ -170,7 +171,7 @@ static void BuildDocksToolbWndProc(Window *w, WindowEvent *e)
break;
case WE_ABORT_PLACE_OBJ:
RaiseWindowButtons(w);
w->RaiseButtons();
w = FindWindowById(WC_BUILD_STATION, 0);
if (w != NULL) WP(w, def_d).close = true;
@@ -236,7 +237,7 @@ void ShowBuildDocksToolbar()
static void BuildDockStationWndProc(Window *w, WindowEvent *e)
{
switch (e->event) {
case WE_CREATE: LowerWindowWidget(w, _station_show_coverage + 3); break;
case WE_CREATE: w->LowerWidget(_station_show_coverage + 3); break;
case WE_PAINT: {
int rad = (_patches.modified_catchment) ? CA_DOCK : 4;
@@ -258,9 +259,9 @@ static void BuildDockStationWndProc(Window *w, WindowEvent *e)
switch (e->we.click.widget) {
case 3:
case 4:
RaiseWindowWidget(w, _station_show_coverage + 3);
w->RaiseWidget(_station_show_coverage + 3);
_station_show_coverage = (e->we.click.widget != 3);
LowerWindowWidget(w, _station_show_coverage + 3);
w->LowerWidget(_station_show_coverage + 3);
SndPlayFx(SND_15_BEEP);
SetWindowDirty(w);
break;
@@ -317,7 +318,7 @@ static void UpdateDocksDirection()
static void BuildDocksDepotWndProc(Window *w, WindowEvent *e)
{
switch (e->event) {
case WE_CREATE: LowerWindowWidget(w, _ship_depot_direction + 3); break;
case WE_CREATE: w->LowerWidget(_ship_depot_direction + 3); break;
case WE_PAINT:
DrawWindowWidgets(w);
@@ -332,9 +333,9 @@ static void BuildDocksDepotWndProc(Window *w, WindowEvent *e)
switch (e->we.click.widget) {
case 3:
case 4:
RaiseWindowWidget(w, _ship_depot_direction + 3);
w->RaiseWidget(_ship_depot_direction + 3);
_ship_depot_direction = (e->we.click.widget == 3 ? AXIS_X : AXIS_Y);
LowerWindowWidget(w, _ship_depot_direction + 3);
w->LowerWidget(_ship_depot_direction + 3);
SndPlayFx(SND_15_BEEP);
UpdateDocksDirection();
SetWindowDirty(w);

View File

@@ -79,7 +79,7 @@ protected:
strecpy(buf, GetDriverTypeName(type), lastof(buf));
strecpy(buf + 5, name, lastof(buf));
#if !defined(NDEBUG)
#if !defined(NDEBUG) || defined(WITH_ASSERT)
/* NDEBUG disables asserts and gives a warning: unused variable 'P' */
std::pair<Drivers::iterator, bool> P =
#endif /* !NDEBUG */

View File

@@ -43,6 +43,38 @@
#include "player_face.h"
#include "group.h"
/**
* Multiply two integer values and shift the results to right.
*
* This function multiplies two integer values. The result is
* shifted by the amount of shift to right.
*
* @param a The first integer
* @param b The second integer
* @param shift The amount to shift the value to right.
* @return The shifted result
*/
static inline int32 BigMulS(const int32 a, const int32 b, const uint8 shift)
{
return (int32)((int64)a * (int64)b >> shift);
}
/**
* Multiply two unsigned integers and shift the results to right.
*
* This function multiplies two unsigned integers. The result is
* shifted by the amount of shift to right.
*
* @param a The first unsigned integer
* @param b The second unsigned integer
* @param shift The amount to shift the value to right.
* @return The shifted result
*/
static inline uint32 BigMulSU(const uint32 a, const uint32 b, const uint8 shift)
{
return (uint32)((uint64)a * (uint64)b >> shift);
}
/* Score info */
const ScoreInfo _score_info[] = {
{ SCORE_VEHICLES, 120, 100 },
@@ -212,7 +244,7 @@ int UpdateCompanyRatingAndValue(Player *p, bool update)
/* Skip the total */
if (i == SCORE_TOTAL) continue;
/* Check the score */
s = clamp(_score_part[owner][i], 0, _score_info[i].needed) * _score_info[i].score / _score_info[i].needed;
s = Clamp(_score_part[owner][i], 0, _score_info[i].needed) * _score_info[i].score / _score_info[i].needed;
score += s;
total_score += _score_info[i].score;
}
@@ -296,12 +328,12 @@ void ChangeOwnershipOfPlayerItems(PlayerID old_player, PlayerID new_player)
FOR_ALL_TOWNS(t) {
/* If a player takes over, give the ratings to that player. */
if (new_player != PLAYER_SPECTATOR) {
if (HASBIT(t->have_ratings, old_player)) {
if (HASBIT(t->have_ratings, new_player)) {
if (HasBit(t->have_ratings, old_player)) {
if (HasBit(t->have_ratings, new_player)) {
// use max of the two ratings.
t->ratings[new_player] = max(t->ratings[new_player], t->ratings[old_player]);
} else {
SETBIT(t->have_ratings, new_player);
SetBit(t->have_ratings, new_player);
t->ratings[new_player] = t->ratings[old_player];
}
}
@@ -309,7 +341,7 @@ void ChangeOwnershipOfPlayerItems(PlayerID old_player, PlayerID new_player)
/* Reset the ratings for the old player */
t->ratings[old_player] = 500;
CLRBIT(t->have_ratings, old_player);
ClrBit(t->have_ratings, old_player);
}
{
@@ -333,7 +365,7 @@ void ChangeOwnershipOfPlayerItems(PlayerID old_player, PlayerID new_player)
}
FOR_ALL_VEHICLES(v) {
if (v->owner == old_player && IS_BYTE_INSIDE(v->type, VEH_TRAIN, VEH_AIRCRAFT + 1)) {
if (v->owner == old_player && IsInsideMM(v->type, VEH_TRAIN, VEH_AIRCRAFT + 1)) {
if (new_player == PLAYER_SPECTATOR) {
DeleteWindowById(WC_VEHICLE_VIEW, v->index);
DeleteWindowById(WC_VEHICLE_DETAILS, v->index);
@@ -607,7 +639,7 @@ static void PlayersGenStatistics()
SubtractMoneyFromPlayer(_price.station_value >> 1);
}
if (!HASBIT(1<<0|1<<3|1<<6|1<<9, _cur_month))
if (!HasBit(1<<0|1<<3|1<<6|1<<9, _cur_month))
return;
FOR_ALL_PLAYERS(p) {
@@ -706,7 +738,7 @@ static void PlayersPayInterest()
_current_player = p->index;
SET_EXPENSES_TYPE(EXPENSES_LOAN_INT);
SubtractMoneyFromPlayer(CommandCost((Money)BIGMULUS(p->current_loan, interest, 16)));
SubtractMoneyFromPlayer(CommandCost((Money)BigMulSU(p->current_loan, interest, 16)));
SET_EXPENSES_TYPE(EXPENSES_OTHER);
SubtractMoneyFromPlayer(_price.station_value >> 2);
@@ -759,10 +791,10 @@ static const Money _price_base[NUM_PRICES] = {
65000, ///< ship_base
20, ///< build_trees
250, ///< terraform
20, ///< clear_1
40, ///< purchase_land
200, ///< clear_2
500, ///< clear_3
20, ///< clear_grass
40, ///< clear_roughland
200, ///< clear_rocks
500, ///< clear_fields
20, ///< remove_trees
-70, ///< remove_rail
10, ///< remove_signals
@@ -977,7 +1009,7 @@ static void FindSubsidyCargoRoute(FoundRoute *fr)
if (i == NULL) return;
/* Randomize cargo type */
if (HASBIT(Random(), 0) && i->produced_cargo[1] != CT_INVALID) {
if (HasBit(Random(), 0) && i->produced_cargo[1] != CT_INVALID) {
cargo = i->produced_cargo[1];
trans = i->last_month_pct_transported[1];
total = i->last_month_production[1];
@@ -1070,7 +1102,7 @@ static void SubsidyMonthlyHandler()
}
/* 25% chance to go on */
if (CHANCE16(1,4)) {
if (Chance16(1,4)) {
/* Find a free slot*/
s = _subsidies;
while (s->cargo_type != CT_INVALID) {
@@ -1147,14 +1179,14 @@ Money GetTransportedGoodsIncome(uint num_pieces, uint dist, byte transit_days, C
const CargoSpec *cs = GetCargo(cargo_type);
/* Use callback to calculate cargo profit, if available */
if (HASBIT(cs->callback_mask, CBM_CARGO_PROFIT_CALC)) {
if (HasBit(cs->callback_mask, CBM_CARGO_PROFIT_CALC)) {
uint32 var18 = min(dist, 0xFFFF) | (min(num_pieces, 0xFF) << 16) | (transit_days << 24);
uint16 callback = GetCargoCallback(CBID_CARGO_PROFIT_CALC, 0, var18, cs);
if (callback != CALLBACK_FAILED) {
int result = GB(callback, 0, 14);
/* Simulate a 15 bit signed value */
if (HASBIT(callback, 14)) result = 0x4000 - result;
if (HasBit(callback, 14)) result = 0x4000 - result;
/* "The result should be a signed multiplier that gets multiplied
* by the amount of cargo moved and the price factor, then gets
@@ -1195,7 +1227,7 @@ Money GetTransportedGoodsIncome(uint num_pieces, uint dist, byte transit_days, C
if (time_factor < MIN_TIME_FACTOR) time_factor = MIN_TIME_FACTOR;
return BIGMULSS(dist * time_factor * num_pieces, _cargo_payment_rates[cargo_type], 21);
return BigMulS(dist * time_factor * num_pieces, _cargo_payment_rates[cargo_type], 21);
}
static void DeliverGoodsToIndustry(TileIndex xy, CargoID cargo_type, int num_pieces)
@@ -1222,7 +1254,7 @@ static void DeliverGoodsToIndustry(TileIndex xy, CargoID cargo_type, int num_pie
/* Check if matching cargo has been found */
if (i == lengthof(ind->accepts_cargo)) continue;
if (HASBIT(indspec->callback_flags, CBM_IND_REFUSE_CARGO)) {
if (HasBit(indspec->callback_flags, CBM_IND_REFUSE_CARGO)) {
uint16 res = GetIndustryCallback(CBID_INDUSTRY_REFUSE_CARGO, 0, GetReverseCargoTranslation(cargo_type, indspec->grf_prop.grffile), ind, ind->type, ind->xy);
if (res == 0) continue;
}
@@ -1244,9 +1276,9 @@ static void DeliverGoodsToIndustry(TileIndex xy, CargoID cargo_type, int num_pie
best->was_cargo_delivered = true;
best->last_cargo_accepted_at = _date;
if (HASBIT(callback, CBM_IND_PRODUCTION_CARGO_ARRIVAL) || HASBIT(callback, CBM_IND_PRODUCTION_256_TICKS)) {
if (HasBit(callback, CBM_IND_PRODUCTION_CARGO_ARRIVAL) || HasBit(callback, CBM_IND_PRODUCTION_256_TICKS)) {
best->incoming_cargo_waiting[accepted_cargo_index] = min(num_pieces + best->incoming_cargo_waiting[accepted_cargo_index], 0xFFFF);
if (HASBIT(callback, CBM_IND_PRODUCTION_CARGO_ARRIVAL)) {
if (HasBit(callback, CBM_IND_PRODUCTION_CARGO_ARRIVAL)) {
IndustryProductionCallback(best, 0);
} else {
InvalidateWindow(WC_INDUSTRY_VIEW, best->index);
@@ -1339,7 +1371,7 @@ static Money DeliverGoods(int num_pieces, CargoID cargo_type, StationID source,
{
Player *p = GetPlayer(_current_player);
p->cur_economy.delivered_cargo += num_pieces;
SETBIT(p->cargo_types, cargo_type);
SetBit(p->cargo_types, cargo_type);
}
/* Get station pointers. */
@@ -1393,7 +1425,7 @@ void VehiclePayment(Vehicle *front_v)
_current_player = front_v->owner;
/* At this moment loading cannot be finished */
CLRBIT(front_v->vehicle_flags, VF_LOADING_FINISHED);
ClrBit(front_v->vehicle_flags, VF_LOADING_FINISHED);
/* Start unloading in at the first possible moment */
front_v->load_unload_time_rem = 1;
@@ -1404,7 +1436,7 @@ void VehiclePayment(Vehicle *front_v)
/* All cargo has already been paid for, no need to pay again */
if (!v->cargo.UnpaidCargo()) {
SETBIT(v->vehicle_flags, VF_CARGO_UNLOADING);
SetBit(v->vehicle_flags, VF_CARGO_UNLOADING);
continue;
}
@@ -1415,7 +1447,7 @@ void VehiclePayment(Vehicle *front_v)
CargoPacket *cp = *it;
if (!cp->paid_for &&
cp->source != last_visited &&
HASBIT(ge->acceptance_pickup, GoodsEntry::ACCEPTANCE) &&
HasBit(ge->acceptance_pickup, GoodsEntry::ACCEPTANCE) &&
(front_v->current_order.flags & OF_TRANSFER) == 0) {
/* Deliver goods to the station */
st->time_since_unload = 0;
@@ -1428,7 +1460,7 @@ void VehiclePayment(Vehicle *front_v)
result |= 1;
SETBIT(v->vehicle_flags, VF_CARGO_UNLOADING);
SetBit(v->vehicle_flags, VF_CARGO_UNLOADING);
} else if (front_v->current_order.flags & (OF_UNLOAD | OF_TRANSFER)) {
if (!cp->paid_for && (front_v->current_order.flags & OF_TRANSFER) != 0) {
Money profit = GetTransportedGoodsIncome(
@@ -1445,7 +1477,7 @@ void VehiclePayment(Vehicle *front_v)
}
result |= 2;
SETBIT(v->vehicle_flags, VF_CARGO_UNLOADING);
SetBit(v->vehicle_flags, VF_CARGO_UNLOADING);
}
}
v->cargo.InvalidateCache();
@@ -1483,7 +1515,7 @@ static void LoadUnloadVehicle(Vehicle *v, int *cargo_left)
/* We have not waited enough time till the next round of loading/unloading */
if (--v->load_unload_time_rem != 0) {
if (_patches.improved_load && HASBIT(v->current_order.flags, OFB_FULL_LOAD)) {
if (_patches.improved_load && HasBit(v->current_order.flags, OFB_FULL_LOAD)) {
/* 'Reserve' this cargo for this vehicle, because we were first. */
for (; v != NULL; v = v->Next()) {
if (v->cargo_cap != 0) cargo_left[v->cargo_type] -= v->cargo_cap - v->cargo.Count();
@@ -1495,7 +1527,7 @@ static void LoadUnloadVehicle(Vehicle *v, int *cargo_left)
if (v->type == VEH_TRAIN && !IsTileType(v->tile, MP_STATION)) {
/* The train reversed in the station. Take the "easy" way
* out and let the train just leave as it always did. */
SETBIT(v->vehicle_flags, VF_LOADING_FINISHED);
SetBit(v->vehicle_flags, VF_LOADING_FINISHED);
return;
}
@@ -1519,32 +1551,32 @@ static void LoadUnloadVehicle(Vehicle *v, int *cargo_left)
if (v->cargo_cap == 0) continue;
byte load_amount = EngInfo(v->engine_type)->load_amount;
if (_patches.gradual_loading && HASBIT(EngInfo(v->engine_type)->callbackmask, CBM_VEHICLE_LOAD_AMOUNT)) {
if (_patches.gradual_loading && HasBit(EngInfo(v->engine_type)->callbackmask, CBM_VEHICLE_LOAD_AMOUNT)) {
uint16 cb_load_amount = GetVehicleCallback(CBID_VEHICLE_LOAD_AMOUNT, 0, 0, v->engine_type, v);
if (cb_load_amount != CALLBACK_FAILED && cb_load_amount != 0) load_amount = cb_load_amount & 0xFF;
}
GoodsEntry *ge = &st->goods[v->cargo_type];
if (HASBIT(v->vehicle_flags, VF_CARGO_UNLOADING)) {
if (HasBit(v->vehicle_flags, VF_CARGO_UNLOADING)) {
uint cargo_count = v->cargo.Count();
uint amount_unloaded = _patches.gradual_loading ? min(cargo_count, load_amount) : cargo_count;
bool remaining; // Are there cargo entities in this vehicle that can still be unloaded here?
if (HASBIT(ge->acceptance_pickup, GoodsEntry::ACCEPTANCE) && !(u->current_order.flags & OF_TRANSFER)) {
if (HasBit(ge->acceptance_pickup, GoodsEntry::ACCEPTANCE) && !(u->current_order.flags & OF_TRANSFER)) {
/* The cargo has reached it's final destination, the packets may now be destroyed */
remaining = v->cargo.MoveTo(NULL, amount_unloaded, CargoList::MTA_FINAL_DELIVERY, last_visited);
result |= 1;
} else if (u->current_order.flags & (OF_UNLOAD | OF_TRANSFER)) {
remaining = v->cargo.MoveTo(&ge->cargo, amount_unloaded);
SETBIT(ge->acceptance_pickup, GoodsEntry::PICKUP);
SetBit(ge->acceptance_pickup, GoodsEntry::PICKUP);
result |= 2;
} else {
/* The order changed while unloading (unset unload/transfer) or the
* station does not accept goods anymore. */
CLRBIT(v->vehicle_flags, VF_CARGO_UNLOADING);
ClrBit(v->vehicle_flags, VF_CARGO_UNLOADING);
continue;
}
@@ -1558,7 +1590,7 @@ static void LoadUnloadVehicle(Vehicle *v, int *cargo_left)
completely_empty = false;
} else {
/* We have finished unloading (cargo count == 0) */
CLRBIT(v->vehicle_flags, VF_CARGO_UNLOADING);
ClrBit(v->vehicle_flags, VF_CARGO_UNLOADING);
}
continue;
@@ -1589,7 +1621,7 @@ static void LoadUnloadVehicle(Vehicle *v, int *cargo_left)
/* Skip loading this vehicle if another train/vehicle is already handling
* the same cargo type at this station */
if (_patches.improved_load && cargo_left[v->cargo_type] <= 0) {
SETBIT(cargo_not_full, v->cargo_type);
SetBit(cargo_not_full, v->cargo_type);
continue;
}
@@ -1624,9 +1656,9 @@ static void LoadUnloadVehicle(Vehicle *v, int *cargo_left)
}
if (v->cargo.Count() == v->cargo_cap) {
SETBIT(cargo_full, v->cargo_type);
SetBit(cargo_full, v->cargo_type);
} else {
SETBIT(cargo_not_full, v->cargo_type);
SetBit(cargo_not_full, v->cargo_type);
}
}
@@ -1634,7 +1666,7 @@ static void LoadUnloadVehicle(Vehicle *v, int *cargo_left)
* all wagons at the same time instead of using the same 'improved'
* loading algorithm for the wagons (only fill wagon when there is
* enough to fill the previous wagons) */
if (_patches.improved_load && HASBIT(u->current_order.flags, OFB_FULL_LOAD)) {
if (_patches.improved_load && HasBit(u->current_order.flags, OFB_FULL_LOAD)) {
/* Update left cargo */
for (v = u; v != NULL; v = v->Next()) {
if (v->cargo_cap != 0) cargo_left[v->cargo_type] -= v->cargo_cap - v->cargo.Count();
@@ -1653,7 +1685,7 @@ static void LoadUnloadVehicle(Vehicle *v, int *cargo_left)
}
} else {
bool finished_loading = true;
if (HASBIT(v->current_order.flags, OFB_FULL_LOAD)) {
if (HasBit(v->current_order.flags, OFB_FULL_LOAD)) {
if (_patches.full_load_any) {
/* if the aircraft carries passengers and is NOT full, then
* continue loading, no matter how much mail is in */

View File

@@ -69,7 +69,7 @@
static inline TLG GetTLG(TileIndex t)
{
return (TLG)((HASBIT(TileX(t), 0) << 1) + HASBIT(TileY(t), 0));
return (TLG)((HasBit(TileX(t), 0) << 1) + HasBit(TileY(t), 0));
}
/** Finds which Rail Bits are present on a given tile. For bridge tiles,
@@ -270,11 +270,11 @@ static void DrawCatenaryRailway(const TileInfo *ti)
/* We check whether the track in question (k) is present in the tile
* (TrackSourceTile) */
if (HASBIT(trackconfig[TrackSourceTile[i][k]], TracksAtPCP[i][k])) {
if (HasBit(trackconfig[TrackSourceTile[i][k]], TracksAtPCP[i][k])) {
/* track found, if track is in the neighbour tile, adjust the number
* of the PCP for preferred/allowed determination*/
DiagDirection PCPpos = (TrackSourceTile[i][k] == TS_HOME) ? i : ReverseDiagDir(i);
SETBIT(PCPstatus, i); // This PCP is in use
SetBit(PCPstatus, i); // This PCP is in use
PPPpreferred[i] &= PreferredPPPofTrackAtPCP[TracksAtPCP[i][k]][PCPpos];
PPPallowed[i] &= ~DisallowedPPPofTrackAtPCP[TracksAtPCP[i][k]][PCPpos];
@@ -282,8 +282,8 @@ static void DrawCatenaryRailway(const TileInfo *ti)
}
/* Deactivate all PPPs if PCP is not used */
PPPpreferred[i] *= HASBIT(PCPstatus, i);
PPPallowed[i] *= HASBIT(PCPstatus, i);
PPPpreferred[i] *= HasBit(PCPstatus, i);
PPPallowed[i] *= HasBit(PCPstatus, i);
/* A station is always "flat", so adjust the tileh accordingly */
if (IsTileType(neighbour, MP_STATION)) tileh[TS_NEIGHBOUR] = SLOPE_FLAT;
@@ -307,7 +307,7 @@ static void DrawCatenaryRailway(const TileInfo *ti)
/* Level means that the slope is the same, or the track is flat */
if (tileh[TS_HOME] == tileh[TS_NEIGHBOUR] || (isflat[TS_HOME] && isflat[TS_NEIGHBOUR])) {
for (k = 0; k < NUM_IGNORE_GROUPS; k++)
if (PPPpreferred[i] == IgnoredPCP[k][tlg][i]) CLRBIT(PCPstatus, i);
if (PPPpreferred[i] == IgnoredPCP[k][tlg][i]) ClrBit(PCPstatus, i);
}
/* Now decide where we draw our pylons. First try the preferred PPPs, but they may not exist.
@@ -322,20 +322,20 @@ static void DrawCatenaryRailway(const TileInfo *ti)
if ((height <= GetTileMaxZ(ti->tile) + TILE_HEIGHT) &&
(i == PCPpositions[bridgetrack][0] || i == PCPpositions[bridgetrack][1])) {
SETBIT(OverridePCP, i);
SetBit(OverridePCP, i);
}
}
if (PPPallowed[i] != 0 && HASBIT(PCPstatus, i) && !HASBIT(OverridePCP, i)) {
if (PPPallowed[i] != 0 && HasBit(PCPstatus, i) && !HasBit(OverridePCP, i)) {
for (k = 0; k < DIR_END; k++) {
byte temp = PPPorder[i][GetTLG(ti->tile)][k];
if (HASBIT(PPPallowed[i], temp)) {
if (HasBit(PPPallowed[i], temp)) {
uint x = ti->x + x_pcp_offsets[i] + x_ppp_offsets[temp];
uint y = ti->y + y_pcp_offsets[i] + y_ppp_offsets[temp];
/* Don't build the pylon if it would be outside the tile */
if (!HASBIT(OwnedPPPonPCP[i], temp)) {
if (!HasBit(OwnedPPPonPCP[i], temp)) {
/* We have a neighour that will draw it, bail out */
if (trackconfig[TS_NEIGHBOUR] != 0) break;
continue; /* No neighbour, go looking for a better position */
@@ -359,10 +359,10 @@ static void DrawCatenaryRailway(const TileInfo *ti)
/* Drawing of pylons is finished, now draw the wires */
for (t = TRACK_BEGIN; t < TRACK_END; t++) {
if (HASBIT(trackconfig[TS_HOME], t)) {
if (HasBit(trackconfig[TS_HOME], t)) {
if (IsTunnelTile(ti->tile)) break; // drawn together with tunnel-roof (see DrawCatenaryOnTunnel())
byte PCPconfig = HASBIT(PCPstatus, PCPpositions[t][0]) +
(HASBIT(PCPstatus, PCPpositions[t][1]) << 1);
byte PCPconfig = HasBit(PCPstatus, PCPpositions[t][0]) +
(HasBit(PCPstatus, PCPpositions[t][1]) << 1);
const SortableSpriteStruct *sss;
int tileh_selector = !(tileh[TS_HOME] % 3) * tileh[TS_HOME] / 3; /* tileh for the slopes, 0 otherwise */
@@ -419,7 +419,7 @@ static void DrawCatenaryOnBridge(const TileInfo *ti)
if (num % 2) {
DiagDirection PCPpos = (axis == AXIS_X ? DIAGDIR_NE : DIAGDIR_NW);
Direction PPPpos = (axis == AXIS_X ? DIR_NW : DIR_NE);
if (HASBIT(tlg, (axis == AXIS_X ? 0 : 1))) PPPpos = ReverseDir(PPPpos);
if (HasBit(tlg, (axis == AXIS_X ? 0 : 1))) PPPpos = ReverseDir(PPPpos);
uint x = ti->x + x_pcp_offsets[PCPpos] + x_ppp_offsets[PPPpos];
uint y = ti->y + y_pcp_offsets[PCPpos] + y_ppp_offsets[PPPpos];
AddSortableSpriteToDraw(pylon_sprites[PPPpos], PAL_NONE, x, y, 1, 1, BB_HEIGHT_UNDER_BRIDGE, height, IsTransparencySet(TO_BUILDINGS), -1, -1);
@@ -429,7 +429,7 @@ static void DrawCatenaryOnBridge(const TileInfo *ti)
if (DistanceMax(ti->tile, start) == length) {
DiagDirection PCPpos = (axis == AXIS_X ? DIAGDIR_SW : DIAGDIR_SE);
Direction PPPpos = (axis == AXIS_X ? DIR_NW : DIR_NE);
if (HASBIT(tlg, (axis == AXIS_X ? 0 : 1))) PPPpos = ReverseDir(PPPpos);
if (HasBit(tlg, (axis == AXIS_X ? 0 : 1))) PPPpos = ReverseDir(PPPpos);
uint x = ti->x + x_pcp_offsets[PCPpos] + x_ppp_offsets[PPPpos];
uint y = ti->y + y_pcp_offsets[PCPpos] + y_ppp_offsets[PPPpos];
AddSortableSpriteToDraw(pylon_sprites[PPPpos], PAL_NONE, x, y, 1, 1, BB_HEIGHT_UNDER_BRIDGE, height, IsTransparencySet(TO_BUILDINGS), -1, -1);
@@ -504,7 +504,7 @@ int32 SettingsDisableElrail(int32 p1)
* so add there also normal rail compatibility */
v->u.rail.compatible_railtypes |= (1 << RAILTYPE_RAIL);
v->u.rail.railtype = RAILTYPE_RAIL;
SETBIT(v->u.rail.flags, VRF_EL_ENGINE_ALLOWED_NORMAL_RAIL);
SetBit(v->u.rail.flags, VRF_EL_ENGINE_ALLOWED_NORMAL_RAIL);
}
}
}

View File

@@ -165,7 +165,7 @@ void StartupEngines()
e->lifelength = ei->lifelength + _patches.extend_vehicle_life;
/* prevent certain engines from ever appearing. */
if (!HASBIT(ei->climates, _opt.landscape)) {
if (!HasBit(ei->climates, _opt.landscape)) {
e->flags |= ENGINE_AVAILABLE;
e->player_avail = 0;
}
@@ -183,14 +183,14 @@ static void AcceptEnginePreview(EngineID eid, PlayerID player)
Engine *e = GetEngine(eid);
Player *p = GetPlayer(player);
SETBIT(e->player_avail, player);
SetBit(e->player_avail, player);
if (e->type == VEH_TRAIN) {
const RailVehicleInfo *rvi = RailVehInfo(eid);
assert(rvi->railtype < RAILTYPE_END);
SETBIT(p->avail_railtypes, rvi->railtype);
SetBit(p->avail_railtypes, rvi->railtype);
} else if (e->type == VEH_ROAD) {
SETBIT(p->avail_roadtypes, HASBIT(EngInfo(eid)->misc_flags, EF_ROAD_TRAM) ? ROADTYPE_TRAM : ROADTYPE_ROAD);
SetBit(p->avail_roadtypes, HasBit(EngInfo(eid)->misc_flags, EF_ROAD_TRAM) ? ROADTYPE_TRAM : ROADTYPE_ROAD);
}
e->preview_player = INVALID_PLAYER;
@@ -210,7 +210,7 @@ static PlayerID GetBestPlayer(PlayerID pp)
best_hist = -1;
best_player = PLAYER_SPECTATOR;
FOR_ALL_PLAYERS(p) {
if (p->is_active && p->block_preview == 0 && !HASBIT(mask, p->index) &&
if (p->is_active && p->block_preview == 0 && !HasBit(mask, p->index) &&
p->old_economy[0].performance_history > best_hist) {
best_hist = p->old_economy[0].performance_history;
best_player = p->index;
@@ -219,7 +219,7 @@ static PlayerID GetBestPlayer(PlayerID pp)
if (best_player == PLAYER_SPECTATOR) return PLAYER_SPECTATOR;
SETBIT(mask, best_player);
SetBit(mask, best_player);
} while (pp--, pp != 0);
return best_player;
@@ -300,7 +300,7 @@ static void NewVehicleAvailable(Engine *e)
FOR_ALL_PLAYERS(p) {
uint block_preview = p->block_preview;
if (!HASBIT(e->player_avail, p->index)) continue;
if (!HasBit(e->player_avail, p->index)) continue;
/* We assume the user did NOT build it.. prove me wrong ;) */
p->block_preview = 20;
@@ -332,13 +332,13 @@ static void NewVehicleAvailable(Engine *e)
RailType railtype = RailVehInfo(index)->railtype;
assert(railtype < RAILTYPE_END);
FOR_ALL_PLAYERS(p) {
if (p->is_active) SETBIT(p->avail_railtypes, railtype);
if (p->is_active) SetBit(p->avail_railtypes, railtype);
}
}
if ((index - NUM_TRAIN_ENGINES) < NUM_ROAD_ENGINES) {
/* maybe make another road type available */
FOR_ALL_PLAYERS(p) {
if (p->is_active) SETBIT(p->avail_roadtypes, HASBIT(EngInfo(index)->misc_flags, EF_ROAD_TRAM) ? ROADTYPE_TRAM : ROADTYPE_ROAD);
if (p->is_active) SetBit(p->avail_roadtypes, HasBit(EngInfo(index)->misc_flags, EF_ROAD_TRAM) ? ROADTYPE_TRAM : ROADTYPE_ROAD);
}
}
AddNewsItem(index, NEWS_FLAGS(NM_CALLBACK, 0, NT_NEW_VEHICLES, DNC_VEHICLEAVAIL), 0, 0);
@@ -436,12 +436,12 @@ bool IsEngineBuildable(EngineID engine, byte type, PlayerID player)
if (e->type != type) return false;
/* check if it's available */
if (!HASBIT(e->player_avail, player)) return false;
if (!HasBit(e->player_avail, player)) return false;
if (type == VEH_TRAIN) {
/* Check if the rail type is available to this player */
const Player *p = GetPlayer(player);
if (!HASBIT(p->avail_railtypes, RailVehInfo(engine)->railtype)) return false;
if (!HasBit(p->avail_railtypes, RailVehInfo(engine)->railtype)) return false;
}
return true;

View File

@@ -350,6 +350,12 @@ FILE *FioFOpenFile(const char *filename, const char *mode, Subdirectory subdir,
}
}
/* Sometimes a full path is given. To support
* the 'subdirectory' must be 'removed'. */
if (f == NULL && subdir != NO_DIRECTORY) {
f = FioFOpenFile(filename, mode, NO_DIRECTORY, filesize);
}
return f;
}
@@ -363,6 +369,16 @@ void FioCreateDirectory(const char *name)
CreateDirectory(OTTD2FS(name), NULL);
#elif defined(OS2) && !defined(__INNOTEK_LIBC__)
mkdir(OTTD2FS(name));
#elif defined(__MORPHOS__) || defined(__AMIGAOS__)
char buf[MAX_PATH];
ttd_strlcpy(buf, name, MAX_PATH);
size_t len = strlen(name) - 1;
if (buf[len] == '/') {
buf[len] = '\0'; // Kill pathsep, so mkdir() will not fail
}
mkdir(OTTD2FS(buf), 0755);
#else
mkdir(OTTD2FS(name), 0755);
#endif
@@ -508,7 +524,7 @@ static bool TarListAddFile(const char *filename)
if (_tar_filelist.insert(TarFileList::value_type(name, entry)).second) num++;
/* Skip to the next block.. */
skip = ALIGN(skip, 512);
skip = Align(skip, 512);
fseek(f, skip, SEEK_CUR);
pos += skip;
}
@@ -720,7 +736,10 @@ void DeterminePaths(const char *exe)
char *autosave_dir = str_fmt("%s%s", _personal_dir, FioGetSubdirectory(AUTOSAVE_DIR));
/* Make the necessary folders */
#if !defined(__MORPHOS__) && !defined(__AMIGA__) && defined(WITH_PERSONAL_DIR)
FioCreateDirectory(_personal_dir);
#endif
FioCreateDirectory(save_dir);
FioCreateDirectory(autosave_dir);

View File

@@ -145,15 +145,7 @@ char *FiosBrowseTo(const FiosItem *item)
case FIOS_TYPE_BMP:
{
static char str_buffr[512];
#if defined(__MORPHOS__) || defined(__AMIGAOS__)
/* On MorphOS or AmigaOS paths look like: "Volume:directory/subdirectory" */
if (FiosIsRoot(path)) {
snprintf(str_buffr, lengthof(str_buffr), "%s:%s", path, item->name);
} else // XXX - only next line!
#endif
snprintf(str_buffr, lengthof(str_buffr), "%s%s", path, item->name);
return str_buffr;
}
}
@@ -170,8 +162,21 @@ void FiosMakeSavegameName(char *buf, const char *name, size_t size)
/* Don't append the extension if it is already there */
period = strrchr(name, '.');
if (period != NULL && strcasecmp(period, extension) == 0) extension = "";
#if defined(__MORPHOS__) || defined(__AMIGAOS__)
if (_fios_path != NULL) {
unsigned char sepchar = _fios_path[(strlen(_fios_path) - 1)];
if (sepchar != ':' && sepchar != '/') {
snprintf(buf, size, "%s" PATHSEP "%s%s", _fios_path, name, extension);
} else {
snprintf(buf, size, "%s%s%s", _fios_path, name, extension);
}
} else {
snprintf(buf, size, "%s%s", name, extension);
}
#else
snprintf(buf, size, "%s" PATHSEP "%s%s", _fios_path, name, extension);
#endif
}
#if defined(WIN32)

View File

@@ -365,7 +365,7 @@ static void SetGlyphPtr(FontSize size, WChar key, const GlyphEntry *glyph)
void *AllocateFont(size_t size)
{
return malloc(size);
return MallocT<byte>(size);
}
@@ -434,7 +434,7 @@ const Sprite *GetGlyph(FontSize size, WChar key)
if (size == FS_NORMAL) {
for (y = 0; y < slot->bitmap.rows; y++) {
for (x = 0; x < slot->bitmap.width; x++) {
if (aa ? (slot->bitmap.buffer[x + y * slot->bitmap.pitch] > 0) : HASBIT(slot->bitmap.buffer[(x / 8) + y * slot->bitmap.pitch], 7 - (x % 8))) {
if (aa ? (slot->bitmap.buffer[x + y * slot->bitmap.pitch] > 0) : HasBit(slot->bitmap.buffer[(x / 8) + y * slot->bitmap.pitch], 7 - (x % 8))) {
sprite.data[1 + x + (1 + y) * sprite.width].m = SHADOW_COLOUR;
sprite.data[1 + x + (1 + y) * sprite.width].a = aa ? slot->bitmap.buffer[x + y * slot->bitmap.pitch] : 0xFF;
}
@@ -444,7 +444,7 @@ const Sprite *GetGlyph(FontSize size, WChar key)
for (y = 0; y < slot->bitmap.rows; y++) {
for (x = 0; x < slot->bitmap.width; x++) {
if (aa ? (slot->bitmap.buffer[x + y * slot->bitmap.pitch] > 0) : HASBIT(slot->bitmap.buffer[(x / 8) + y * slot->bitmap.pitch], 7 - (x % 8))) {
if (aa ? (slot->bitmap.buffer[x + y * slot->bitmap.pitch] > 0) : HasBit(slot->bitmap.buffer[(x / 8) + y * slot->bitmap.pitch], 7 - (x % 8))) {
sprite.data[x + y * sprite.width].m = FACE_COLOUR;
sprite.data[x + y * sprite.width].a = aa ? slot->bitmap.buffer[x + y * slot->bitmap.pitch] : 0xFF;
}

View File

@@ -7,6 +7,7 @@
#include "gfx.h"
#include "viewport.h"
#include "core/random_func.hpp"
void UpdateTownMaxPass(Town *t);
@@ -16,10 +17,6 @@ void DrawClearLandTile(const TileInfo *ti, byte set);
void DrawClearLandFence(const TileInfo *ti);
void TileLoopClearHelper(TileIndex tile);
/* water_land.cpp */
void DrawShipDepotSprite(int x, int y, int image);
void TileLoop_Water(TileIndex tile);
/* players.cpp */
bool CheckPlayerHasMoney(CommandCost cost);
void SubtractMoneyFromPlayer(CommandCost cost);
@@ -32,52 +29,9 @@ void ShowInfo(const char *str);
void CDECL ShowInfoF(const char *str, ...);
/* openttd.cpp */
/**************
* Warning: DO NOT enable this unless you understand what it does
*
* If enabled, in a network game all randoms will be dumped to the
* stdout if the first client joins (or if you are a client). This
* is to help finding desync problems.
*
* Warning: DO NOT enable this unless you understand what it does
**************/
//#define RANDOM_DEBUG
// Enable this to produce higher quality random numbers.
// Doesn't work with network yet.
//#define MERSENNE_TWISTER
// Mersenne twister functions
void SeedMT(uint32 seed);
uint32 RandomMT();
#ifdef MERSENNE_TWISTER
static inline uint32 Random() { return RandomMT(); }
uint RandomRange(uint max);
#else
#ifdef RANDOM_DEBUG
#define Random() DoRandom(__LINE__, __FILE__)
uint32 DoRandom(int line, const char *file);
#define RandomRange(max) DoRandomRange(max, __LINE__, __FILE__)
uint DoRandomRange(uint max, int line, const char *file);
#else
uint32 Random();
uint RandomRange(uint max);
#endif
#endif // MERSENNE_TWISTER
static inline TileIndex RandomTileSeed(uint32 r) { return TILE_MASK(r); }
static inline TileIndex RandomTile() { return TILE_MASK(Random()); }
uint32 InteractiveRandom(); // Used for random sequences that are not the same on the other end of the multiplayer link
uint InteractiveRandomRange(uint max);
/* texteff.cpp */
void AddAnimatedTile(TileIndex tile);
void DeleteAnimatedTile(TileIndex tile);
@@ -151,8 +105,6 @@ void ChangeTownRating(Town *t, int add, int max);
uint GetTownRadiusGroup(const Town* t, TileIndex tile);
void ShowHighscoreTable(int difficulty, int8 rank);
int FindFirstBit(uint32 x);
void AfterLoadTown();
void UpdatePatches();
void AskExitGame();

View File

@@ -228,7 +228,7 @@ static void GenerateLandscapeWndProc(Window *w, WindowEvent *e)
switch (e->event) {
case WE_CREATE:
LowerWindowWidget(w, _opt_newgame.landscape + GLAND_TEMPERATE);
w->LowerWidget(_opt_newgame.landscape + GLAND_TEMPERATE);
snprintf(_genseed_buffer, sizeof(_genseed_buffer), "%u", _patches_newgame.generation_seed);
InitializeTextBuffer(&_genseed_query.text, _genseed_buffer, lengthof(_genseed_buffer), 120);
@@ -239,28 +239,28 @@ static void GenerateLandscapeWndProc(Window *w, WindowEvent *e)
case WE_PAINT:
/* You can't select smoothness if not terragenesis */
if (mode == GLWP_GENERATE) {
SetWindowWidgetDisabledState(w, GLAND_SMOOTHNESS_TEXT, _patches_newgame.land_generator == 0);
SetWindowWidgetDisabledState(w, GLAND_SMOOTHNESS_PULLDOWN, _patches_newgame.land_generator == 0);
w->SetWidgetDisabledState(GLAND_SMOOTHNESS_TEXT, _patches_newgame.land_generator == 0);
w->SetWidgetDisabledState(GLAND_SMOOTHNESS_PULLDOWN, _patches_newgame.land_generator == 0);
}
/* Disable snowline if not hilly */
SetWindowWidgetDisabledState(w, GLAND_SNOW_LEVEL_TEXT, _opt_newgame.landscape != LT_ARCTIC);
w->SetWidgetDisabledState(GLAND_SNOW_LEVEL_TEXT, _opt_newgame.landscape != LT_ARCTIC);
/* Disable town, industry and trees in SE */
SetWindowWidgetDisabledState(w, GLAND_TOWN_TEXT, _game_mode == GM_EDITOR);
SetWindowWidgetDisabledState(w, GLAND_TOWN_PULLDOWN, _game_mode == GM_EDITOR);
SetWindowWidgetDisabledState(w, GLAND_INDUSTRY_TEXT, _game_mode == GM_EDITOR);
SetWindowWidgetDisabledState(w, GLAND_INDUSTRY_PULLDOWN, _game_mode == GM_EDITOR);
SetWindowWidgetDisabledState(w, GLAND_TREE_TEXT, _game_mode == GM_EDITOR);
SetWindowWidgetDisabledState(w, GLAND_TREE_PULLDOWN, _game_mode == GM_EDITOR);
w->SetWidgetDisabledState(GLAND_TOWN_TEXT, _game_mode == GM_EDITOR);
w->SetWidgetDisabledState(GLAND_TOWN_PULLDOWN, _game_mode == GM_EDITOR);
w->SetWidgetDisabledState(GLAND_INDUSTRY_TEXT, _game_mode == GM_EDITOR);
w->SetWidgetDisabledState(GLAND_INDUSTRY_PULLDOWN, _game_mode == GM_EDITOR);
w->SetWidgetDisabledState(GLAND_TREE_TEXT, _game_mode == GM_EDITOR);
w->SetWidgetDisabledState(GLAND_TREE_PULLDOWN, _game_mode == GM_EDITOR);
SetWindowWidgetDisabledState(w, GLAND_START_DATE_DOWN, _patches_newgame.starting_year <= MIN_YEAR);
SetWindowWidgetDisabledState(w, GLAND_START_DATE_UP, _patches_newgame.starting_year >= MAX_YEAR);
SetWindowWidgetDisabledState(w, GLAND_SNOW_LEVEL_DOWN, _patches_newgame.snow_line_height <= 2 || _opt_newgame.landscape != LT_ARCTIC);
SetWindowWidgetDisabledState(w, GLAND_SNOW_LEVEL_UP, _patches_newgame.snow_line_height >= MAX_SNOWLINE_HEIGHT || _opt_newgame.landscape != LT_ARCTIC);
w->SetWidgetDisabledState(GLAND_START_DATE_DOWN, _patches_newgame.starting_year <= MIN_YEAR);
w->SetWidgetDisabledState(GLAND_START_DATE_UP, _patches_newgame.starting_year >= MAX_YEAR);
w->SetWidgetDisabledState(GLAND_SNOW_LEVEL_DOWN, _patches_newgame.snow_line_height <= 2 || _opt_newgame.landscape != LT_ARCTIC);
w->SetWidgetDisabledState(GLAND_SNOW_LEVEL_UP, _patches_newgame.snow_line_height >= MAX_SNOWLINE_HEIGHT || _opt_newgame.landscape != LT_ARCTIC);
SetWindowWidgetLoweredState(w, GLAND_TEMPERATE, _opt_newgame.landscape == LT_TEMPERATE);
SetWindowWidgetLoweredState(w, GLAND_ARCTIC, _opt_newgame.landscape == LT_ARCTIC);
SetWindowWidgetLoweredState(w, GLAND_TROPICAL, _opt_newgame.landscape == LT_TROPIC);
SetWindowWidgetLoweredState(w, GLAND_TOYLAND, _opt_newgame.landscape == LT_TOYLAND);
w->SetWidgetLoweredState(GLAND_TEMPERATE, _opt_newgame.landscape == LT_TEMPERATE);
w->SetWidgetLoweredState(GLAND_ARCTIC, _opt_newgame.landscape == LT_ARCTIC);
w->SetWidgetLoweredState(GLAND_TROPICAL, _opt_newgame.landscape == LT_TROPIC);
w->SetWidgetLoweredState(GLAND_TOYLAND, _opt_newgame.landscape == LT_TOYLAND);
DrawWindowWidgets(w);
y = (mode == GLWP_HEIGHTMAP) ? 22 : 0;
@@ -335,7 +335,7 @@ static void GenerateLandscapeWndProc(Window *w, WindowEvent *e)
switch (e->we.click.widget) {
case 0: DeleteWindow(w); break;
case GLAND_TEMPERATE: case GLAND_ARCTIC: case GLAND_TROPICAL: case GLAND_TOYLAND:
RaiseWindowWidget(w, _opt_newgame.landscape + GLAND_TEMPERATE);
w->RaiseWidget(_opt_newgame.landscape + GLAND_TEMPERATE);
SetNewLandscapeType(e->we.click.widget - GLAND_TEMPERATE);
break;
case GLAND_MAPSIZE_X_TEXT: case GLAND_MAPSIZE_X_PULLDOWN: // Mapsize X
@@ -384,10 +384,10 @@ static void GenerateLandscapeWndProc(Window *w, WindowEvent *e)
case GLAND_START_DATE_DOWN: case GLAND_START_DATE_UP: // Year buttons
/* Don't allow too fast scrolling */
if ((w->flags4 & WF_TIMEOUT_MASK) <= 2 << WF_TIMEOUT_SHL) {
HandleButtonClick(w, e->we.click.widget);
w->HandleButtonClick(e->we.click.widget);
SetWindowDirty(w);
_patches_newgame.starting_year = clamp(_patches_newgame.starting_year + e->we.click.widget - GLAND_START_DATE_TEXT, MIN_YEAR, MAX_YEAR);
_patches_newgame.starting_year = Clamp(_patches_newgame.starting_year + e->we.click.widget - GLAND_START_DATE_TEXT, MIN_YEAR, MAX_YEAR);
}
_left_button_clicked = false;
break;
@@ -399,10 +399,10 @@ static void GenerateLandscapeWndProc(Window *w, WindowEvent *e)
case GLAND_SNOW_LEVEL_DOWN: case GLAND_SNOW_LEVEL_UP: // Snow line buttons
/* Don't allow too fast scrolling */
if ((w->flags4 & WF_TIMEOUT_MASK) <= 2 << WF_TIMEOUT_SHL) {
HandleButtonClick(w, e->we.click.widget);
w->HandleButtonClick(e->we.click.widget);
SetWindowDirty(w);
_patches_newgame.snow_line_height = clamp(_patches_newgame.snow_line_height + e->we.click.widget - GLAND_SNOW_LEVEL_TEXT, 2, MAX_SNOWLINE_HEIGHT);
_patches_newgame.snow_line_height = Clamp(_patches_newgame.snow_line_height + e->we.click.widget - GLAND_SNOW_LEVEL_TEXT, 2, MAX_SNOWLINE_HEIGHT);
}
_left_button_clicked = false;
break;
@@ -493,12 +493,12 @@ static void GenerateLandscapeWndProc(Window *w, WindowEvent *e)
switch (WP(w, generate_d).widget_id) {
case GLAND_START_DATE_TEXT:
InvalidateWidget(w, GLAND_START_DATE_TEXT);
_patches_newgame.starting_year = clamp(value, MIN_YEAR, MAX_YEAR);
w->InvalidateWidget(GLAND_START_DATE_TEXT);
_patches_newgame.starting_year = Clamp(value, MIN_YEAR, MAX_YEAR);
break;
case GLAND_SNOW_LEVEL_TEXT:
InvalidateWidget(w, GLAND_SNOW_LEVEL_TEXT);
_patches_newgame.snow_line_height = clamp(value, 2, MAX_SNOWLINE_HEIGHT);
w->InvalidateWidget(GLAND_SNOW_LEVEL_TEXT);
_patches_newgame.snow_line_height = Clamp(value, 2, MAX_SNOWLINE_HEIGHT);
break;
}
@@ -605,18 +605,18 @@ static void CreateScenarioWndProc(Window *w, WindowEvent *e)
static const StringID mapsizes[] = {STR_64, STR_128, STR_256, STR_512, STR_1024, STR_2048, INVALID_STRING_ID};
switch (e->event) {
case WE_CREATE: LowerWindowWidget(w, _opt_newgame.landscape + CSCEN_TEMPERATE); break;
case WE_CREATE: w->LowerWidget(_opt_newgame.landscape + CSCEN_TEMPERATE); break;
case WE_PAINT:
SetWindowWidgetDisabledState(w, CSCEN_START_DATE_DOWN, _patches_newgame.starting_year <= MIN_YEAR);
SetWindowWidgetDisabledState(w, CSCEN_START_DATE_UP, _patches_newgame.starting_year >= MAX_YEAR);
SetWindowWidgetDisabledState(w, CSCEN_FLAT_LAND_HEIGHT_DOWN, _patches_newgame.se_flat_world_height <= 0);
SetWindowWidgetDisabledState(w, CSCEN_FLAT_LAND_HEIGHT_UP, _patches_newgame.se_flat_world_height >= MAX_TILE_HEIGHT);
w->SetWidgetDisabledState(CSCEN_START_DATE_DOWN, _patches_newgame.starting_year <= MIN_YEAR);
w->SetWidgetDisabledState(CSCEN_START_DATE_UP, _patches_newgame.starting_year >= MAX_YEAR);
w->SetWidgetDisabledState(CSCEN_FLAT_LAND_HEIGHT_DOWN, _patches_newgame.se_flat_world_height <= 0);
w->SetWidgetDisabledState(CSCEN_FLAT_LAND_HEIGHT_UP, _patches_newgame.se_flat_world_height >= MAX_TILE_HEIGHT);
SetWindowWidgetLoweredState(w, CSCEN_TEMPERATE, _opt_newgame.landscape == LT_TEMPERATE);
SetWindowWidgetLoweredState(w, CSCEN_ARCTIC, _opt_newgame.landscape == LT_ARCTIC);
SetWindowWidgetLoweredState(w, CSCEN_TROPICAL, _opt_newgame.landscape == LT_TROPIC);
SetWindowWidgetLoweredState(w, CSCEN_TOYLAND, _opt_newgame.landscape == LT_TOYLAND);
w->SetWidgetLoweredState(CSCEN_TEMPERATE, _opt_newgame.landscape == LT_TEMPERATE);
w->SetWidgetLoweredState(CSCEN_ARCTIC, _opt_newgame.landscape == LT_ARCTIC);
w->SetWidgetLoweredState(CSCEN_TROPICAL, _opt_newgame.landscape == LT_TROPIC);
w->SetWidgetLoweredState(CSCEN_TOYLAND, _opt_newgame.landscape == LT_TOYLAND);
DrawWindowWidgets(w);
DrawStringRightAligned(211, 97, STR_MAPSIZE, TC_FROMSTRING);
@@ -636,7 +636,7 @@ static void CreateScenarioWndProc(Window *w, WindowEvent *e)
case WE_CLICK:
switch (e->we.click.widget) {
case CSCEN_TEMPERATE: case CSCEN_ARCTIC: case CSCEN_TROPICAL: case CSCEN_TOYLAND:
RaiseWindowWidget(w, _opt_newgame.landscape + CSCEN_TEMPERATE);
w->RaiseWidget(_opt_newgame.landscape + CSCEN_TEMPERATE);
SetNewLandscapeType(e->we.click.widget - CSCEN_TEMPERATE);
break;
case CSCEN_MAPSIZE_X_TEXT: case CSCEN_MAPSIZE_X_PULLDOWN: // Mapsize X
@@ -654,10 +654,10 @@ static void CreateScenarioWndProc(Window *w, WindowEvent *e)
case CSCEN_START_DATE_DOWN: case CSCEN_START_DATE_UP: // Year buttons
/* Don't allow too fast scrolling */
if ((w->flags4 & WF_TIMEOUT_MASK) <= 2 << WF_TIMEOUT_SHL) {
HandleButtonClick(w, e->we.click.widget);
w->HandleButtonClick(e->we.click.widget);
SetWindowDirty(w);
_patches_newgame.starting_year = clamp(_patches_newgame.starting_year + e->we.click.widget - CSCEN_START_DATE_TEXT, MIN_YEAR, MAX_YEAR);
_patches_newgame.starting_year = Clamp(_patches_newgame.starting_year + e->we.click.widget - CSCEN_START_DATE_TEXT, MIN_YEAR, MAX_YEAR);
}
_left_button_clicked = false;
break;
@@ -669,10 +669,10 @@ static void CreateScenarioWndProc(Window *w, WindowEvent *e)
case CSCEN_FLAT_LAND_HEIGHT_DOWN: case CSCEN_FLAT_LAND_HEIGHT_UP: // Height level buttons
/* Don't allow too fast scrolling */
if ((w->flags4 & WF_TIMEOUT_MASK) <= 2 << WF_TIMEOUT_SHL) {
HandleButtonClick(w, e->we.click.widget);
w->HandleButtonClick(e->we.click.widget);
SetWindowDirty(w);
_patches_newgame.se_flat_world_height = clamp(_patches_newgame.se_flat_world_height + e->we.click.widget - CSCEN_FLAT_LAND_HEIGHT_TEXT, 0, MAX_TILE_HEIGHT);
_patches_newgame.se_flat_world_height = Clamp(_patches_newgame.se_flat_world_height + e->we.click.widget - CSCEN_FLAT_LAND_HEIGHT_TEXT, 0, MAX_TILE_HEIGHT);
}
_left_button_clicked = false;
break;
@@ -698,12 +698,12 @@ static void CreateScenarioWndProc(Window *w, WindowEvent *e)
switch (WP(w, generate_d).widget_id) {
case CSCEN_START_DATE_TEXT:
InvalidateWidget(w, CSCEN_START_DATE_TEXT);
_patches_newgame.starting_year = clamp(value, MIN_YEAR, MAX_YEAR);
w->InvalidateWidget(CSCEN_START_DATE_TEXT);
_patches_newgame.starting_year = Clamp(value, MIN_YEAR, MAX_YEAR);
break;
case CSCEN_FLAT_LAND_HEIGHT_TEXT:
InvalidateWidget(w, CSCEN_FLAT_LAND_HEIGHT_TEXT);
_patches_newgame.se_flat_world_height = clamp(value, 0, MAX_TILE_HEIGHT);
w->InvalidateWidget(CSCEN_FLAT_LAND_HEIGHT_TEXT);
_patches_newgame.se_flat_world_height = Clamp(value, 0, MAX_TILE_HEIGHT);
break;
}

View File

@@ -105,8 +105,8 @@ void GfxFillRect(int left, int top, int right, int bottom, int color)
dst = blitter->MoveTo(dpi->dst_ptr, left, top);
if (!HASBIT(color, PALETTE_MODIFIER_GREYOUT)) {
if (!HASBIT(color, USE_COLORTABLE)) {
if (!HasBit(color, PALETTE_MODIFIER_GREYOUT)) {
if (!HasBit(color, USE_COLORTABLE)) {
blitter->DrawRect(dst, right, bottom, (uint8)color);
} else {
blitter->DrawColorMappingRect(dst, right, bottom, GB(color, 0, PALETTE_WIDTH));
@@ -654,7 +654,7 @@ int DoDrawStringTruncated(const char *str, int x, int y, uint16 color, uint maxw
void DrawSprite(SpriteID img, SpriteID pal, int x, int y, const SubSprite *sub)
{
if (HASBIT(img, PALETTE_MODIFIER_TRANSPARENT)) {
if (HasBit(img, PALETTE_MODIFIER_TRANSPARENT)) {
_color_remap_ptr = GetNonSprite(GB(pal, 0, PALETTE_WIDTH)) + 1;
GfxMainBlitter(GetSprite(GB(img, 0, SPRITE_WIDTH)), x, y, BM_TRANSPARENT, sub);
} else if (pal != PAL_NONE) {
@@ -1015,8 +1015,8 @@ void RedrawScreenRect(int left, int top, int right, int bottom)
void DrawDirtyBlocks()
{
byte *b = _dirty_blocks;
const int w = ALIGN(_screen.width, 64);
const int h = ALIGN(_screen.height, 8);
const int w = Align(_screen.width, 64);
const int h = Align(_screen.height, 8);
int x;
int y;

View File

@@ -375,7 +375,7 @@ static void LoadSpriteTables()
GRFConfig *master = CallocT<GRFConfig>(1);
master->filename = strdup(files->openttd.filename);
FillGRFDetails(master, false);
ClrBitT(master->flags, GCF_INIT_ONLY);
ClrBit(master->flags, GCF_INIT_ONLY);
master->next = top;
_grfconfig = master;

View File

@@ -65,7 +65,7 @@ struct GraphDrawer {
uint height; ///< The height of the graph in pixels.
StringID format_str_y_axis;
byte colors[GRAPH_MAX_DATASETS];
Money cost[GRAPH_MAX_DATASETS][24]; ///< last 2 years
OverflowSafeInt64 cost[GRAPH_MAX_DATASETS][24]; ///< last 2 years
};
static void DrawGraph(const GraphDrawer *gw)
@@ -131,15 +131,15 @@ static void DrawGraph(const GraphDrawer *gw)
highest_value = x_axis_offset * 2;
for (int i = 0; i < gw->num_dataset; i++) {
if (!HASBIT(gw->excluded_data, i)) {
if (!HasBit(gw->excluded_data, i)) {
for (int j = 0; j < gw->num_on_x_axis; j++) {
Money datapoint = gw->cost[i][j];
OverflowSafeInt64 datapoint = gw->cost[i][j];
if (datapoint != INVALID_DATAPOINT) {
/* For now, if the graph has negative values the scaling is
* symmetrical about the x axis, so take the absolute value
* of each data point. */
highest_value = max(highest_value, myabs(datapoint));
highest_value = max(highest_value, abs(datapoint));
}
}
}
@@ -206,7 +206,7 @@ static void DrawGraph(const GraphDrawer *gw)
/* draw lines and dots */
for (int i = 0; i < gw->num_dataset; i++) {
if (!HASBIT(gw->excluded_data, i)) {
if (!HasBit(gw->excluded_data, i)) {
/* Centre the dot between the grid lines. */
x = gw->left + GRAPH_X_POSITION_BEGINNING + (GRAPH_X_POSITION_SEPARATION / 2);
@@ -215,12 +215,31 @@ static void DrawGraph(const GraphDrawer *gw)
uint prev_y = INVALID_DATAPOINT_POS;
for (int j = 0; j < gw->num_on_x_axis; j++) {
Money datapoint = gw->cost[i][j];
OverflowSafeInt64 datapoint = gw->cost[i][j];
if (datapoint != INVALID_DATAPOINT) {
/* XXX: This can overflow if x_axis_offset * datapoint is
* too big to fit in an int64. */
y = gw->top + x_axis_offset - (x_axis_offset * datapoint) / highest_value;
/*
* Check whether we need to reduce the 'accuracy' of the
* datapoint value and the highest value to splut overflows.
* And when 'drawing' 'one million' or 'one million and one'
* there is no significant difference, so the least
* significant bits can just be removed.
*
* If there are more bits needed than would fit in a 32 bits
* integer, so at about 31 bits because of the sign bit, the
* least significant bits are removed.
*/
int mult_range = FindLastBit(x_axis_offset) + FindLastBit(abs(datapoint));
int reduce_range = max(mult_range - 31, 0);
/* Handle negative values differently (don't shift sign) */
if (datapoint < 0) {
datapoint = -(abs(datapoint) >> reduce_range);
} else {
datapoint >>= reduce_range;
}
y = gw->top + x_axis_offset - (x_axis_offset * datapoint) / (highest_value >> reduce_range);
/* Draw the point. */
GfxFillRect(x - 1, y - 1, x + 1, y + 1, color);
@@ -250,7 +269,7 @@ static void GraphLegendWndProc(Window *w, WindowEvent *e)
switch (e->event) {
case WE_CREATE:
for (uint i = 3; i < w->widget_count; i++) {
if (!HASBIT(_legend_excluded_players, i - 3)) LowerWindowWidget(w, i);
if (!HasBit(_legend_excluded_players, i - 3)) w->LowerWidget(i);
}
break;
@@ -260,8 +279,8 @@ static void GraphLegendWndProc(Window *w, WindowEvent *e)
FOR_ALL_PLAYERS(p) {
if (p->is_active) continue;
SETBIT(_legend_excluded_players, p->index);
RaiseWindowWidget(w, p->index + 3);
SetBit(_legend_excluded_players, p->index);
w->RaiseWidget(p->index + 3);
}
DrawWindowWidgets(w);
@@ -273,16 +292,16 @@ static void GraphLegendWndProc(Window *w, WindowEvent *e)
SetDParam(0, p->index);
SetDParam(1, p->index);
DrawString(21, 17 + p->index * 12, STR_7021, HASBIT(_legend_excluded_players, p->index) ? TC_BLACK : TC_WHITE);
DrawString(21, 17 + p->index * 12, STR_7021, HasBit(_legend_excluded_players, p->index) ? TC_BLACK : TC_WHITE);
}
break;
}
case WE_CLICK:
if (!IS_INT_INSIDE(e->we.click.widget, 3, 11)) return;
if (!IsInsideMM(e->we.click.widget, 3, 11)) return;
TOGGLEBIT(_legend_excluded_players, e->we.click.widget - 3);
ToggleWidgetLoweredState(w, e->we.click.widget);
ToggleBit(_legend_excluded_players, e->we.click.widget - 3);
w->ToggleWidgetLoweredState(e->we.click.widget);
SetWindowDirty(w);
InvalidateWindow(WC_INCOME_GRAPH, 0);
InvalidateWindow(WC_OPERATING_PROFIT, 0);
@@ -334,7 +353,7 @@ static void SetupGraphDrawerForPlayers(GraphDrawer *gd)
/* Exclude the players which aren't valid */
FOR_ALL_PLAYERS(p) {
if (!p->is_active) SETBIT(excluded_players, p->index);
if (!p->is_active) SetBit(excluded_players, p->index);
}
gd->excluded_data = excluded_players;
gd->num_vert_lines = 24;
@@ -733,7 +752,7 @@ static void CargoPaymentRatesWndProc(Window *w, WindowEvent *e)
* both the text and the colored box have to be manually painted.
* clk_dif will move one pixel down and one pixel to the right
* when the button is clicked */
byte clk_dif = IsWindowWidgetLowered(w, i + 3) ? 1 : 0;
byte clk_dif = w->IsWidgetLowered(i + 3) ? 1 : 0;
GfxFillRect(x + clk_dif, y + clk_dif, x + 8 + clk_dif, y + 5 + clk_dif, 0);
GfxFillRect(x + 1 + clk_dif, y + 1 + clk_dif, x + 7 + clk_dif, y + 4 + clk_dif, cs->legend_colour);
@@ -760,8 +779,8 @@ static void CargoPaymentRatesWndProc(Window *w, WindowEvent *e)
case WE_CLICK:
if (e->we.click.widget >= 3) {
TOGGLEBIT(_legend_excluded_cargo, e->we.click.widget - 3);
ToggleWidgetLoweredState(w, e->we.click.widget);
ToggleBit(_legend_excluded_cargo, e->we.click.widget - 3);
w->ToggleWidgetLoweredState(e->we.click.widget);
SetWindowDirty(w);
}
break;
@@ -816,7 +835,7 @@ void ShowCargoPaymentRates()
wi->data = 0;
wi->tooltips = STR_7064_TOGGLE_GRAPH_FOR_CARGO;
if (!HASBIT(_legend_excluded_cargo, i)) LowerWindowWidget(w, i + 3);
if (!HasBit(_legend_excluded_cargo, i)) w->LowerWidget(i + 3);
}
SetWindowDirty(w);
@@ -932,8 +951,8 @@ static void PerformanceRatingDetailWndProc(Window *w, WindowEvent *e)
if (_performance_rating_detail_player == INVALID_PLAYER || !GetPlayer(_performance_rating_detail_player)->is_active) {
if (_performance_rating_detail_player != INVALID_PLAYER) {
/* Raise and disable the widget for the previous selection. */
RaiseWindowWidget(w, _performance_rating_detail_player + 13);
DisableWindowWidget(w, _performance_rating_detail_player + 13);
w->RaiseWidget(_performance_rating_detail_player + 13);
w->DisableWidget(_performance_rating_detail_player + 13);
SetWindowDirty(w);
_performance_rating_detail_player = INVALID_PLAYER;
@@ -942,7 +961,7 @@ static void PerformanceRatingDetailWndProc(Window *w, WindowEvent *e)
for (PlayerID i = PLAYER_FIRST; i < MAX_PLAYERS; i++) {
if (GetPlayer(i)->is_active) {
/* Lower the widget corresponding to this player. */
LowerWindowWidget(w, i + 13);
w->LowerWidget(i + 13);
SetWindowDirty(w);
_performance_rating_detail_player = i;
@@ -958,9 +977,9 @@ static void PerformanceRatingDetailWndProc(Window *w, WindowEvent *e)
for (PlayerID i = PLAYER_FIRST; i < MAX_PLAYERS; i++) {
if (!GetPlayer(i)->is_active) {
/* Check if we have the player as an active player */
if (!IsWindowWidgetDisabled(w, i + 13)) {
if (!w->IsWidgetDisabled(i + 13)) {
/* Bah, player gone :( */
DisableWindowWidget(w, i + 13);
w->DisableWidget(i + 13);
/* We need a repaint */
SetWindowDirty(w);
@@ -969,9 +988,9 @@ static void PerformanceRatingDetailWndProc(Window *w, WindowEvent *e)
}
/* Check if we have the player marked as inactive */
if (IsWindowWidgetDisabled(w, i + 13)) {
if (w->IsWidgetDisabled(i + 13)) {
/* New player! Yippie :p */
EnableWindowWidget(w, i + 13);
w->EnableWidget(i + 13);
/* We need a repaint */
SetWindowDirty(w);
}
@@ -1006,7 +1025,7 @@ static void PerformanceRatingDetailWndProc(Window *w, WindowEvent *e)
DrawStringRightAligned(107, y, SET_PERFORMANCE_DETAIL_INT, TC_FROMSTRING);
/* Calculate the %-bar */
x = clamp(val, 0, needed) * 50 / needed;
x = Clamp(val, 0, needed) * 50 / needed;
/* SCORE_LOAN is inversed */
if (val < 0 && i == SCORE_LOAN) x = 0;
@@ -1016,7 +1035,7 @@ static void PerformanceRatingDetailWndProc(Window *w, WindowEvent *e)
if (x != 50) GfxFillRect(112 + x, y - 2, 112 + 50, y + 10, color_notdone);
/* Calculate the % */
x = clamp(val, 0, needed) * 100 / needed;
x = Clamp(val, 0, needed) * 100 / needed;
/* SCORE_LOAN is inversed */
if (val < 0 && i == SCORE_LOAN) x = 0;
@@ -1050,12 +1069,12 @@ static void PerformanceRatingDetailWndProc(Window *w, WindowEvent *e)
case WE_CLICK:
/* Check which button is clicked */
if (IS_INT_INSIDE(e->we.click.widget, 13, 21)) {
if (IsInsideMM(e->we.click.widget, 13, 21)) {
/* Is it no on disable? */
if (!IsWindowWidgetDisabled(w, e->we.click.widget)) {
RaiseWindowWidget(w, _performance_rating_detail_player + 13);
if (!w->IsWidgetDisabled(e->we.click.widget)) {
w->RaiseWidget(_performance_rating_detail_player + 13);
_performance_rating_detail_player = (PlayerID)(e->we.click.widget - 13);
LowerWindowWidget(w, _performance_rating_detail_player + 13);
w->LowerWidget(_performance_rating_detail_player + 13);
SetWindowDirty(w);
}
}
@@ -1066,7 +1085,7 @@ static void PerformanceRatingDetailWndProc(Window *w, WindowEvent *e)
/* Disable the players who are not active */
for (PlayerID i = PLAYER_FIRST; i < MAX_PLAYERS; i++) {
SetWindowWidgetDisabledState(w, i + 13, !GetPlayer(i)->is_active);
w->SetWidgetDisabledState(i + 13, !GetPlayer(i)->is_active);
}
/* Update all player stats with the current data
* (this is because _score_info is not saved to a savegame) */
@@ -1077,7 +1096,7 @@ static void PerformanceRatingDetailWndProc(Window *w, WindowEvent *e)
w->custom[0] = DAY_TICKS;
w->custom[1] = 5;
if (_performance_rating_detail_player != INVALID_PLAYER) LowerWindowWidget(w, _performance_rating_detail_player + 13);
if (_performance_rating_detail_player != INVALID_PLAYER) w->LowerWidget(_performance_rating_detail_player + 13);
SetWindowDirty(w);
break;

View File

@@ -339,7 +339,7 @@ CommandCost CmdSetGroupReplaceProtection(TileIndex tile, uint32 flags, uint32 p1
if (g->owner != _current_player) return CMD_ERROR;
if (flags & DC_EXEC) {
g->replace_protection = HASBIT(p2, 0);
g->replace_protection = HasBit(p2, 0);
InvalidateWindowData(GetWCForVT(g->vehicle_type), (g->vehicle_type << 11) | VLW_GROUP_LIST | _current_player);
}

View File

@@ -43,9 +43,6 @@ static void BuildGroupList(grouplist_d* gl, PlayerID owner, VehicleType vehicle_
if (!(gl->l.flags & VL_REBUILD)) return;
list = MallocT<const Group*>(GetGroupArraySize());
if (list == NULL) {
error("Could not allocate memory for the group-sorting-list");
}
FOR_ALL_GROUPS(g) {
if (g->owner == owner && g->vehicle_type == vehicle_type) list[n++] = g;
@@ -53,9 +50,6 @@ static void BuildGroupList(grouplist_d* gl, PlayerID owner, VehicleType vehicle_
free((void*)gl->sort_list);
gl->sort_list = MallocT<const Group *>(n);
if (n != 0 && gl->sort_list == NULL) {
error("Could not allocate memory for the group-sorting-list");
}
gl->l.list_length = n;
for (uint i = 0; i < n; ++i) gl->sort_list[i] = list[i];
@@ -143,9 +137,9 @@ static const Widget _group_widgets[] = {
{ WWT_STICKYBOX, RESIZE_LR, 14, 448, 459, 0, 13, 0x0, STR_STICKY_BUTTON},
{ WWT_PANEL, RESIZE_NONE, 14, 0, 200, 14, 25, 0x0, STR_NULL},
{ WWT_PANEL, RESIZE_NONE, 14, 0, 200, 26, 38, 0x0, STR_NULL},
{ WWT_PANEL, RESIZE_NONE, 14, 0, 200, 39, 52, 0x0, STR_NULL},
{ WWT_PANEL, RESIZE_NONE, 14, 0, 200, 39, 51, 0x0, STR_NULL},
{ WWT_MATRIX, RESIZE_BOTTOM, 14, 0, 188, 52, 168, 0x701, STR_GROUPS_CLICK_ON_GROUP_FOR_TIP},
{ WWT_SCROLLBAR, RESIZE_BOTTOM, 14, 189, 200, 26, 168, 0x0, STR_0190_SCROLL_BAR_SCROLLS_LIST},
{ WWT_SCROLLBAR, RESIZE_BOTTOM, 14, 189, 200, 52, 168, 0x0, STR_0190_SCROLL_BAR_SCROLLS_LIST},
{ WWT_PUSHTXTBTN, RESIZE_NONE, 14, 201, 281, 14, 25, STR_SORT_BY, STR_SORT_ORDER_TIP},
{ WWT_PANEL, RESIZE_NONE, 14, 282, 435, 14, 25, 0x0, STR_SORT_CRITERIA_TIP},
{ WWT_TEXTBTN, RESIZE_NONE, 14, 436, 447, 14, 25, STR_0225, STR_SORT_CRITERIA_TIP},
@@ -266,7 +260,7 @@ static void CreateVehicleGroupWindow(Window *w)
*/
static void UpdateGroupActionDropdown(Window *w, GroupID gid, bool refresh = true)
{
if (refresh && !IsWindowWidgetLowered(w, GRP_WIDGET_MANAGE_VEHICLES_DROPDOWN)) return;
if (refresh && !w->IsWidgetLowered(GRP_WIDGET_MANAGE_VEHICLES_DROPDOWN)) return;
static StringID action_str[] = {
STR_REPLACE_VEHICLES,
@@ -329,8 +323,8 @@ static void GroupWndProc(Window *w, WindowEvent *e)
SetVScroll2Count(w, gv->l.list_length);
/* The drop down menu is out, *but* it may not be used, retract it. */
if (gv->l.list_length == 0 && IsWindowWidgetLowered(w, GRP_WIDGET_MANAGE_VEHICLES_DROPDOWN)) {
RaiseWindowWidget(w, GRP_WIDGET_MANAGE_VEHICLES_DROPDOWN);
if (gv->l.list_length == 0 && w->IsWidgetLowered(GRP_WIDGET_MANAGE_VEHICLES_DROPDOWN)) {
w->RaiseWidget(GRP_WIDGET_MANAGE_VEHICLES_DROPDOWN);
Window **w2;
FOR_ALL_WINDOWS(w2) {
if (w->window_class == WP(*w2, dropdown_d).parent_wnd_class &&
@@ -342,7 +336,7 @@ static void GroupWndProc(Window *w, WindowEvent *e)
}
/* Disable all lists management button when the list is empty */
SetWindowWidgetsDisabledState(w, gv->l.list_length == 0 || _local_player != owner,
w->SetWidgetsDisabledState(gv->l.list_length == 0 || _local_player != owner,
GRP_WIDGET_STOP_ALL,
GRP_WIDGET_START_ALL,
GRP_WIDGET_MANAGE_VEHICLES,
@@ -350,7 +344,7 @@ static void GroupWndProc(Window *w, WindowEvent *e)
WIDGET_LIST_END);
/* Disable the group specific function when we select the default group or all vehicles */
SetWindowWidgetsDisabledState(w, IsDefaultGroupID(gv->group_sel) || IsAllGroupID(gv->group_sel) || _local_player != owner,
w->SetWidgetsDisabledState(IsDefaultGroupID(gv->group_sel) || IsAllGroupID(gv->group_sel) || _local_player != owner,
GRP_WIDGET_DELETE_GROUP,
GRP_WIDGET_RENAME_GROUP,
GRP_WIDGET_REPLACE_PROTECTION,
@@ -362,7 +356,7 @@ static void GroupWndProc(Window *w, WindowEvent *e)
* verify, whether you are the owner of the vehicle,
* so it doesn't have to be disabled
*/
SetWindowWidgetsDisabledState(w, _local_player != owner,
w->SetWidgetsDisabledState(_local_player != owner,
GRP_WIDGET_CREATE_GROUP,
GRP_WIDGET_AVAILABLE_VEHICLES,
WIDGET_LIST_END);

View File

@@ -12,6 +12,7 @@
template <typename T> FORCEINLINE T* MallocT(size_t num_elements)
{
T *t_ptr = (T*)malloc(num_elements * sizeof(T));
if (t_ptr == NULL && num_elements != 0) error("Out of memory. Cannot allocate %i bytes", num_elements * sizeof(T));
return t_ptr;
}
/** When allocating using malloc/calloc in C++ it is usually needed to cast the return value
@@ -19,6 +20,7 @@ template <typename T> FORCEINLINE T* MallocT(size_t num_elements)
template <typename T> FORCEINLINE T* CallocT(size_t num_elements)
{
T *t_ptr = (T*)calloc(num_elements, sizeof(T));
if (t_ptr == NULL && num_elements != 0) error("Out of memory. Cannot allocate %i bytes", num_elements * sizeof(T));
return t_ptr;
}
/** When allocating using malloc/calloc in C++ it is usually needed to cast the return value
@@ -26,6 +28,7 @@ template <typename T> FORCEINLINE T* CallocT(size_t num_elements)
template <typename T> FORCEINLINE T* ReallocT(T* t_ptr, size_t num_elements)
{
t_ptr = (T*)realloc(t_ptr, num_elements * sizeof(T));
if (t_ptr == NULL && num_elements != 0) error("Out of memory. Cannot reallocate %i bytes", num_elements * sizeof(T));
return t_ptr;
}
@@ -39,11 +42,6 @@ template<typename T> void Swap(T& a, T& b)
}
/** returns the absolute value of (scalar) variable. @note assumes variable to be signed */
template <typename T> static inline T myabs(T a) { return a < (T)0 ? -a : a; }
/** returns the (absolute) difference between two (scalar) variables */
template <typename T> static inline T delta(T a, T b) { return a < b ? b - a : a - b; }
/** Some enums need to have allowed incrementing (i.e. StationClassID) */
#define DECLARE_POSTFIX_INCREMENT(type) \
FORCEINLINE type operator ++(type& e, int) \
@@ -151,21 +149,6 @@ template <typename Tenum_t> struct TinyEnumT
}
};
template <typename T> void ClrBitT(T &t, int bit_index)
{
t = (T)(t & ~((T)1 << bit_index));
}
template <typename T> void SetBitT(T &t, int bit_index)
{
t = (T)(t | ((T)1 << bit_index));
}
template <typename T> void ToggleBitT(T &t, int bit_index)
{
t = (T)(t ^ ((T)1 << bit_index));
}
/**
* Overflow safe template for integers, i.e. integers that will never overflow
* you multiply the maximum value with 2, or add 2, or substract somethng from
@@ -198,7 +181,7 @@ public:
*/
FORCEINLINE OverflowSafeInt& operator += (const OverflowSafeInt& other)
{
if ((T_MAX - myabs(other.m_value)) < myabs(this->m_value) &&
if ((T_MAX - abs(other.m_value)) < abs(this->m_value) &&
(this->m_value < 0) == (other.m_value < 0)) {
this->m_value = (this->m_value < 0) ? T_MIN : T_MAX ;
} else {
@@ -229,7 +212,7 @@ public:
*/
FORCEINLINE OverflowSafeInt& operator *= (const int factor)
{
if (factor != 0 && (T_MAX / myabs(factor)) < myabs(this->m_value)) {
if (factor != 0 && (T_MAX / abs(factor)) < abs(this->m_value)) {
this->m_value = ((this->m_value < 0) == (factor < 0)) ? T_MAX : T_MIN ;
} else {
this->m_value *= factor ;

View File

@@ -161,7 +161,8 @@ struct GRFFileProps {
struct IndustrySpec {
const IndustryTileTable *const *table;///< List of the tiles composing the industry
byte num_table; ///< Number of elements in the table
uint8 cost_multiplier; ///< Base cost multiplier.
uint8 cost_multiplier; ///< Base construction cost multiplier.
uint32 removal_cost_multiplier; ///< Base removal cost multiplier.
uint16 raw_industry_cost_multiplier; ///< Multiplier for the raw industries cost
uint32 prospecting_chance; ///< Chance prospecting succeeds
IndustryType conflicting[3]; ///< Industries this industry cannot be close to
@@ -202,6 +203,14 @@ struct IndustrySpec {
* @return the cost (inflation corrected etc)
*/
Money GetConstructionCost() const;
/**
* Get the cost for removing this industry
* Take note that the cost will always be zero for non-grf industries.
* Only if the grf author did specified a cost will it be applicable.
* @return the cost (inflation corrected etc)
*/
Money GetRemovalCost() const;
};
/**

View File

@@ -40,6 +40,7 @@
#include "misc/autoptr.hpp"
#include "autoslope.h"
#include "transparency.h"
#include "water.h"
void ShowIndustryViewWindow(int industry);
void BuildOilRig(TileIndex tile);
@@ -68,7 +69,7 @@ void ResetIndustries()
/* once performed, enable only the current climate industries */
for (IndustryType i = 0; i < NUM_INDUSTRYTYPES; i++) {
_industry_specs[i].enabled = i < NEW_INDUSTRYOFFSET &&
HASBIT(_origin_industry_specs[i].climate_availability, _opt.landscape);
HasBit(_origin_industry_specs[i].climate_availability, _opt.landscape);
}
memset(&_industry_tile_specs, 0, sizeof(_industry_tile_specs));
@@ -290,7 +291,7 @@ static void DrawTile_Industry(TileInfo *ti)
GetIndustryConstructionStage(ti->tile))];
image = dits->ground.sprite;
if (HASBIT(image, PALETTE_MODIFIER_COLOR) && dits->ground.pal == PAL_NONE) {
if (HasBit(image, PALETTE_MODIFIER_COLOR) && dits->ground.pal == PAL_NONE) {
pal = GENERAL_SPRITE_COLOR(ind->random_color);
} else {
pal = dits->ground.pal;
@@ -305,7 +306,7 @@ static void DrawTile_Industry(TileInfo *ti)
image = dits->building.sprite;
if (image != 0) {
AddSortableSpriteToDraw(image,
(HASBIT(image, PALETTE_MODIFIER_COLOR) && dits->building.pal == PAL_NONE) ? GENERAL_SPRITE_COLOR(ind->random_color) : dits->building.pal,
(HasBit(image, PALETTE_MODIFIER_COLOR) && dits->building.pal == PAL_NONE) ? GENERAL_SPRITE_COLOR(ind->random_color) : dits->building.pal,
ti->x + dits->subtile_x,
ti->y + dits->subtile_y,
dits->width,
@@ -346,7 +347,7 @@ static void GetAcceptedCargo_Industry(TileIndex tile, AcceptedCargo ac)
const CargoID *accepts_cargo = itspec->accepts_cargo;
const uint8 *acceptance = itspec->acceptance;
if (HASBIT(itspec->callback_flags, CBM_INDT_ACCEPT_CARGO)) {
if (HasBit(itspec->callback_flags, CBM_INDT_ACCEPT_CARGO)) {
uint16 res = GetIndustryTileCallback(CBID_INDTILE_ACCEPT_CARGO, 0, 0, gfx, GetIndustryByTile(tile), tile);
if (res != CALLBACK_FAILED) {
accepts_cargo = raw_accepts_cargo;
@@ -354,7 +355,7 @@ static void GetAcceptedCargo_Industry(TileIndex tile, AcceptedCargo ac)
}
}
if (HASBIT(itspec->callback_flags, CBM_INDT_CARGO_ACCEPTANCE)) {
if (HasBit(itspec->callback_flags, CBM_INDT_CARGO_ACCEPTANCE)) {
uint16 res = GetIndustryTileCallback(CBID_INDTILE_CARGO_ACCEPTANCE, 0, 0, gfx, GetIndustryByTile(tile), tile);
if (res != CALLBACK_FAILED) {
acceptance = raw_acceptance;
@@ -400,7 +401,7 @@ static CommandCost ClearTile_Industry(TileIndex tile, byte flags)
}
if (flags & DC_EXEC) delete i;
return CommandCost();
return CommandCost(indspec->GetRemovalCost());
}
static void TransportIndustryGoods(TileIndex tile)
@@ -557,7 +558,7 @@ static void AnimateTile_Industry(TileIndex tile)
case GFX_OILWELL_ANIMATED_2:
case GFX_OILWELL_ANIMATED_3:
if ((_tick_counter & 7) == 0) {
bool b = CHANCE16(1, 7);
bool b = Chance16(1, 7);
IndustryGfx gfx = GetIndustryGfx(tile);
m = GetIndustryAnimationState(tile) + 1;
@@ -737,7 +738,7 @@ static void TileLoop_Industry(TileIndex tile)
case GFX_COAL_MINE_TOWER_NOT_ANIMATED:
case GFX_COPPER_MINE_TOWER_NOT_ANIMATED:
case GFX_GOLD_MINE_TOWER_NOT_ANIMATED:
if (!(_tick_counter & 0x400) && CHANCE16(1, 2)) {
if (!(_tick_counter & 0x400) && Chance16(1, 2)) {
switch (gfx) {
case GFX_COAL_MINE_TOWER_NOT_ANIMATED: gfx = GFX_COAL_MINE_TOWER_ANIMATED; break;
case GFX_COPPER_MINE_TOWER_NOT_ANIMATED: gfx = GFX_COPPER_MINE_TOWER_ANIMATED; break;
@@ -750,7 +751,7 @@ static void TileLoop_Industry(TileIndex tile)
break;
case GFX_OILWELL_NOT_ANIMATED:
if (CHANCE16(1, 6)) {
if (Chance16(1, 6)) {
SetIndustryGfx(tile, GFX_OILWELL_ANIMATED_1);
SetIndustryAnimationState(tile, 0);
AddAnimatedTile(tile);
@@ -774,7 +775,7 @@ static void TileLoop_Industry(TileIndex tile)
break;
case GFX_POWERPLANT_SPARKS:
if (CHANCE16(1, 3)) {
if (Chance16(1, 3)) {
SndPlayTileFx(SND_0C_ELECTRIC_SPARK, tile);
AddAnimatedTile(tile);
}
@@ -804,7 +805,7 @@ static void TileLoop_Industry(TileIndex tile)
break;
case GFX_SUGAR_MINE_SIEVE:
if (CHANCE16(1, 3)) AddAnimatedTile(tile);
if (Chance16(1, 3)) AddAnimatedTile(tile);
break;
}
}
@@ -862,7 +863,7 @@ static void SetupFarmFieldFence(TileIndex tile, int size, byte type, Axis direct
if (IsTileType(tile, MP_CLEAR) || IsTileType(tile, MP_TREES)) {
byte or_ = type;
if (or_ == 1 && CHANCE16(1, 7)) or_ = 2;
if (or_ == 1 && Chance16(1, 7)) or_ = 2;
if (direction == AXIS_X) {
SetFenceSE(tile, or_);
@@ -989,7 +990,7 @@ static void ProduceIndustryGoods(Industry *i)
/* play a sound? */
if ((i->counter & 0x3F) == 0) {
if (CHANCE16R(1, 14, r) && (num = indsp->number_of_sounds) != 0) {
if (Chance16R(1, 14, r) && (num = indsp->number_of_sounds) != 0) {
SndPlayTileFx(
(SoundFx)(indsp->random_sounds[((r >> 16) * num) >> 16]),
i->xy);
@@ -1000,7 +1001,7 @@ static void ProduceIndustryGoods(Industry *i)
/* produce some cargo */
if ((i->counter & 0xFF) == 0) {
if (HASBIT(indsp->callback_flags, CBM_IND_PRODUCTION_256_TICKS)) IndustryProductionCallback(i, 1);
if (HasBit(indsp->callback_flags, CBM_IND_PRODUCTION_256_TICKS)) IndustryProductionCallback(i, 1);
IndustryBehaviour indbehav = indsp->behaviour;
i->produced_cargo_waiting[0] = min(0xffff, i->produced_cargo_waiting[0] + i->production_rate[0]);
@@ -1008,17 +1009,17 @@ static void ProduceIndustryGoods(Industry *i)
if ((indbehav & INDUSTRYBEH_PLANT_FIELDS) != 0) {
bool plant;
if (HASBIT(indsp->callback_flags, CBM_IND_SPECIAL_EFFECT)) {
if (HasBit(indsp->callback_flags, CBM_IND_SPECIAL_EFFECT)) {
plant = (GetIndustryCallback(CBID_INDUSTRY_SPECIAL_EFFECT, Random(), 0, i, i->type, i->xy) != 0);
} else {
plant = CHANCE16(1, 8);
plant = Chance16(1, 8);
}
if (plant) PlantRandomFarmField(i);
}
if ((indbehav & INDUSTRYBEH_CUT_TREES) != 0) {
bool cut = ((i->counter & 0x1FF) == 0);
if (HASBIT(indsp->callback_flags, CBM_IND_SPECIAL_EFFECT)) {
if (HasBit(indsp->callback_flags, CBM_IND_SPECIAL_EFFECT)) {
cut = (GetIndustryCallback(CBID_INDUSTRY_SPECIAL_EFFECT, 0, 1, i, i->type, i->xy) != 0);
}
@@ -1183,14 +1184,14 @@ bool IsSlopeRefused(Slope current, Slope refused)
{
if (IsSteepSlope(current)) return true;
if (current != SLOPE_FLAT) {
if (refused & SLOPE_STEEP) return true;
if (IsSteepSlope(refused)) return true;
Slope t = ComplementSlope(current);
if (refused & 1 && (t & SLOPE_NW)) return false;
if (refused & 2 && (t & SLOPE_NE)) return false;
if (refused & 4 && (t & SLOPE_SW)) return false;
if (refused & 8 && (t & SLOPE_SE)) return false;
if (refused & SLOPE_W && (t & SLOPE_NW)) return true;
if (refused & SLOPE_S && (t & SLOPE_NE)) return true;
if (refused & SLOPE_E && (t & SLOPE_SW)) return true;
if (refused & SLOPE_N && (t & SLOPE_SE)) return true;
}
return false;
@@ -1225,9 +1226,9 @@ static bool CheckIfIndustryTilesAreFree(TileIndex tile, const IndustryTileTable
IndustryBehaviour ind_behav = GetIndustrySpec(type)->behaviour;
/* Perform land/water check if not disabled */
if (!HASBIT(its->slopes_refused, 5) && (IsWaterTile(cur_tile) == !(ind_behav & INDUSTRYBEH_BUILT_ONWATER))) return false;
if (!HasBit(its->slopes_refused, 5) && (IsWaterTile(cur_tile) == !(ind_behav & INDUSTRYBEH_BUILT_ONWATER))) return false;
if (HASBIT(its->callback_flags, CBM_INDT_SHAPE_CHECK)) {
if (HasBit(its->callback_flags, CBM_INDT_SHAPE_CHECK)) {
custom_shape = true;
if (!PerformIndustryTileSlopeCheck(tile, cur_tile, its, type, gfx, itspec_index)) return false;
} else {
@@ -1235,9 +1236,9 @@ static bool CheckIfIndustryTilesAreFree(TileIndex tile, const IndustryTileTable
refused_slope |= IsSlopeRefused(tileh, its->slopes_refused);
}
if (ind_behav & (INDUSTRYBEH_ONLY_INTOWN | INDUSTRYBEH_TOWN1200_MORE)) {
if (ind_behav & (INDUSTRYBEH_ONLY_INTOWN)) {
if (!IsTileType(cur_tile, MP_HOUSE)) {
_error_message = STR_029D_CAN_ONLY_BE_BUILT_IN_TOWNS;
_error_message = STR_030D_CAN_ONLY_BE_BUILT_IN_TOWNS;
return false;
}
if (CmdFailed(DoCommand(cur_tile, 0, 0, 0, CMD_LANDSCAPE_CLEAR))) return false;
@@ -1252,7 +1253,7 @@ static bool CheckIfIndustryTilesAreFree(TileIndex tile, const IndustryTileTable
/* It is almost impossible to have a fully flat land in TG, so what we
* do is that we check if we can make the land flat later on. See
* CheckIfCanLevelIndustryPlatform(). */
return !refused_slope || (_patches.land_generator == LG_TERRAGENESIS && _generating_world && !custom_shape);
return !refused_slope || (_patches.land_generator == LG_TERRAGENESIS && _generating_world && !custom_shape && !_ignore_restrictions);
}
static bool CheckIfIndustryIsAllowed(TileIndex tile, int type, const Town *t)
@@ -1289,7 +1290,7 @@ static bool CheckCanTerraformSurroundingTiles(TileIndex tile, uint height, int i
return false;
/* Don't allow too big of a change if this is the sub-tile check */
if (internal != 0 && delta(curh, height) > 1) return false;
if (internal != 0 && Delta(curh, height) > 1) return false;
/* Different height, so the surrounding tiles of this tile
* has to be correct too (in level, or almost in level)
@@ -1428,8 +1429,11 @@ static void DoCreateNewIndustry(Industry *i, TileIndex tile, int type, const Ind
i->production_rate[0] = indspec->production_rate[0];
i->production_rate[1] = indspec->production_rate[1];
/* don't use smooth economy for industries using production callbacks */
if (_patches.smooth_economy && !(HASBIT(indspec->callback_flags, CBM_IND_PRODUCTION_256_TICKS) || HASBIT(indspec->callback_flags, CBM_IND_PRODUCTION_CARGO_ARRIVAL))) {
/* don't use smooth economy for industries using production related callbacks */
if (_patches.smooth_economy &&
!(HasBit(indspec->callback_flags, CBM_IND_PRODUCTION_256_TICKS) || HasBit(indspec->callback_flags, CBM_IND_PRODUCTION_CARGO_ARRIVAL)) && // production callbacks
!(HasBit(indspec->callback_flags, CBM_IND_MONTHLYPROD_CHANGE) || HasBit(indspec->callback_flags, CBM_IND_PRODUCTION_CHANGE)) // production change callbacks
) {
i->production_rate[0] = min((RandomRange(256) + 128) * i->production_rate[0] >> 8 , 255);
i->production_rate[1] = min((RandomRange(256) + 128) * i->production_rate[1] >> 8 , 255);
}
@@ -1460,12 +1464,12 @@ static void DoCreateNewIndustry(Industry *i, TileIndex tile, int type, const Ind
i->last_month_production[1] = i->production_rate[1] * 8;
i->founder = _current_player;
if (HASBIT(indspec->callback_flags, CBM_IND_DECIDE_COLOUR)) {
if (HasBit(indspec->callback_flags, CBM_IND_DECIDE_COLOUR)) {
uint16 res = GetIndustryCallback(CBID_INDUSTRY_DECIDE_COLOUR, 0, 0, i, type, INVALID_TILE);
if (res != CALLBACK_FAILED) i->random_color = GB(res, 0, 4);
}
if (HASBIT(indspec->callback_flags, CBM_IND_INPUT_CARGO_TYPES)) {
if (HasBit(indspec->callback_flags, CBM_IND_INPUT_CARGO_TYPES)) {
for (j = 0; j < lengthof(i->accepts_cargo); j++) i->accepts_cargo[j] = CT_INVALID;
for (j = 0; j < lengthof(i->accepts_cargo); j++) {
uint16 res = GetIndustryCallback(CBID_INDUSTRY_INPUT_CARGO_TYPES, j, 0, i, type, INVALID_TILE);
@@ -1474,7 +1478,7 @@ static void DoCreateNewIndustry(Industry *i, TileIndex tile, int type, const Ind
}
}
if (HASBIT(indspec->callback_flags, CBM_IND_OUTPUT_CARGO_TYPES)) {
if (HasBit(indspec->callback_flags, CBM_IND_OUTPUT_CARGO_TYPES)) {
for (j = 0; j < lengthof(i->produced_cargo); j++) i->produced_cargo[j] = CT_INVALID;
for (j = 0; j < lengthof(i->produced_cargo); j++) {
uint16 res = GetIndustryCallback(CBID_INDUSTRY_OUTPUT_CARGO_TYPES, j, 0, i, type, INVALID_TILE);
@@ -1548,13 +1552,13 @@ static Industry *CreateNewIndustryHelper(TileIndex tile, IndustryType type, uint
if (!CheckIfIndustryTilesAreFree(tile, it, itspec_index, type, &custom_shape_check)) return NULL;
if (HASBIT(GetIndustrySpec(type)->callback_flags, CBM_IND_LOCATION)) {
if (HasBit(GetIndustrySpec(type)->callback_flags, CBM_IND_LOCATION)) {
if (!CheckIfCallBackAllowsCreation(tile, type, itspec_index)) return NULL;
} else {
if (!_check_new_industry_procs[indspec->check_proc](tile)) return NULL;
}
if (!custom_shape_check && _patches.land_generator == LG_TERRAGENESIS && _generating_world && !CheckIfCanLevelIndustryPlatform(tile, 0, it, type)) return NULL;
if (!custom_shape_check && _patches.land_generator == LG_TERRAGENESIS && _generating_world && !_ignore_restrictions && !CheckIfCanLevelIndustryPlatform(tile, 0, it, type)) return NULL;
if (!CheckIfTooCloseToIndustry(tile, type)) return NULL;
const Town *t = CheckMultipleIndustryInTown(tile, type);
@@ -1628,7 +1632,7 @@ CommandCost CmdBuildIndustry(TileIndex tile, uint32 flags, uint32 p1, uint32 p2)
} else {
int count = indspec->num_table;
const IndustryTileTable * const *itt = indspec->table;
int num = clamp(p2, 0, count - 1);
int num = Clamp(p2, 0, count - 1);
_error_message = STR_0239_SITE_UNSUITABLE;
do {
@@ -1873,7 +1877,7 @@ static void CanCargoServiceIndustry(CargoID cargo, Industry *ind, bool *c_accept
/* Check for acceptance of cargo */
for (uint j = 0; j < lengthof(ind->accepts_cargo) && ind->accepts_cargo[j] != CT_INVALID; j++) {
if (cargo == ind->accepts_cargo[j]) {
if (HASBIT(indspec->callback_flags, CBM_IND_REFUSE_CARGO)) {
if (HasBit(indspec->callback_flags, CBM_IND_REFUSE_CARGO)) {
uint16 res = GetIndustryCallback(CBID_INDUSTRY_REFUSE_CARGO,
0, GetReverseCargoTranslation(cargo, indspec->grf_prop.grffile),
ind, ind->type, ind->xy);
@@ -1940,13 +1944,13 @@ int WhoCanServiceIndustry(Industry* ind)
*/
const Order *o;
FOR_VEHICLE_ORDERS(v, o) {
if (o->type == OT_GOTO_STATION && !HASBIT(o->flags, OFB_TRANSFER)) {
if (o->type == OT_GOTO_STATION && !HasBit(o->flags, OFB_TRANSFER)) {
/* Vehicle visits a station to load or unload */
Station *st = GetStation(o->dest);
if (!st->IsValid()) continue;
/* Same cargo produced by industry is dropped here => not serviced by vehicle v */
if (HASBIT(o->flags, OFB_UNLOAD) && !c_accepts) break;
if (HasBit(o->flags, OFB_UNLOAD) && !c_accepts) break;
if (stations.find(st) != stations.end()) {
if (v->owner == _local_player) return 2; // Player services industry
@@ -1985,6 +1989,10 @@ static void ReportNewsProductionChangeIndustry(Industry *ind, CargoID type, int
);
}
enum {
PERCENT_TRANSPORTED_60 = 153,
};
/** Change industry production or do closure
* @param i Industry for which changes are performed
* @param monthly true if it's the monthly call, false if it's the random call
@@ -1997,18 +2005,22 @@ static void ChangeIndustryProduction(Industry *i, bool monthly)
const IndustrySpec *indspec = GetIndustrySpec(i->type);
bool standard = true;
bool suppress_message = false;
/* don't use smooth economy for industries using production callbacks */
bool smooth_economy = _patches.smooth_economy && !(HASBIT(indspec->callback_flags, CBM_IND_PRODUCTION_256_TICKS) || HASBIT(indspec->callback_flags, CBM_IND_PRODUCTION_CARGO_ARRIVAL));
/* don't use smooth economy for industries using production related callbacks */
bool smooth_economy = _patches.smooth_economy &&
!(HasBit(indspec->callback_flags, CBM_IND_PRODUCTION_256_TICKS) || HasBit(indspec->callback_flags, CBM_IND_PRODUCTION_CARGO_ARRIVAL)) && // production callbacks
!(HasBit(indspec->callback_flags, CBM_IND_MONTHLYPROD_CHANGE) || HasBit(indspec->callback_flags, CBM_IND_PRODUCTION_CHANGE)); // production change callbacks
byte div = 0;
byte mul = 0;
int8 increment = 0;
if (HASBIT(indspec->callback_flags, monthly ? CBM_IND_MONTHLYPROD_CHANGE : CBM_IND_PRODUCTION_CHANGE)) {
if (HasBit(indspec->callback_flags, monthly ? CBM_IND_MONTHLYPROD_CHANGE : CBM_IND_PRODUCTION_CHANGE)) {
uint16 res = GetIndustryCallback(monthly ? CBID_INDUSTRY_MONTHLYPROD_CHANGE : CBID_INDUSTRY_PRODUCTION_CHANGE, 0, Random(), i, i->type, i->xy);
standard = false;
monthly = false; // smooth economy is disabled so we need to fake random industry production change to allow 'use standard' result
if (res != CALLBACK_FAILED) {
standard = false;
suppress_message = HASBIT(res, 7);
suppress_message = HasBit(res, 7);
/* Get the custom message if any */
if (HASBIT(res, 8)) str = MapGRFStringID(indspec->grf_prop.grffile->grfid, GB(GetRegister(0x100), 0, 16));
if (HasBit(res, 8)) str = MapGRFStringID(indspec->grf_prop.grffile->grfid, GB(GetRegister(0x100), 0, 16));
res = GB(res, 0, 4);
switch(res) {
default: NOT_REACHED();
@@ -2018,9 +2030,13 @@ static void ChangeIndustryProduction(Industry *i, bool monthly)
case 0x3: closeit = true; break; // The industry announces imminent closure, and is physically removed from the map next month.
case 0x4: standard = true; break; // Do the standard random production change as if this industry was a primary one.
case 0x5: case 0x6: case 0x7: // Divide production by 4, 8, 16
case 0x8: div = res - 0x5; break; // Divide production by 32
case 0x8: div = res - 0x3; break; // Divide production by 32
case 0x9: case 0xA: case 0xB: // Multiply production by 4, 8, 16
case 0xC: mul = res - 0x9; break; // Multiply production by 32
case 0xC: mul = res - 0x7; break; // Multiply production by 32
case 0xD: // decrement production
case 0xE: // increment production
increment = res == 0x0D ? -1 : 1;
break;
}
}
}
@@ -2036,18 +2052,27 @@ static void ChangeIndustryProduction(Industry *i, bool monthly)
if (smooth_economy) {
closeit = true;
for (byte j = 0; j < 2 && i->produced_cargo[j] != CT_INVALID; j++){
uint32 r = Random();
int old_prod, new_prod, percent;
int mult = (i->last_month_pct_transported[j] > PERCENT_TRANSPORTED_60) ? 1 : -1;
new_prod = old_prod = i->production_rate[j];
if (CHANCE16I(20, 1024, r)) new_prod -= max(((RandomRange(50) + 10) * old_prod) >> 8, 1U);
/* Chance of increasing becomes better when more is transported */
if (CHANCE16I(20 + (i->last_month_pct_transported[j] * 20 >> 8), 1024, r >> 16) && !only_decrease) {
new_prod += max(((RandomRange(50) + 10) * old_prod) >> 8, 1U);
if (only_decrease) {
mult = -1;
} else if (Chance16(1, 3)) {
mult *= -1;
}
new_prod = clamp(new_prod, 1, 255);
if (Chance16(1, 22)) {
new_prod += mult * (max(((RandomRange(50) + 10) * old_prod) >> 8, 1U));
}
/* Prevent production to overflow or Oil Rig passengers to be over-"produced" */
new_prod = Clamp(new_prod, 1, 255);
if (((indspec->behaviour & INDUSTRYBEH_BUILT_ONWATER) != 0) && j == 1)
new_prod = Clamp(new_prod, 0, 16);
/* Do not stop closing the industry when it has the lowest possible production rate */
if (new_prod == old_prod && old_prod > 1) {
closeit = false;
@@ -2065,9 +2090,9 @@ static void ChangeIndustryProduction(Industry *i, bool monthly)
}
}
} else {
if (only_decrease || CHANCE16(1, 3)) {
if (only_decrease || Chance16(1, 3)) {
/* If you transport > 60%, 66% chance we increase, else 33% chance we increase */
if (!only_decrease && (i->last_month_pct_transported[0] > 153) != CHANCE16(1, 3)) {
if (!only_decrease && (i->last_month_pct_transported[0] > PERCENT_TRANSPORTED_60) != Chance16(1, 3)) {
mul = 1; // Increase production
} else {
div = 1; // Decrease production
@@ -2077,7 +2102,7 @@ static void ChangeIndustryProduction(Industry *i, bool monthly)
}
if (standard && indspec->life_type & INDUSTRYLIFE_PROCESSING) {
if ( (byte)(_cur_year - i->last_prod_year) >= 5 && CHANCE16(1, smooth_economy ? 180 : 2)) {
if ( (byte)(_cur_year - i->last_prod_year) >= 5 && Chance16(1, smooth_economy ? 180 : 2)) {
closeit = true;
}
}
@@ -2102,6 +2127,11 @@ static void ChangeIndustryProduction(Industry *i, bool monthly)
}
}
if (increment != 0) {
i->prod_level = ClampU(i->prod_level + increment, 4, 0x80);
if (i->prod_level == 4) closeit = true;
}
/* Close if needed and allowed */
if (closeit && !CheckIndustryCloseDownProtection(i->type)) {
i->prod_level = 0;
@@ -2156,7 +2186,7 @@ void IndustryMonthlyLoop()
}
/* 3% chance that we start a new industry */
if (CHANCE16(3, 100)) {
if (Chance16(3, 100)) {
MaybeNewIndustry();
} else {
i = GetRandomIndustry();
@@ -2197,6 +2227,11 @@ Money IndustrySpec::GetConstructionCost() const
)) >> 8;
}
Money IndustrySpec::GetRemovalCost() const
{
return (_price.remove_house * this->removal_cost_multiplier) >> 8;
}
static CommandCost TerraformTile_Industry(TileIndex tile, uint32 flags, uint z_new, Slope tileh_new)
{
if (AutoslopeEnabled()) {
@@ -2213,7 +2248,7 @@ static CommandCost TerraformTile_Industry(TileIndex tile, uint32 flags, uint z_n
const IndustryTileSpec *itspec = GetIndustryTileSpec(gfx);
/* Call callback 3C 'disable autosloping for industry tiles'. */
if (HASBIT(itspec->callback_flags, CBM_INDT_AUTOSLOPE)) {
if (HasBit(itspec->callback_flags, CBM_INDT_AUTOSLOPE)) {
/* If the callback fails, allow autoslope. */
uint16 res = GetIndustryTileCallback(CBID_INDUSTRY_AUTOSLOPE, 0, 0, gfx, GetIndustryByTile(tile), tile);
if ((res == 0) || (res == CALLBACK_FAILED)) return _price.terraform;

View File

@@ -26,37 +26,17 @@
#include "newgrf_text.h"
#include "date.h"
extern Industry *CreateNewIndustry(TileIndex tile, IndustryType type);
/**
* Search callback function for TryBuildIndustry
* @param tile to test
* @param data that is passed by the caller. In this case, the type of industry been tested
* @return the success (or not) of the operation
*/
static bool SearchTileForIndustry(TileIndex tile, uint32 data)
{
return CreateNewIndustry(tile, data) != NULL;
}
/**
* Perform a 9*9 tiles circular search around a tile
* in order to find a suitable zone to create the desired industry
* @param tile to start search for
* @param type of the desired industry
* @return the success (or not) of the operation
*/
static bool TryBuildIndustry(TileIndex tile, int type)
{
return CircularTileSearch(tile, 9, SearchTileForIndustry, type);
}
bool _ignore_restrictions;
enum {
DYNA_INDU_MATRIX_WIDGET = 2,
DYNA_INDU_INFOPANEL = 4,
DYNA_INDU_FUND_WIDGET,
DYNA_INDU_RESIZE_WIDGET,
/** Names of the widgets of the dynamic place industries gui */
enum DynamicPlaceIndustriesWidgets {
DPIW_CLOSEBOX = 0,
DPIW_CAPTION,
DPIW_MATRIX_WIDGET,
DPIW_SCROLLBAR,
DPIW_INFOPANEL,
DPIW_FUND_WIDGET,
DPIW_RESIZE_WIDGET,
};
/** Attached struct to the window extended data */
@@ -87,11 +67,11 @@ static void BuildDynamicIndustryWndProc(Window *w, WindowEvent *e)
* info coming from the callback. SO it will only be available to tis full
* height when newindistries are loaded */
if (!_loaded_newgrf_features.has_newindustries) {
w->widget[DYNA_INDU_INFOPANEL].bottom -= 44;
w->widget[DYNA_INDU_FUND_WIDGET].bottom -= 44;
w->widget[DYNA_INDU_FUND_WIDGET].top -= 44;
w->widget[DYNA_INDU_RESIZE_WIDGET].bottom -= 44;
w->widget[DYNA_INDU_RESIZE_WIDGET].top -= 44;
w->widget[DPIW_INFOPANEL].bottom -= 44;
w->widget[DPIW_FUND_WIDGET].bottom -= 44;
w->widget[DPIW_FUND_WIDGET].top -= 44;
w->widget[DPIW_RESIZE_WIDGET].bottom -= 44;
w->widget[DPIW_RESIZE_WIDGET].top -= 44;
w->resize.height = w->height -= 44;
}
@@ -138,9 +118,9 @@ static void BuildDynamicIndustryWndProc(Window *w, WindowEvent *e)
case WE_PAINT: {
const IndustrySpec *indsp = (WP(w, fnd_d).select == INVALID_INDUSTRYTYPE) ? NULL : GetIndustrySpec(WP(w, fnd_d).select);
int x_str = w->widget[DYNA_INDU_INFOPANEL].left + 3;
int y_str = w->widget[DYNA_INDU_INFOPANEL].top + 3;
const Widget *wi = &w->widget[DYNA_INDU_INFOPANEL];
int x_str = w->widget[DPIW_INFOPANEL].left + 3;
int y_str = w->widget[DPIW_INFOPANEL].top + 3;
const Widget *wi = &w->widget[DPIW_INFOPANEL];
int max_width = wi->right - wi->left - 4;
/* Raw industries might be prospected. Show this fact by changing the string
@@ -148,11 +128,11 @@ static void BuildDynamicIndustryWndProc(Window *w, WindowEvent *e)
if (_game_mode == GM_EDITOR) {
/* We've chosen many random industries but no industries have been specified */
if (indsp == NULL) _fund_gui.enabled[WP(w, fnd_d).index] = _opt.diff.number_industries != 0;
w->widget[DYNA_INDU_FUND_WIDGET].data = STR_BUILD_NEW_INDUSTRY;
w->widget[DPIW_FUND_WIDGET].data = STR_BUILD_NEW_INDUSTRY;
} else {
w->widget[DYNA_INDU_FUND_WIDGET].data = (_patches.raw_industry_construction == 2 && indsp->IsRawIndustry()) ? STR_PROSPECT_NEW_INDUSTRY : STR_FUND_NEW_INDUSTRY;
w->widget[DPIW_FUND_WIDGET].data = (_patches.raw_industry_construction == 2 && indsp->IsRawIndustry()) ? STR_PROSPECT_NEW_INDUSTRY : STR_FUND_NEW_INDUSTRY;
}
SetWindowWidgetDisabledState(w, DYNA_INDU_FUND_WIDGET, !_fund_gui.enabled[WP(w, fnd_d).index]);
w->SetWidgetDisabledState(DPIW_FUND_WIDGET, !_fund_gui.enabled[WP(w, fnd_d).index]);
SetVScrollCount(w, _fund_gui.count);
@@ -214,7 +194,7 @@ static void BuildDynamicIndustryWndProc(Window *w, WindowEvent *e)
/* Get the additional purchase info text, if it has not already been */
if (_fund_gui.text[WP(w, fnd_d).index] == STR_NULL) { // Have i been called already?
if (HASBIT(indsp->callback_flags, CBM_IND_FUND_MORE_TEXT)) { // No. Can it be called?
if (HasBit(indsp->callback_flags, CBM_IND_FUND_MORE_TEXT)) { // No. Can it be called?
uint16 callback_res = GetIndustryCallback(CBID_INDUSTRY_FUND_MORE_TEXT, 0, 0, NULL, WP(w, fnd_d).select, INVALID_TILE);
if (callback_res != CALLBACK_FAILED) { // Did it failed?
StringID newtxt = GetGRFStringID(indsp->grf_prop.grffile->grfid, 0xD000 + callback_res); // No. here's the new string
@@ -232,11 +212,16 @@ static void BuildDynamicIndustryWndProc(Window *w, WindowEvent *e)
}
} break;
case WE_DOUBLE_CLICK:
if (e->we.click.widget != DPIW_MATRIX_WIDGET) break;
e->we.click.widget = DPIW_FUND_WIDGET;
/* Fall through */
case WE_CLICK:
switch (e->we.click.widget) {
case DYNA_INDU_MATRIX_WIDGET: {
case DPIW_MATRIX_WIDGET: {
const IndustrySpec *indsp;
int y = (e->we.click.pt.y - w->widget[DYNA_INDU_MATRIX_WIDGET].top) / 13 + w->vscroll.pos ;
int y = (e->we.click.pt.y - w->widget[DPIW_MATRIX_WIDGET].top) / 13 + w->vscroll.pos ;
if (y >= 0 && y < _fund_gui.count) { // Is it within the boundaries of available data?
WP(w, fnd_d).index = y;
@@ -248,15 +233,15 @@ static void BuildDynamicIndustryWndProc(Window *w, WindowEvent *e)
if ((_game_mode != GM_EDITOR && _patches.raw_industry_construction == 2 && indsp != NULL && indsp->IsRawIndustry()) ||
WP(w, fnd_d).select == INVALID_INDUSTRYTYPE) {
/* Reset the button state if going to prospecting or "build many industries" */
RaiseWindowButtons(w);
w->RaiseButtons();
ResetObjectToPlace();
}
}
} break;
case DYNA_INDU_FUND_WIDGET: {
case DPIW_FUND_WIDGET: {
if (WP(w, fnd_d).select == INVALID_INDUSTRYTYPE) {
HandleButtonClick(w, DYNA_INDU_FUND_WIDGET);
w->HandleButtonClick(DPIW_FUND_WIDGET);
if (GetNumTowns() == 0) {
ShowErrorMessage(STR_0286_MUST_BUILD_TOWN_FIRST, STR_CAN_T_GENERATE_INDUSTRIES, 0, 0);
@@ -268,9 +253,9 @@ static void BuildDynamicIndustryWndProc(Window *w, WindowEvent *e)
}
} else if (_game_mode != GM_EDITOR && _patches.raw_industry_construction == 2 && GetIndustrySpec(WP(w, fnd_d).select)->IsRawIndustry()) {
DoCommandP(0, WP(w, fnd_d).select, 0, NULL, CMD_BUILD_INDUSTRY | CMD_MSG(STR_4830_CAN_T_CONSTRUCT_THIS_INDUSTRY));
HandleButtonClick(w, DYNA_INDU_FUND_WIDGET);
w->HandleButtonClick(DPIW_FUND_WIDGET);
} else {
HandlePlacePushButton(w, DYNA_INDU_FUND_WIDGET, SPR_CURSOR_INDUSTRY, VHM_RECT, NULL);
HandlePlacePushButton(w, DPIW_FUND_WIDGET, SPR_CURSOR_INDUSTRY, VHM_RECT, NULL);
}
} break;
}
@@ -279,7 +264,7 @@ static void BuildDynamicIndustryWndProc(Window *w, WindowEvent *e)
case WE_RESIZE: {
/* Adjust the number of items in the matrix depending of the rezise */
w->vscroll.cap += e->we.sizing.diff.y / (int)w->resize.step_height;
w->widget[DYNA_INDU_MATRIX_WIDGET].data = (w->vscroll.cap << 8) + 1;
w->widget[DPIW_MATRIX_WIDGET].data = (w->vscroll.cap << 8) + 1;
} break;
case WE_PLACE_OBJ: {
@@ -298,7 +283,7 @@ static void BuildDynamicIndustryWndProc(Window *w, WindowEvent *e)
_current_player = OWNER_NONE;
_generating_world = true;
_ignore_restrictions = true;
success = TryBuildIndustry(e->we.place.tile, WP(w, fnd_d).select);
success = DoCommandP(e->we.place.tile, WP(w, fnd_d).select, InteractiveRandomRange(indsp->num_table), NULL, CMD_BUILD_INDUSTRY | CMD_MSG(STR_4830_CAN_T_CONSTRUCT_THIS_INDUSTRY));
if (!success) {
SetDParam(0, indsp->name);
ShowErrorMessage(_error_message, STR_0285_CAN_T_BUILD_HERE, e->we.place.pt.x, e->we.place.pt.y);
@@ -337,22 +322,24 @@ static void BuildDynamicIndustryWndProc(Window *w, WindowEvent *e)
case WE_TIMEOUT:
case WE_ABORT_PLACE_OBJ:
RaiseWindowButtons(w);
w->RaiseButtons();
break;
}
}
/** Widget definition of the dynamic place industries gui */
static const Widget _build_dynamic_industry_widgets[] = {
{ WWT_CLOSEBOX, RESIZE_NONE, 7, 0, 10, 0, 13, STR_00C5, STR_018B_CLOSE_WINDOW},
{ WWT_CAPTION, RESIZE_RIGHT, 7, 11, 169, 0, 13, STR_0314_FUND_NEW_INDUSTRY, STR_018C_WINDOW_TITLE_DRAG_THIS},
{ WWT_MATRIX, RESIZE_RB, 7, 0, 157, 14, 118, 0x801, STR_INDUSTRY_SELECTION_HINT},
{ WWT_SCROLLBAR, RESIZE_LRB, 7, 158, 169, 14, 118, 0x0, STR_0190_SCROLL_BAR_SCROLLS_LIST},
{ WWT_PANEL, RESIZE_RTB, 7, 0, 169, 119, 199, 0x0, STR_NULL},
{ WWT_TEXTBTN, RESIZE_RTB, 7, 0, 157, 200, 211, STR_FUND_NEW_INDUSTRY, STR_NULL},
{ WWT_RESIZEBOX, RESIZE_LRTB, 7, 158, 169, 200, 211, 0x0, STR_RESIZE_BUTTON},
{ WWT_CLOSEBOX, RESIZE_NONE, 7, 0, 10, 0, 13, STR_00C5, STR_018B_CLOSE_WINDOW}, // DPIW_CLOSEBOX
{ WWT_CAPTION, RESIZE_RIGHT, 7, 11, 169, 0, 13, STR_0314_FUND_NEW_INDUSTRY, STR_018C_WINDOW_TITLE_DRAG_THIS}, // DPIW_CAPTION
{ WWT_MATRIX, RESIZE_RB, 7, 0, 157, 14, 118, 0x801, STR_INDUSTRY_SELECTION_HINT}, // DPIW_MATRIX_WIDGET
{ WWT_SCROLLBAR, RESIZE_LRB, 7, 158, 169, 14, 118, 0x0, STR_0190_SCROLL_BAR_SCROLLS_LIST}, // DPIW_SCROLLBAR
{ WWT_PANEL, RESIZE_RTB, 7, 0, 169, 119, 199, 0x0, STR_NULL}, // DPIW_INFOPANEL
{ WWT_TEXTBTN, RESIZE_RTB, 7, 0, 157, 200, 211, STR_FUND_NEW_INDUSTRY, STR_NULL}, // DPIW_FUND_WIDGET
{ WWT_RESIZEBOX, RESIZE_LRTB, 7, 158, 169, 200, 211, 0x0, STR_RESIZE_BUTTON}, // DPIW_RESIZE_WIDGET
{ WIDGETS_END},
};
/** Window definition of the dynamic place industries gui */
static const WindowDesc _build_industry_dynamic_desc = {
WDP_AUTO, WDP_AUTO, 170, 212, 170, 212,
WC_BUILD_INDUSTRY, WC_NONE,
@@ -385,6 +372,18 @@ static inline bool IsProductionAlterable(const Industry *i)
(i->accepts_cargo[0] == CT_INVALID || i->accepts_cargo[0] == CT_VALUABLES));
}
/** Names of the widgets of the view industry gui */
enum IndustryViewWidgets {
IVW_CLOSEBOX = 0,
IVW_CAPTION,
IVW_STICKY,
IVW_BACKGROUND,
IVW_VIEWPORT,
IVW_INFO,
IVW_GOTO,
IVW_SPACER,
};
/** Information to store about the industry window */
struct indview_d : public vp_d {
byte editbox_line; ///< The line clicked to open the edit box
@@ -406,7 +405,7 @@ static void IndustryViewWndProc(Window *w, WindowEvent *e)
bool first = true;
bool has_accept = false;
if (HASBIT(ind->callback_flags, CBM_IND_PRODUCTION_CARGO_ARRIVAL) || HASBIT(ind->callback_flags, CBM_IND_PRODUCTION_256_TICKS)) {
if (HasBit(ind->callback_flags, CBM_IND_PRODUCTION_CARGO_ARRIVAL) || HasBit(ind->callback_flags, CBM_IND_PRODUCTION_256_TICKS)) {
for (byte j = 0; j < lengthof(i->accepts_cargo); j++) {
if (i->accepts_cargo[j] == CT_INVALID) continue;
has_accept = true;
@@ -436,7 +435,7 @@ static void IndustryViewWndProc(Window *w, WindowEvent *e)
lines++;
}
if (HASBIT(ind->callback_flags, CBM_IND_WINDOW_MORE_TEXT)) lines += 2;
if (HasBit(ind->callback_flags, CBM_IND_WINDOW_MORE_TEXT)) lines += 2;
for (byte j = 5; j <= 7; j++) {
if (j != 5) w->widget[j].top += lines * 10;
@@ -455,7 +454,7 @@ static void IndustryViewWndProc(Window *w, WindowEvent *e)
SetDParam(0, w->window_number);
DrawWindowWidgets(w);
if (HASBIT(ind->callback_flags, CBM_IND_PRODUCTION_CARGO_ARRIVAL) || HASBIT(ind->callback_flags, CBM_IND_PRODUCTION_256_TICKS)) {
if (HasBit(ind->callback_flags, CBM_IND_PRODUCTION_CARGO_ARRIVAL) || HasBit(ind->callback_flags, CBM_IND_PRODUCTION_256_TICKS)) {
for (byte j = 0; j < lengthof(i->accepts_cargo); j++) {
if (i->accepts_cargo[j] == CT_INVALID) continue;
has_accept = true;
@@ -509,7 +508,7 @@ static void IndustryViewWndProc(Window *w, WindowEvent *e)
}
/* Get the extra message for the GUI */
if (HASBIT(ind->callback_flags, CBM_IND_WINDOW_MORE_TEXT)) {
if (HasBit(ind->callback_flags, CBM_IND_WINDOW_MORE_TEXT)) {
uint16 callback_res = GetIndustryCallback(CBID_INDUSTRY_WINDOW_MORE_TEXT, 0, 0, i, i->type, i->xy);
if (callback_res != CALLBACK_FAILED) {
StringID message = GetGRFStringID(ind->grf_prop.grffile->grfid, 0xD000 + callback_res);
@@ -530,7 +529,7 @@ static void IndustryViewWndProc(Window *w, WindowEvent *e)
Industry *i;
switch (e->we.click.widget) {
case 5: {
case IVW_INFO: {
int line, x;
i = GetIndustry(w->window_number);
@@ -539,8 +538,8 @@ static void IndustryViewWndProc(Window *w, WindowEvent *e)
if (!IsProductionAlterable(i)) return;
x = e->we.click.pt.x;
line = (e->we.click.pt.y - WP(w, indview_d).production_offset_y) / 10;
if (e->we.click.pt.y >= WP(w, indview_d).production_offset_y && IS_INT_INSIDE(line, 0, 2) && i->produced_cargo[line] != CT_INVALID) {
if (IS_INT_INSIDE(x, 5, 25) ) {
if (e->we.click.pt.y >= WP(w, indview_d).production_offset_y && IsInsideMM(line, 0, 2) && i->produced_cargo[line] != CT_INVALID) {
if (IsInsideMM(x, 5, 25) ) {
/* Clicked buttons, decrease or increase production */
if (x < 15) {
if (isProductionMinimum(i, line)) return;
@@ -557,7 +556,7 @@ static void IndustryViewWndProc(Window *w, WindowEvent *e)
w->flags4 |= 5 << WF_TIMEOUT_SHL;
WP(w, indview_d).clicked_line = line + 1;
WP(w, indview_d).clicked_button = (x < 15 ? 1 : 2);
} else if (IS_INT_INSIDE(x, 34, 160)) {
} else if (IsInsideMM(x, 34, 160)) {
/* clicked the text */
WP(w, indview_d).editbox_line = line;
SetDParam(0, i->production_rate[line] * 8);
@@ -565,7 +564,7 @@ static void IndustryViewWndProc(Window *w, WindowEvent *e)
}
}
} break;
case 6:
case IVW_GOTO:
i = GetIndustry(w->window_number);
ScrollMainWindowToTile(i->xy + TileDiffXY(1, 1));
} break;
@@ -583,7 +582,7 @@ static void IndustryViewWndProc(Window *w, WindowEvent *e)
Industry* i = GetIndustry(w->window_number);
int line = WP(w, indview_d).editbox_line;
i->production_rate[line] = clampu(atoi(e->we.edittext.str), 0, 255);
i->production_rate[line] = ClampU(atoi(e->we.edittext.str), 0, 255);
UpdateIndustryProduction(i);
SetWindowDirty(w);
}
@@ -599,18 +598,20 @@ static void UpdateIndustryProduction(Industry *i)
}
}
/** Widget definition of the view industy gui */
static const Widget _industry_view_widgets[] = {
{ WWT_CLOSEBOX, RESIZE_NONE, 9, 0, 10, 0, 13, STR_00C5, STR_018B_CLOSE_WINDOW},
{ WWT_CAPTION, RESIZE_NONE, 9, 11, 247, 0, 13, STR_4801, STR_018C_WINDOW_TITLE_DRAG_THIS},
{ WWT_STICKYBOX, RESIZE_NONE, 9, 248, 259, 0, 13, 0x0, STR_STICKY_BUTTON},
{ WWT_PANEL, RESIZE_NONE, 9, 0, 259, 14, 105, 0x0, STR_NULL},
{ WWT_INSET, RESIZE_NONE, 9, 2, 257, 16, 103, 0x0, STR_NULL},
{ WWT_PANEL, RESIZE_NONE, 9, 0, 259, 106, 147, 0x0, STR_NULL},
{ WWT_PUSHTXTBTN, RESIZE_NONE, 9, 0, 129, 148, 159, STR_00E4_LOCATION, STR_482C_CENTER_THE_MAIN_VIEW_ON},
{ WWT_PANEL, RESIZE_NONE, 9, 130, 259, 148, 159, 0x0, STR_NULL},
{ WWT_CLOSEBOX, RESIZE_NONE, 9, 0, 10, 0, 13, STR_00C5, STR_018B_CLOSE_WINDOW}, // IVW_CLOSEBOX
{ WWT_CAPTION, RESIZE_NONE, 9, 11, 247, 0, 13, STR_4801, STR_018C_WINDOW_TITLE_DRAG_THIS}, // IVW_CAPTION
{ WWT_STICKYBOX, RESIZE_NONE, 9, 248, 259, 0, 13, 0x0, STR_STICKY_BUTTON}, // IVW_STICKY
{ WWT_PANEL, RESIZE_NONE, 9, 0, 259, 14, 105, 0x0, STR_NULL}, // IVW_BACKGROUND
{ WWT_INSET, RESIZE_NONE, 9, 2, 257, 16, 103, 0x0, STR_NULL}, // IVW_VIEWPORT
{ WWT_PANEL, RESIZE_NONE, 9, 0, 259, 106, 147, 0x0, STR_NULL}, // IVW_INFO
{ WWT_PUSHTXTBTN, RESIZE_NONE, 9, 0, 129, 148, 159, STR_00E4_LOCATION, STR_482C_CENTER_THE_MAIN_VIEW_ON}, // IVW_GOTO
{ WWT_PANEL, RESIZE_NONE, 9, 130, 259, 148, 159, 0x0, STR_NULL}, // IVW_SPACER
{ WIDGETS_END},
};
/** Window definition of the view industy gui */
static const WindowDesc _industry_view_desc = {
WDP_AUTO, WDP_AUTO, 260, 160, 260, 160,
WC_INDUSTRY_VIEW, WC_NONE,
@@ -632,26 +633,34 @@ void ShowIndustryViewWindow(int industry)
}
}
enum {
DIRECTORY_INDU_SORTBYNAME = 3,
DIRECTORY_INDU_SORTBYTYPE,
DIRECTORY_INDU_SORTBYPROD,
DIRECTORY_INDU_SORTBYTRANSPORT,
DIRECTORY_INDU_SHOWINDU = 8,
/** Names of the widgets of the industry directory gui */
enum IndustryDirectoryWidgets {
IDW_CLOSEBOX = 0,
IDW_CAPTION,
IDW_STICKY,
IDW_SORTBYNAME,
IDW_SORTBYTYPE,
IDW_SORTBYPROD,
IDW_SORTBYTRANSPORT,
IDW_SPACER,
IDW_INDUSRTY_LIST,
IDW_SCROLLBAR,
IDW_RESIZE,
};
/** Widget definition of the industy directory gui */
static const Widget _industry_directory_widgets[] = {
{ WWT_CLOSEBOX, RESIZE_NONE, 13, 0, 10, 0, 13, STR_00C5, STR_018B_CLOSE_WINDOW},
{ WWT_CAPTION, RESIZE_NONE, 13, 11, 495, 0, 13, STR_INDUSTRYDIR_CAPTION, STR_018C_WINDOW_TITLE_DRAG_THIS},
{ WWT_STICKYBOX, RESIZE_NONE, 13, 496, 507, 0, 13, 0x0, STR_STICKY_BUTTON},
{ WWT_PUSHTXTBTN, RESIZE_NONE, 13, 0, 100, 14, 25, STR_SORT_BY_NAME, STR_SORT_ORDER_TIP},
{ WWT_PUSHTXTBTN, RESIZE_NONE, 13, 101, 200, 14, 25, STR_SORT_BY_TYPE, STR_SORT_ORDER_TIP},
{ WWT_PUSHTXTBTN, RESIZE_NONE, 13, 201, 300, 14, 25, STR_SORT_BY_PRODUCTION, STR_SORT_ORDER_TIP},
{ WWT_PUSHTXTBTN, RESIZE_NONE, 13, 301, 400, 14, 25, STR_SORT_BY_TRANSPORTED, STR_SORT_ORDER_TIP},
{ WWT_PANEL, RESIZE_NONE, 13, 401, 495, 14, 25, 0x0, STR_NULL},
{ WWT_PANEL, RESIZE_BOTTOM, 13, 0, 495, 26, 189, 0x0, STR_200A_TOWN_NAMES_CLICK_ON_NAME},
{ WWT_SCROLLBAR, RESIZE_BOTTOM, 13, 496, 507, 14, 177, 0x0, STR_0190_SCROLL_BAR_SCROLLS_LIST},
{ WWT_RESIZEBOX, RESIZE_TB, 13, 496, 507, 178, 189, 0x0, STR_RESIZE_BUTTON},
{ WWT_CLOSEBOX, RESIZE_NONE, 13, 0, 10, 0, 13, STR_00C5, STR_018B_CLOSE_WINDOW}, // IDW_CLOSEBOX
{ WWT_CAPTION, RESIZE_NONE, 13, 11, 495, 0, 13, STR_INDUSTRYDIR_CAPTION, STR_018C_WINDOW_TITLE_DRAG_THIS}, // IDW_CAPTION
{ WWT_STICKYBOX, RESIZE_NONE, 13, 496, 507, 0, 13, 0x0, STR_STICKY_BUTTON}, // IDW_STICKY
{ WWT_PUSHTXTBTN, RESIZE_NONE, 13, 0, 100, 14, 25, STR_SORT_BY_NAME, STR_SORT_ORDER_TIP}, // IDW_SORTBYNAME
{ WWT_PUSHTXTBTN, RESIZE_NONE, 13, 101, 200, 14, 25, STR_SORT_BY_TYPE, STR_SORT_ORDER_TIP}, // IDW_SORTBYTYPE
{ WWT_PUSHTXTBTN, RESIZE_NONE, 13, 201, 300, 14, 25, STR_SORT_BY_PRODUCTION, STR_SORT_ORDER_TIP}, // IDW_SORTBYPROD
{ WWT_PUSHTXTBTN, RESIZE_NONE, 13, 301, 400, 14, 25, STR_SORT_BY_TRANSPORTED, STR_SORT_ORDER_TIP}, // IDW_SORTBYTRANSPORT
{ WWT_PANEL, RESIZE_NONE, 13, 401, 495, 14, 25, 0x0, STR_NULL}, // IDW_SPACER
{ WWT_PANEL, RESIZE_BOTTOM, 13, 0, 495, 26, 189, 0x0, STR_200A_TOWN_NAMES_CLICK_ON_NAME}, // IDW_INDUSRTY_LIST
{ WWT_SCROLLBAR, RESIZE_BOTTOM, 13, 496, 507, 14, 177, 0x0, STR_0190_SCROLL_BAR_SCROLLS_LIST}, // IDW_SCROLLBAR
{ WWT_RESIZEBOX, RESIZE_TB, 13, 496, 507, 178, 189, 0x0, STR_RESIZE_BUTTON}, // IDW_RESIZE
{ WIDGETS_END},
};
@@ -752,7 +761,6 @@ static void MakeSortedIndustryList()
/* Create array for sorting */
_industry_sort = ReallocT(_industry_sort, GetMaxIndustryIndex() + 1);
if (_industry_sort == NULL) error("Could not allocate memory for the industry-sorting-list");
/* Don't attempt a sort if there are no industries */
if (GetNumIndustries() != 0) {
@@ -816,35 +824,35 @@ static void IndustryDirectoryWndProc(Window *w, WindowEvent *e)
case WE_CLICK:
switch (e->we.click.widget) {
case DIRECTORY_INDU_SORTBYNAME: {
case IDW_SORTBYNAME: {
_industry_sort_order = _industry_sort_order == 0 ? 1 : 0;
_industry_sort_dirty = true;
SetWindowDirty(w);
} break;
case DIRECTORY_INDU_SORTBYTYPE: {
case IDW_SORTBYTYPE: {
_industry_sort_order = _industry_sort_order == 2 ? 3 : 2;
_industry_sort_dirty = true;
SetWindowDirty(w);
} break;
case DIRECTORY_INDU_SORTBYPROD: {
case IDW_SORTBYPROD: {
_industry_sort_order = _industry_sort_order == 4 ? 5 : 4;
_industry_sort_dirty = true;
SetWindowDirty(w);
} break;
case DIRECTORY_INDU_SORTBYTRANSPORT: {
case IDW_SORTBYTRANSPORT: {
_industry_sort_order = _industry_sort_order == 6 ? 7 : 6;
_industry_sort_dirty = true;
SetWindowDirty(w);
} break;
case DIRECTORY_INDU_SHOWINDU: {
case IDW_INDUSRTY_LIST: {
int y = (e->we.click.pt.y - 28) / 10;
uint16 p;
if (!IS_INT_INSIDE(y, 0, w->vscroll.cap)) return;
if (!IsInsideMM(y, 0, w->vscroll.cap)) return;
p = y + w->vscroll.pos;
if (p < _num_industry_sort) {
ScrollMainWindowToTile(_industry_sort[p]->xy);
@@ -863,8 +871,7 @@ static void IndustryDirectoryWndProc(Window *w, WindowEvent *e)
}
}
/* Industry List */
/** Window definition of the industy directory gui */
static const WindowDesc _industry_directory_desc = {
WDP_AUTO, WDP_AUTO, 508, 190, 508, 190,
WC_INDUSTRY_DIRECTORY, WC_NONE,
@@ -873,7 +880,6 @@ static const WindowDesc _industry_directory_desc = {
IndustryDirectoryWndProc
};
void ShowIndustryDirectory()
{
Window *w = AllocateWindowDescFront(&_industry_directory_desc, 0);

View File

@@ -83,7 +83,7 @@ static inline Industry *GetIndustryByTile(TileIndex t)
static inline bool IsIndustryCompleted(TileIndex t)
{
assert(IsTileType(t, MP_INDUSTRY));
return HASBIT(_m[t].m1, 7);
return HasBit(_m[t].m1, 7);
}
IndustryType GetIndustryType(TileIndex tile);

View File

@@ -53,13 +53,13 @@ static inline void SetNewLandscapeType(byte landscape)
static void SelectGameWndProc(Window *w, WindowEvent *e)
{
switch (e->event) {
case WE_CREATE: LowerWindowWidget(w, _opt_newgame.landscape + 8); break;
case WE_CREATE: w->LowerWidget(_opt_newgame.landscape + 8); break;
case WE_PAINT:
SetWindowWidgetLoweredState(w, 8, _opt_newgame.landscape == LT_TEMPERATE);
SetWindowWidgetLoweredState(w, 9, _opt_newgame.landscape == LT_ARCTIC);
SetWindowWidgetLoweredState(w, 10, _opt_newgame.landscape == LT_TROPIC);
SetWindowWidgetLoweredState(w, 11, _opt_newgame.landscape == LT_TOYLAND);
w->SetWidgetLoweredState(8, _opt_newgame.landscape == LT_TEMPERATE);
w->SetWidgetLoweredState(9, _opt_newgame.landscape == LT_ARCTIC);
w->SetWidgetLoweredState(10, _opt_newgame.landscape == LT_TROPIC);
w->SetWidgetLoweredState(11, _opt_newgame.landscape == LT_TOYLAND);
SetDParam(0, STR_6801_EASY + _opt_newgame.diff_level);
DrawWindowWidgets(w);
break;
@@ -85,7 +85,7 @@ static void SelectGameWndProc(Window *w, WindowEvent *e)
}
break;
case 8: case 9: case 10: case 11:
RaiseWindowWidget(w, _opt_newgame.landscape + 8);
w->RaiseWidget(_opt_newgame.landscape + 8);
SetNewLandscapeType(e->we.click.widget - 8);
break;
case 12: ShowGameOptions(); break;

View File

@@ -2304,7 +2304,7 @@ STR_7072_VIEW_HQ :{BLACK}Wys HK
STR_RELOCATE_HQ :{BLACK}Beweeg HQ
STR_COMPANY_PASSWORD :{BLACK}Wagwoord
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Wagwoord-beskerm jou maatskappy om onmagtig gebruikers te belet van verbinding
STR_SET_COMPANY_PASSWORD :Stel maatskappy wagwoord
STR_SET_COMPANY_PASSWORD :{BLACK}Stel maatskappy wagwoord
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}W<>eld Insinking!{}{}Finansieel eksperte vrees ergste as ekonomie inmekaar sak!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Insinking Oor!{}{}Oplewing in sake gee vertroue na nywerhede as ekonomie versterk!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Tokkel groot/klein venster groote

View File

@@ -2302,7 +2302,7 @@ STR_7072_VIEW_HQ :{BLACK}View HQ
STR_RELOCATE_HQ :{BLACK}Relocate HQ
STR_COMPANY_PASSWORD :{BLACK}Password
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Password-protect your company to prevent unauthorized users from joining.
STR_SET_COMPANY_PASSWORD :Set company password
STR_SET_COMPANY_PASSWORD :{BLACK}Set company password
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}World Recession!{}{}Financial experts fear worst as economy slumps!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Recession Over!{}{}Upturn in trade gives confidence to industries as economy strengthens!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Toggle large/small window size

View File

@@ -596,6 +596,9 @@ STR_0208_ACCIDENTS_DISASTERS :{YELLOW}Acident
STR_0209_COMPANY_INFORMATION :{YELLOW}Informações da empresa
STR_NEWS_OPEN_CLOSE :{YELLOW}Abrir / fechar industrias
STR_020A_ECONOMY_CHANGES :{YELLOW}Alterações econômicas
STR_INDUSTRY_CHANGES_SERVED_BY_PLAYER :{YELLOW}Mudanças na produção de indústrias providas pelo jogador
STR_INDUSTRY_CHANGES_SERVED_BY_OTHER :{YELLOW}Mudanças na produção de indústrias providas pelo(s) competidor(es)
STR_OTHER_INDUSTRY_PRODUCTION_CHANGES :{YELLOW}Outras mudanças de produção das indústrias
STR_020B_ADVICE_INFORMATION_ON_PLAYER :{YELLOW}Avisos / informações dos veículos do jogador
STR_020C_NEW_VEHICLES :{YELLOW}Novos veículos
STR_020D_CHANGES_OF_CARGO_ACCEPTANCE :{YELLOW}Alterações de aceitação de carga
@@ -1682,6 +1685,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}Construi
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}Construir ponte de bonde
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}Construir túnel rodoviário
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}Construir túnel de bonde
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}Ativar/Desativar vias de mão única
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}Alternar construir/remover para contrução rodoviária
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}Alternar construir/remover linhas de bonde e sinais
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}Selecionar a orientação da garagem
@@ -1703,6 +1707,7 @@ STR_TOWN_LABEL :{WHITE}{TOWN}
STR_TOWN_LABEL_TINY_BLACK :{TINYFONT}{BLACK}{TOWN}
STR_TOWN_LABEL_TINY_WHITE :{TINYFONT}{WHITE}{TOWN}
STR_2002 :{TINYFONT}{BLACK}{SIGN}
STR_2002_WHITE :{TINYFONT}{WHITE}{SIGN}
STR_2004_BUILDING_MUST_BE_DEMOLISHED :{WHITE}O edifício necessita ser demolido primeiro
STR_2005 :{WHITE}{TOWN}
STR_2006_POPULATION :{BLACK}População: {ORANGE}{COMMA}{BLACK} Casas: {ORANGE}{COMMA}
@@ -2308,7 +2313,7 @@ STR_7072_VIEW_HQ :{BLACK}Ver sede
STR_RELOCATE_HQ :{BLACK}Mover sede
STR_COMPANY_PASSWORD :{BLACK}Senha
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Usar senha na empresa para prevenir utilizadores não autorizados.
STR_SET_COMPANY_PASSWORD :Definir senha para empresa
STR_SET_COMPANY_PASSWORD :{BLACK}Definir senha para empresa
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Recesso Mundial!{}{}Economistas temem crise!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Fim do recesso!{}{}Melhoras no comércio inspiram confiança nas indústrias à medida que a economia se fortalece!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Alternar entre janela grande/pequena
@@ -3289,6 +3294,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Altitude
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Centralizar o minimapa na posição atual
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Pequeno

View File

@@ -2302,7 +2302,7 @@ STR_7072_VIEW_HQ :{BLACK}Пока
STR_RELOCATE_HQ :{BLACK}Преместване ЦК
STR_COMPANY_PASSWORD :{BLACK}Парола
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Постави парола за да предпазиш компанията си от неоторизирани потребители.
STR_SET_COMPANY_PASSWORD :Поставяне парола на компанията
STR_SET_COMPANY_PASSWORD :{BLACK}Поставяне парола на компанията
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Световна икономическа криза!{}{}Финансовите експерти очакват най-лошото от сриващата се световна икономика!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Световната икономическа криза отмина!{}{}Възходът на търговията дава увереност на индустриите в новата засилваща се икономическа реалност!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Активирай голям/малък размер на прозореца

View File

@@ -594,6 +594,9 @@ STR_0208_ACCIDENTS_DISASTERS :{YELLOW}Acciden
STR_0209_COMPANY_INFORMATION :{YELLOW}Informació de l'Empresa
STR_NEWS_OPEN_CLOSE :{YELLOW}Obrir / tancar d'indústries
STR_020A_ECONOMY_CHANGES :{YELLOW}Canvis de l'Economia
STR_INDUSTRY_CHANGES_SERVED_BY_PLAYER :{YELLOW}Canvis de producció en indústries proveïdes pel jugador
STR_INDUSTRY_CHANGES_SERVED_BY_OTHER :{YELLOW}Canvis de producció en indústries proveïdes pel competidor(s)
STR_OTHER_INDUSTRY_PRODUCTION_CHANGES :{YELLOW}Altres canvis de producció de l'indústria
STR_020B_ADVICE_INFORMATION_ON_PLAYER :{YELLOW}Avisos / informació dels teus vehicles
STR_020C_NEW_VEHICLES :{YELLOW}Nous vehicles
STR_020D_CHANGES_OF_CARGO_ACCEPTANCE :{YELLOW}Canvis en admisió de càrrega
@@ -1680,6 +1683,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}Construe
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}Construeix pont per tramvies
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}Construeix un túnel per carretera
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}Construeix túnel per tramvies
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}Activa/Desactiva les carreteres d'un sentit
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}Intercanvia funció construeix/treu per la construcció de carreteres
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}Canvia construeix/treu de la construcció de vies de tramvia
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}Selecciona la orientació de les Cotxeres
@@ -1701,6 +1705,7 @@ STR_TOWN_LABEL :{WHITE}{TOWN}
STR_TOWN_LABEL_TINY_BLACK :{TINYFONT}{BLACK}{TOWN}
STR_TOWN_LABEL_TINY_WHITE :{TINYFONT}{WHITE}{TOWN}
STR_2002 :{TINYFONT}{BLACK}{SIGN}
STR_2002_WHITE :{TINYFONT}{WHITE}{SIGN}
STR_2004_BUILDING_MUST_BE_DEMOLISHED :{WHITE}L'edifici s'ha d'enderrocar primer
STR_2005 :{WHITE}{TOWN}
STR_2006_POPULATION :{BLACK}Població: {ORANGE}{COMMA}{BLACK} Cases: {ORANGE}{COMMA}
@@ -2304,7 +2309,7 @@ STR_7072_VIEW_HQ :{BLACK}Veure Se
STR_RELOCATE_HQ :{BLACK}Trasllada la Seu
STR_COMPANY_PASSWORD :{BLACK}Contrasenya
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Protegeix la teva Empresa amb contrasenya per tal d'evitar que la utilitzin usuaris no autoritzats.
STR_SET_COMPANY_PASSWORD :Estableix la contrasenya de l'Empresa
STR_SET_COMPANY_PASSWORD :{BLACK}Estableix la contrasenya de l'Empresa
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Recessió Mundial!{}{}Economistes experts temen que l'economia es desplomi!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Recessió Acabada!{}{}La millora als negocis dóna confiança a les indústries a la vegada que l'economia s'enforteix!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Intercanvia mida gran/petita de finestra
@@ -3285,6 +3290,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Alçada
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Centrar el mapa petit a la posició actual
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Petit

View File

@@ -2306,7 +2306,7 @@ STR_7072_VIEW_HQ :{BLACK}Pogledaj
STR_RELOCATE_HQ :{BLACK}Premjesti sjedište kompanije
STR_COMPANY_PASSWORD :{BLACK}Zaporka
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Zaštiti svoju tvrtku od neovlaštenog korištenja pomoću zaporke.
STR_SET_COMPANY_PASSWORD :Postavi zaporku tvrtke
STR_SET_COMPANY_PASSWORD :{BLACK}Postavi zaporku tvrtke
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Svjetska recesija!{}{}Financijski stručnjaci očekuju najgore zbog ekonomske krize!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Recesija završena!{}{}Obrat u trgovanu daje samopouzdanje gospodarstvu jer ekonomija jača!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Namjesti veliku/malu veličinu prozora

View File

@@ -652,6 +652,9 @@ STR_0208_ACCIDENTS_DISASTERS :{YELLOW}Nehody
STR_0209_COMPANY_INFORMATION :{YELLOW}Informace o společnosti
STR_NEWS_OPEN_CLOSE :{YELLOW}Otevření / zavření továren
STR_020A_ECONOMY_CHANGES :{YELLOW}Změny v ekonomice
STR_INDUSTRY_CHANGES_SERVED_BY_PLAYER :{YELLOW}Změny produkce průmyslu obsluhovaného hráčem
STR_INDUSTRY_CHANGES_SERVED_BY_OTHER :{YELLOW}Změny produkce průmyslu obsluhovaného konkurencí
STR_OTHER_INDUSTRY_PRODUCTION_CHANGES :{YELLOW}Jiné změny produkce průmyslu
STR_020B_ADVICE_INFORMATION_ON_PLAYER :{YELLOW}Rady / informace o hráčových vozidlech
STR_020C_NEW_VEHICLES :{YELLOW}Nový dopravní prostředek
STR_020D_CHANGES_OF_CARGO_ACCEPTANCE :{YELLOW}Změny příjmu zboží
@@ -1738,6 +1741,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}Postavit
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}Postavit tramvajový most
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}Postavit silniční tunel
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}Postavit tramvajový tunel
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}Povolit / zakázat jednosměrné silnice
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}Přepnout stavba / odstranění silnice
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}Přepínání mezi výstavbou a bouráním tramvajové tratě
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}Výběr orientace garáže
@@ -1759,6 +1763,7 @@ STR_TOWN_LABEL :{WHITE}{TOWN}
STR_TOWN_LABEL_TINY_BLACK :{TINYFONT}{BLACK}{TOWN}
STR_TOWN_LABEL_TINY_WHITE :{TINYFONT}{WHITE}{TOWN}
STR_2002 :{TINYFONT}{BLACK}{SIGN}
STR_2002_WHITE :{TINYFONT}{WHITE}{SIGN}
STR_2004_BUILDING_MUST_BE_DEMOLISHED :{WHITE}Budova musí být nejprve zničena
STR_2005 :{WHITE}{TOWN}
STR_2006_POPULATION :{BLACK}Populace: {ORANGE}{COMMA}{BLACK} Domů: {ORANGE}{COMMA}
@@ -2362,7 +2367,7 @@ STR_7072_VIEW_HQ :{BLACK}Ředitel
STR_RELOCATE_HQ :{BLACK}Přesídlit
STR_COMPANY_PASSWORD :{BLACK}Heslo
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Heslo - zabrání neautorizovaným uživatelům v připojení se k tvé společnosti.
STR_SET_COMPANY_PASSWORD :Nastav heslo společnosti.
STR_SET_COMPANY_PASSWORD :{BLACK}Nastav heslo společnosti.
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Celosvětový hospodářský úpadek!{}{}Finanční experti se kvůli prudkému poklesu ekonomiky obávají nejhoršího!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Konec hospodářského úpadku!{}{}Posílení trhu zvýšilo u průmyslu důvěru!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Přepnout velké/malé okno
@@ -3349,6 +3354,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Výška
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Vycentrovat malou mapu na tomto místě
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Malé
@@ -3503,3 +3509,6 @@ STR_FACE_TIE :Kravata:
STR_FACE_EARRING :Náušnice:
STR_FACE_TIE_EARRING_TIP :{BLACK}Změnit kravatu nebo náušnice
########
############ signal GUI
########

View File

@@ -594,6 +594,9 @@ STR_0208_ACCIDENTS_DISASTERS :{YELLOW}Uheld /
STR_0209_COMPANY_INFORMATION :{YELLOW}Selskabsinformation
STR_NEWS_OPEN_CLOSE :{YELLOW}Åbning / lukning af industrier
STR_020A_ECONOMY_CHANGES :{YELLOW}Økonomiændringer
STR_INDUSTRY_CHANGES_SERVED_BY_PLAYER :{YELLOW}Produktionsændringer for industrier forsynet af spilleren
STR_INDUSTRY_CHANGES_SERVED_BY_OTHER :{YELLOW}Produktionsændringer for industrier forsynet af deltager(e)
STR_OTHER_INDUSTRY_PRODUCTION_CHANGES :{YELLOW}Andre produktionsændringer for industri
STR_020B_ADVICE_INFORMATION_ON_PLAYER :{YELLOW}Rådgivning / information om spillerens køretøjer
STR_020C_NEW_VEHICLES :{YELLOW}Nye køretøjer
STR_020D_CHANGES_OF_CARGO_ACCEPTANCE :{YELLOW}Ændring i accepteret last
@@ -821,7 +824,7 @@ STR_02E4 :{BLACK}{SKIP}{S
STR_MEASURING_UNITS_SELECTION :{BLACK}Vælg måleenheder
STR_02E6_ROAD_VEHICLES :{BLACK}Vejkøretøjer
STR_02E7 :{BLACK}{SKIP}{SKIP}{SKIP}{STRING}
STR_02E8_SELECT_SIDE_OF_ROAD_FOR :{BLACK}Vælg den side af vejen, køretøjer skal køre i
STR_02E8_SELECT_SIDE_OF_ROAD_FOR :{BLACK}Vælg den side af vejen, køretøjer skal kører i
STR_02E9_DRIVE_ON_LEFT :Kør i venstre side
STR_02EA_DRIVE_ON_RIGHT :Kør i højre side
STR_02EB_TOWN_NAMES :{BLACK}Bynavne
@@ -1327,7 +1330,7 @@ STR_INDUSTRY_TOO_CLOSE :{WHITE}...for t
STR_RAIL_REFIT_VEHICLE_TO_CARRY :{BLACK}Ombyg toget til at køre med en anden lasttype
STR_RAIL_REFIT_VEHICLE :{BLACK}Ombyg toget
STR_RAIL_SELECT_TYPE_OF_CARGO_FOR :{BLACK}Vælg den lasttype toget skal køre med
STR_RAIL_SELECT_TYPE_OF_CARGO_FOR :{BLACK}Vælg den lasttype toget skal kører med
STR_RAIL_REFIT_TO_CARRY_HIGHLIGHTED :{BLACK}Ombyg toget til at køre med den markerede lasttype
STR_RAIL_CAN_T_REFIT_VEHICLE :{WHITE}Kan ikke ombygge toget...
STR_CONFIG_PATCHES_SERVINT_ISPERCENT :{LTBLUE}Service intervaller er i procent: {ORANGE}{STRING}
@@ -1680,6 +1683,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}Byg bro
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}Byg sporvejsbro
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}Byg tunnel
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}Byg sporvejstunnel
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}Aktiver/Deaktiver ensrettede veje
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}Skift mellem bygning/fjernelse af veje
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}Skift mellem bygning/fjernelse af sporveje
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}Vælg retning for værksted
@@ -2304,7 +2308,7 @@ STR_7072_VIEW_HQ :{BLACK}Vis HK
STR_RELOCATE_HQ :{BLACK}Flyt hovedkvarter
STR_COMPANY_PASSWORD :{BLACK}Kodeord
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Beskyt dit selskab med et kodeord for at undgå, at fremmede slutter sig til spillet.
STR_SET_COMPANY_PASSWORD :Sæt selskabets kodeord
STR_SET_COMPANY_PASSWORD :{BLACK}Sæt selskabets kodeord
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Lavkonjuktur over hele verden!{}{}Vismændende frygter det værste, økonomien skrumper!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Økonomisk krise overvundet!{}{}Stigning i forbrug giver industrien selvtilliden tilbage, produktionen øges!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Skift mellem stort/lille vindue
@@ -2778,7 +2782,7 @@ STR_TRAIN_STOPPING :{RED}Stopper
STR_TRAIN_STOPPING_VEL :{RED}Stopper, {VELOCITY}
STR_INCOMPATIBLE_RAIL_TYPES :Skinnetyperne passer ikke sammen
STR_TRAIN_NO_POWER :{RED}Ingen strøm
STR_TRAIN_START_NO_CATENARY :Toget kan ikke køre, fordi sporet ikke har køreledninger
STR_TRAIN_START_NO_CATENARY :Toget kan ikke kører, fordi sporet ikke har køreledninger
STR_NEW_VEHICLE_NOW_AVAILABLE :{BLACK}{BIGFONT}Ny {STRING} er nu tilgængelig!
STR_NEW_VEHICLE_TYPE :{BLACK}{BIGFONT}{ENGINE}
@@ -3076,6 +3080,7 @@ STR_NEWGRF_ERROR_LOAD_BEFORE :{STRING} skal i
STR_NEWGRF_ERROR_LOAD_AFTER :{STRING} skal indlæses efter {STRING}.
STR_NEWGRF_ERROR_OTTD_VERSION_NUMBER :{STRING} kræver OpenTTD version {STRING} eller højere.
STR_NEWGRF_ERROR_AFTER_TRANSLATED_FILE :GRF filen, som den er lavet til at oversætte,
STR_NEWGRF_ERROR_TOO_MANY_NEWGRFS_LOADED :For mange NewGRF sæt er indlæst.
STR_NEWGRF_ADD :{BLACK}Tilføj
STR_NEWGRF_ADD_TIP :{BLACK}Tilføj et NewGRF sæt til listen
@@ -3284,6 +3289,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Højde a
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Centrer det lille kort ved den nuværende position
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Lille

View File

@@ -594,6 +594,9 @@ STR_0208_ACCIDENTS_DISASTERS :{YELLOW}Ongeluk
STR_0209_COMPANY_INFORMATION :{YELLOW}Bedrijfsinformatie
STR_NEWS_OPEN_CLOSE :{YELLOW}Openen / sluiten van industrieën
STR_020A_ECONOMY_CHANGES :{YELLOW}Veranderingen in de economie
STR_INDUSTRY_CHANGES_SERVED_BY_PLAYER :{YELLOW}Productie veranderingen van industriën bezocht door speler
STR_INDUSTRY_CHANGES_SERVED_BY_OTHER :{YELLOW}Productie veranderingen van industriën bezocht door tegenstander(s)
STR_OTHER_INDUSTRY_PRODUCTION_CHANGES :{YELLOW}Andere productie aanpassingen van industriën
STR_020B_ADVICE_INFORMATION_ON_PLAYER :{YELLOW}Advies/informatie over voertuigen van de speler
STR_020C_NEW_VEHICLES :{YELLOW}Nieuwe voertuigen
STR_020D_CHANGES_OF_CARGO_ACCEPTANCE :{YELLOW}Verandering geaccepteerde goederen
@@ -1680,6 +1683,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}Bouw bru
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}Bouw tramrails brug
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}Bouw wegtunnel
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}Bouw tramrails tunnel
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}Activeer/Deactiveer eenrichtingsverkeer
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}Schakel tussen bouwen en verwijderen voor wegbouw
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}Schakelaar tussen bouwen/verwijderen van tramrails
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}Selecteer richting van wegvoertuigdepot
@@ -1701,6 +1705,7 @@ STR_TOWN_LABEL :{WHITE}{TOWN}
STR_TOWN_LABEL_TINY_BLACK :{TINYFONT}{BLACK}{TOWN}
STR_TOWN_LABEL_TINY_WHITE :{TINYFONT}{WHITE}{TOWN}
STR_2002 :{TINYFONT}{BLACK}{SIGN}
STR_2002_WHITE :{TINYFONT}{WHITE}{SIGN}
STR_2004_BUILDING_MUST_BE_DEMOLISHED :{WHITE}Gebouw moet eerst gesloopt worden
STR_2005 :{WHITE}{TOWN}
STR_2006_POPULATION :{BLACK}Bevolking: {ORANGE}{COMMA}{BLACK} Huizen: {ORANGE}{COMMA}
@@ -2304,7 +2309,7 @@ STR_7072_VIEW_HQ :{BLACK}Bekijk H
STR_RELOCATE_HQ :{BLACK}Verplaats HQ
STR_COMPANY_PASSWORD :{BLACK}Wachtwoord
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Bescherm het bedrijf met een wachtwoord zodat niet geautoriseerde personen niet mee kunnen doen.
STR_SET_COMPANY_PASSWORD :Geef bedrijfswachtwoord op
STR_SET_COMPANY_PASSWORD :{BLACK}Geef bedrijfswachtwoord op
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Wereld Recessie!{}{}Financiële experts vrezen het ergste terwijl economie ineen stort!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Recessie Voorbij!{}{}Stijgende handel geeft industrie vertrouwen terwijl economie verstevigt!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Schakel tussen groot/klein venster
@@ -3285,6 +3290,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Hoogte v
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Centreer de kleine kaart op huidige positie
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Klein

View File

@@ -432,7 +432,7 @@ STR_0170 :{TINYFONT}{STRI
STR_0171_PAUSE_GAME :{BLACK}Pause game
STR_0172_SAVE_GAME_ABANDON_GAME :{BLACK}Save game, abandon game, quit
STR_0173_DISPLAY_LIST_OF_COMPANY :{BLACK}Display list of company's stations
STR_0174_DISPLAY_MAP :{BLACK}Display map
STR_0174_DISPLAY_MAP :{BLACK}Display map, extra viewport or list of signs
STR_0175_DISPLAY_MAP_TOWN_DIRECTORY :{BLACK}Display map, town directory
STR_0176_DISPLAY_TOWN_DIRECTORY :{BLACK}Display town directory
STR_0177_DISPLAY_COMPANY_FINANCES :{BLACK}Display company finances information
@@ -854,7 +854,7 @@ STR_030E_SELECT_TEMPERATE_LANDSCAPE :{BLACK}Select '
STR_030F_SELECT_SUB_ARCTIC_LANDSCAPE :{BLACK}Select 'sub-arctic' landscape style
STR_0310_SELECT_SUB_TROPICAL_LANDSCAPE :{BLACK}Select 'sub-tropical' landscape style
STR_0311_SELECT_TOYLAND_LANDSCAPE :{BLACK}Select 'toyland' landscape style
STR_0312_FUND_CONSTRUCTION_OF_NEW :{BLACK}Fund construction of new industry
STR_0312_FUND_CONSTRUCTION_OF_NEW :{BLACK}Fund construction of new industry or list all industries
############ range for menu starts
STR_INDUSTRY_DIR :Industry Directory
@@ -1169,6 +1169,7 @@ STR_CONFIG_PATCHES_SMOOTH_ECONOMY :{LTBLUE}Enable
STR_CONFIG_PATCHES_ALLOW_SHARES :{LTBLUE}Allow buying shares from other companies
STR_CONFIG_PATCHES_DRAG_SIGNALS_DENSITY :{LTBLUE}When dragging, place signals every: {ORANGE}{STRING1} tile(s)
STR_CONFIG_PATCHES_SEMAPHORE_BUILD_BEFORE_DATE :{LTBLUE}Automatically build semaphores before: {ORANGE}{STRING1}
STR_CONFIG_PATCHES_ENABLE_SIGNAL_GUI :{LTBLUE}Enable the signal GUI: {ORANGE}{STRING1}
STR_CONFIG_PATCHES_TOWN_LAYOUT_INVALID :{WHITE}The town layout "no more roads" isn't valid in the scenario editor
STR_CONFIG_PATCHES_TOWN_LAYOUT :{LTBLUE}Select town-road layout: {ORANGE}{STRING1}
@@ -1705,6 +1706,7 @@ STR_TOWN_LABEL :{WHITE}{TOWN}
STR_TOWN_LABEL_TINY_BLACK :{TINYFONT}{BLACK}{TOWN}
STR_TOWN_LABEL_TINY_WHITE :{TINYFONT}{WHITE}{TOWN}
STR_2002 :{TINYFONT}{BLACK}{SIGN}
STR_2002_WHITE :{TINYFONT}{WHITE}{SIGN}
STR_2004_BUILDING_MUST_BE_DEMOLISHED :{WHITE}Building must be demolished first
STR_2005 :{WHITE}{TOWN}
STR_2006_POPULATION :{BLACK}Population: {ORANGE}{COMMA}{BLACK} Houses: {ORANGE}{COMMA}
@@ -2308,7 +2310,12 @@ STR_7072_VIEW_HQ :{BLACK}View HQ
STR_RELOCATE_HQ :{BLACK}Relocate HQ
STR_COMPANY_PASSWORD :{BLACK}Password
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Password-protect your company to prevent unauthorised users from joining.
STR_SET_COMPANY_PASSWORD :Set company password
STR_SET_COMPANY_PASSWORD :{BLACK}Set company password
STR_COMPANY_PASSWORD_CANCEL :{BLACK}Do not save the entered password
STR_COMPANY_PASSWORD_OK :{BLACK}Give the company the new password
STR_COMPANY_PASSWORD_CAPTION :{WHITE}Company password
STR_MAKE_DEFAULT_COMPANY_PASSWORD :{BLACK}Default company password
STR_MAKE_DEFAULT_COMPANY_PASSWORD_TIP :{BLACK}Use this company password as default for new companies
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}World Recession!{}{}Financial experts fear worst as economy slumps!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Recession Over!{}{}Upturn in trade gives confidence to industries as economy strengthens!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Toggle large/small window size
@@ -3109,6 +3116,8 @@ STR_NEWGRF_COMPATIBLE_LOADED :{ORANGE}Matchin
STR_NEWGRF_COMPATIBLE_LOAD_WARNING :{WHITE}Compatible GRF(s) loaded for missing files
STR_NEWGRF_DISABLED_WARNING :{WHITE}Missing GRF file(s) have been disabled
STR_NEWGRF_NOT_FOUND_WARNING :{WHITE}Missing GRF file(s) to be able to load game
STR_NEWGRF_UNPAUSE_WARNING_TITLE :{YELLOW}Missing GRF file(s)
STR_NEWGRF_UNPAUSE_WARNING :{WHITE}Unpausing can crash OpenTTD. Do not file bug reports for subsequent crashes.{}Do you really want to unpause?
STR_CURRENCY_WINDOW :{WHITE}Custom currency
STR_CURRENCY_EXCHANGE_RATE :{LTBLUE}Exchange rate: {ORANGE}{CURRENCY} = £ {COMMA}
@@ -3289,6 +3298,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Height o
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Center the smallmap on the current position
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Small
@@ -3443,3 +3453,20 @@ STR_FACE_TIE :Tie:
STR_FACE_EARRING :Earring:
STR_FACE_TIE_EARRING_TIP :{BLACK}Change tie or earring
########
############ signal GUI
STR_SIGNAL_SELECTION :{WHITE}Signal Selection
STR_SIGNAL_CAN_T_CONVERT_SIGNALS_HERE :{WHITE}Can't convert signals here...
STR_BUILD_SIGNAL_SEMAPHORE_NORM_TIP :{BLACK}Standard Signal (semaphore){}Signals are necessary to keep trains from crashing on railway networks with more than one train.
STR_BUILD_SIGNAL_SEMAPHORE_ENTRY_TIP :{BLACK}Entry-Signal (semaphore){}Green as long as there is one or more green exit-signal from the following section of track. Otherwise it shows red.
STR_BUILD_SIGNAL_SEMAPHORE_EXIT_TIP :{BLACK}Exit-Signal (semaphore){}Behaves in the same way as a normal signal but is necessary to trigger the correct colour on entry & combo pre-signals.
STR_BUILD_SIGNAL_SEMAPHORE_COMBO_TIP :{BLACK}Combo-Signal (semaphore){}The combo signal simply acts as both an entry and exit signal. This allows you to build large "trees" of presignals.
STR_BUILD_SIGNAL_ELECTRIC_NORM_TIP :{BLACK}Standard Signal (electric){}Signals are necessary to keep trains from crashing on railway networks with more than one train.
STR_BUILD_SIGNAL_ELECTRIC_ENTRY_TIP :{BLACK}Entry-Signal (electric){}Green as long as there is one or more green exit-signal from the following section of track. Otherwise it shows red.
STR_BUILD_SIGNAL_ELECTRIC_EXIT_TIP :{BLACK}Exit-Signal (electric){}Behaves in the same way as a normal signal but is necessary to trigger the correct colour on entry & combo pre-signals.
STR_BUILD_SIGNAL_ELECTRIC_COMBO_TIP :{BLACK}Combo-Signal (electric){}The combo signal simply acts as both an entry and exit signal. This allows you to build large "trees" of presignals.
STR_SIGNAL_CONVERT_TIP :{BLACK}Signal Convert{}When selected, clicking an existing signal will convert it to the selected signal type and variant, CTRL-click will toggle the existing variant.
STR_DRAG_SIGNALS_DENSITY_TIP :{BLACK}Dragging signal density
STR_DRAG_SIGNALS_DENSITY_DECREASE_TIP :{BLACK}Decrease dragging signal density
STR_DRAG_SIGNALS_DENSITY_INCREASE_TIP :{BLACK}Increase dragging signal density
########

View File

@@ -2189,7 +2189,7 @@ STR_7072_VIEW_HQ :{BLACK}Vidu HQ
STR_RELOCATE_HQ :{BLACK}Relokigu HQ
STR_COMPANY_PASSWORD :{BLACK}Pasvorto
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Pasvorte protektu vian kompanion por eviti ke eksteruloj aliĝu.
STR_SET_COMPANY_PASSWORD :Agordu kompanian pasvorton
STR_SET_COMPANY_PASSWORD :{BLACK}Agordu kompanian pasvorton
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Monda Recesio!{}{}Financaj spertuloj timas ke malpliboniĝas treege! Ekonomio malboniĝadas!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Recesio finiĝis!{}{}Komerca pliboniĝos donas konfidon al industrioj! Ekonomio pliboniĝas!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Ŝaltu inter granda kaj malgranda fenestro

View File

@@ -2404,7 +2404,7 @@ STR_7072_VIEW_HQ :{BLACK}Vaata pe
STR_RELOCATE_HQ :{BLACK}Liiguta peakorterit
STR_COMPANY_PASSWORD :{BLACK}Salasõna
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Ettevõtte kaitsmine salasõnaga, et võõrad ei saaks ilma loata ühineda.
STR_SET_COMPANY_PASSWORD :Vali ettevõttele salasõna
STR_SET_COMPANY_PASSWORD :{BLACK}Vali ettevõttele salasõna
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Majanduslik tagasilöök!{}{}Finantseksperdid ennustavad suurt majanduslangust!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Madalseis on läbi!{}{}Suurem kauplemine julgustab majanduse tugevnemisega ettevõtteid!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Lülita aken suureks/väikseks

View File

@@ -2295,7 +2295,7 @@ STR_7072_VIEW_HQ :{BLACK}Näytä
STR_RELOCATE_HQ :{BLACK}Sijoita päämaja
STR_COMPANY_PASSWORD :{BLACK}Salasana
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Salasanalla voit suojata yhtiösi, jotta kukaan vieras ei pääse liittymään.
STR_SET_COMPANY_PASSWORD :Aseta yhtiön salasana
STR_SET_COMPANY_PASSWORD :{BLACK}Aseta yhtiön salasana
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Maailmanlaajuinen laskukausi!{}{}Rahoitusasiantuntijat pelkäävät pahinta talouden laskiessa!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Laskukausi ohi!{}{}Kaupankäynnin käänne parempaan lisää luottamusta teollisuuteen talouden vahvistuessa!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Suuri/pieni ikkunan koko

View File

@@ -595,6 +595,9 @@ STR_0208_ACCIDENTS_DISASTERS :{YELLOW}Acciden
STR_0209_COMPANY_INFORMATION :{YELLOW}Informations corporatives
STR_NEWS_OPEN_CLOSE :{YELLOW}Ouvertures/fermetures d'industries
STR_020A_ECONOMY_CHANGES :{YELLOW}Changements économiques
STR_INDUSTRY_CHANGES_SERVED_BY_PLAYER :{YELLOW}Changements de production des industries desservies par vous
STR_INDUSTRY_CHANGES_SERVED_BY_OTHER :{YELLOW}Changements de production des industries desservies par les autres
STR_OTHER_INDUSTRY_PRODUCTION_CHANGES :{YELLOW}Changement de production des industries non desservies
STR_020B_ADVICE_INFORMATION_ON_PLAYER :{YELLOW}Conseils / information sur les véhicules du joueur
STR_020C_NEW_VEHICLES :{YELLOW}Nouveaux véhicules
STR_020D_CHANGES_OF_CARGO_ACCEPTANCE :{YELLOW}Changements d'acceptation de marchandises
@@ -1167,6 +1170,7 @@ STR_CONFIG_PATCHES_SMOOTH_ECONOMY :{LTBLUE}Permett
STR_CONFIG_PATCHES_ALLOW_SHARES :{LTBLUE}Permettre d'acheter des actions d'autres compagnies
STR_CONFIG_PATCHES_DRAG_SIGNALS_DENSITY :{LTBLUE}Espacements des signaux en mode drag & drop : {ORANGE}{STRING} case(s)
STR_CONFIG_PATCHES_SEMAPHORE_BUILD_BEFORE_DATE :{LTBLUE}Construire automatiquement des sémaphores avant: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ENABLE_SIGNAL_GUI :{LTBLUE}Activer le GUI des signaux: {ORANGE}{STRING}
STR_CONFIG_PATCHES_TOWN_LAYOUT_INVALID :{WHITE}Le schéma de ville "pas de routes" n'est pas autorisé dans l'éditeur de scénario
STR_CONFIG_PATCHES_TOWN_LAYOUT :{LTBLUE}Choisir un schéma de ville: {ORANGE}{STRING}
@@ -1681,6 +1685,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}Construi
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}Construire un pont
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}Construire un tunnel routier
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}Construire un tunnel
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}Activer/Désactiver les routes à sens unique
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}Basculer construire/détruire routes
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}Basculer construire/retirer pour tramways
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}Choisir orientation du dépôt routier
@@ -1702,6 +1707,7 @@ STR_TOWN_LABEL :{WHITE}{TOWN}
STR_TOWN_LABEL_TINY_BLACK :{TINYFONT}{BLACK}{TOWN}
STR_TOWN_LABEL_TINY_WHITE :{TINYFONT}{WHITE}{TOWN}
STR_2002 :{TINYFONT}{BLACK}{SIGN}
STR_2002_WHITE :{TINYFONT}{WHITE}{SIGN}
STR_2004_BUILDING_MUST_BE_DEMOLISHED :{WHITE}L'édifice doit d'abord être démolit
STR_2005 :{WHITE}{TOWN}
STR_2006_POPULATION :{BLACK}Population: {ORANGE}{COMMA}{BLACK} Maisons: {ORANGE}{COMMA}
@@ -2305,7 +2311,7 @@ STR_7072_VIEW_HQ :{BLACK}Voir le
STR_RELOCATE_HQ :{BLACK}Déménager le QG
STR_COMPANY_PASSWORD :{BLACK}Mot de passe
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Permet de protéger par mot de passe votre compagnie pour empêcher des utilisateurs non-autorisés de rejoindre. Utilisez '*' pour vider le mot de passe.
STR_SET_COMPANY_PASSWORD :Choisir le mot de passe de la compagnie
STR_SET_COMPANY_PASSWORD :{BLACK}Choisir le mot de passe de la compagnie
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Récession mondiale!{}{}Les experts financiers craignent le pire!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Fin de la récession!{}{}La reprise redonne confiance aux industries!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Bascule entre une grande/petite fenêtre
@@ -3018,7 +3024,7 @@ STR_B001_ROAD_VEHICLE_DESTROYED :{BLACK}{BIGFONT
STR_B002_OIL_REFINERY_EXPLOSION :{BLACK}{BIGFONT}Explosion d'une raffinerie pétrolière près de {TOWN}!
STR_B003_FACTORY_DESTROYED_IN_SUSPICIOUS :{BLACK}{BIGFONT}Usine détruite dans des circonstances suspectes près de {TOWN}!
STR_B004_UFO_LANDS_NEAR :{BLACK}{BIGFONT}Un 'OVNI' a été découvert près de {TOWN}!
STR_B005_COAL_MINE_SUBSIDENCE_LEAVES :{BLACK}{BIGFONT}Affaissement d'une veine de charbon entraîne la desctruction de la mine de {TOWN}!
STR_B005_COAL_MINE_SUBSIDENCE_LEAVES :{BLACK}{BIGFONT}L'affaissement d'une veine de charbon entraîne la destruction de la mine de {TOWN}!
STR_B006_FLOOD_VEHICLE_DESTROYED :{BLACK}{BIGFONT}Inondations!{}Au moins {COMMA} présumé{P "" s} manquant{P "" s} ou mort{P "" s} après des inondations meurtrières!
STR_BRIBE_FAILED :{WHITE}Votre tentative de corruption à été
@@ -3286,6 +3292,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Altitude
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Centrer la carte sur la position actuelle
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Petit
@@ -3440,3 +3447,20 @@ STR_FACE_TIE :Cravate:
STR_FACE_EARRING :Boucle d'oreille:
STR_FACE_TIE_EARRING_TIP :{BLACK}Modifier la cravate ou la boucle d'oreille
########
############ signal GUI
STR_SIGNAL_SELECTION :{WHITE}Sélection des signaux
STR_SIGNAL_CAN_T_CONVERT_SIGNALS_HERE :{WHITE}Impossible de convertir les signaux...
STR_BUILD_SIGNAL_SEMAPHORE_NORM_TIP :{BLACK}Signal normal (sémaphore){}Les signaux sont nécessaires pour éviter les collisions sur les réseaux avec plus d'un train.
STR_BUILD_SIGNAL_SEMAPHORE_ENTRY_TIP :{BLACK}Signal d'entrée (sémaphore){}Vert tant qu'un ou plusieurs signaux de sortie sont verts dans le bloc. Rouge sinon.
STR_BUILD_SIGNAL_SEMAPHORE_EXIT_TIP :{BLACK}Signal de sortie (sémaphore){}Fonctionne comme un signal normal, mais est nécessaire pour commander les signaux d'entrée et combinés.
STR_BUILD_SIGNAL_SEMAPHORE_COMBO_TIP :{BLACK}Signal combiné (sémaphore){}Le signal combiné est simplement l'unification d'un signal d'entrée et d'un signal de sortie. Cela vous permet de construire de larges "arbres" de pré-signaux.
STR_BUILD_SIGNAL_ELECTRIC_NORM_TIP :{BLACK}Signal normal (électrique){}Les signaux sont nécessaires pour éviter les collisions sur les réseaux avec plus d'un train.
STR_BUILD_SIGNAL_ELECTRIC_ENTRY_TIP :{BLACK}Signal d'entrée (électrique){}Vert tant qu'un ou plusieurs signaux de sortie sont verts dans le bloc. Rouge sinon.
STR_BUILD_SIGNAL_ELECTRIC_EXIT_TIP :{BLACK}Signal de sortie (électrique){}Fonctionne comme un signal normal, mais est nécessaire pour commander les signaux d'entrée et combinés.
STR_BUILD_SIGNAL_ELECTRIC_COMBO_TIP :{BLACK}Signal combiné (électrique){}Le signal combiné est simplement l'unification d'un signal d'entrée et d'un signal de sortie. Cela vous permet de construire de larges "arbres" de pré-signaux.
STR_SIGNAL_CONVERT_TIP :{BLACK}Conversion de signal{}Si sélectionné, cliquer sur un signal existant pour le convertir vers le type et la variante choisis, Ctrl-clic pour basculer la variante.
STR_DRAG_SIGNALS_DENSITY_TIP :{BLACK}Densité de signal
STR_DRAG_SIGNALS_DENSITY_DECREASE_TIP :{BLACK}Réduire la densité de signal
STR_DRAG_SIGNALS_DENSITY_INCREASE_TIP :{BLACK}Augmenter la densité de signal
########

View File

@@ -1050,6 +1050,8 @@ STR_CONFIG_PATCHES_REVERSE_SCROLLING :{LTBLUE}Inverti
STR_CONFIG_PATCHES_LIVERIES_NONE :Ningunha
STR_CONFIG_PATCHES_LIVERIES_ALL :Tódalas compañías
STR_CONFIG_PATCHES_MAX_TRAINS :{LTBLUE}Nº máximo de trens por xogador: {ORANGE}{STRING}
STR_CONFIG_PATCHES_MAX_ROADVEH :{LTBLUE}Nº máximo de vehículos de estrada por xogador: {ORANGE}{STRING}
STR_CONFIG_PATCHES_MAX_AIRCRAFT :{LTBLUE}Nº máximo de aeronaves por xogador: {ORANGE}{STRING}
@@ -1287,12 +1289,12 @@ STR_NETWORK_SET_PASSWORD :{BLACK}Establec
STR_NETWORK_PASSWORD_TIP :{BLACK}Protexe a túa partida cun contrasinal se non queres que outras persoas se unan
STR_NETWORK_SELECT_MAP :{BLACK}Selecciona un mapa:
STR_NETWORK_SELECT_MAP_TIP :{BLACK}¿Que mapa queres xogar?
STR_NETWORK_NUMBER_OF_CLIENTS :{BLACK}Máximo de clientes permitidos:
STR_NETWORK_NUMBER_OF_CLIENTS_TIP :{BLACK}Escolle o máximo número de clientes. Non tódolas liñas teñen que estar cubertas
STR_NETWORK_LAN :LAN
STR_NETWORK_INTERNET :Internet
STR_NETWORK_LAN_INTERNET :LAN / Internet
STR_NETWORK_INTERNET_ADVERTISE :Internet (anunciar)
STR_NETWORK_NUMBER_OF_CLIENTS :{BLACK}Máximo de clientes permitidos:
STR_NETWORK_NUMBER_OF_CLIENTS_TIP :{BLACK}Escolle o máximo número de clientes. Non tódolas liñas teñen que estar cubertas
STR_NETWORK_NUMBER_OF_COMPANIES :{BLACK}Nº máx. de compañías:
STR_NETWORK_NUMBER_OF_COMPANIES_TIP :{BLACK}Limita-lo servidor a unha certa cantidade de compañías
STR_NETWORK_NUMBER_OF_SPECTATORS :{BLACK}Nº máx. de espectadores:
@@ -2132,7 +2134,7 @@ STR_7072_VIEW_HQ :{BLACK}Ve-lo CX
STR_RELOCATE_HQ :{BLACK}Reposicionar CX
STR_COMPANY_PASSWORD :{BLACK}Contrasinal
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Protexe a atúa compañía cun contrasinal para evitar que usuarios non autorizados se unan
STR_SET_COMPANY_PASSWORD :Establece o contrasinal da compañía
STR_SET_COMPANY_PASSWORD :{BLACK}Establece o contrasinal da compañía
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}¡Recesión Mundial!{}{}¡Os expertos en finanzas témense o peor a medida que a economía afúndese!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}¡Fin da Recesión!{}{}¡A mellora no comercio inspira confianza nas industrias a media que a economía reforzase!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Intercambiar entre fiestra grande/pequena
@@ -2494,6 +2496,7 @@ STR_8825_NON_STOP :{BLACK}Non Para
STR_8826_GO_TO :{BLACK}Ir a
STR_8827_FULL_LOAD :{BLACK}Cargar
STR_8828_UNLOAD :{BLACK}Descarga
STR_TIMETABLE_VIEW :{BLACK}Táboa de tempo
STR_8829_ORDERS :{WHITE}{VEHICLE} (Ordes)
STR_882A_END_OF_ORDERS :{SETX 10}- - Fin das Ordes - -
STR_FULLLOAD_OR_SERVICE :{SKIP}{SKIP}{STRING}
@@ -2572,6 +2575,8 @@ STR_TRAIN_NO_POWER :{RED}Sen enerx
STR_NEW_VEHICLE_NOW_AVAILABLE :{BLACK}{BIGFONT}¡Novo {STRING} agora dispoñible!
STR_NEW_VEHICLE_TYPE :{BLACK}{BIGFONT}{ENGINE}
STR_NEW_VEHICLE_NOW_AVAILABLE_WITH_TYPE :{BLACK}¡Nova{STRING} dispoñible! - {ENGINE}
##id 0x9000
@@ -3053,7 +3058,6 @@ STR_GROUP_CREATE_TIP :{BLACK}Pincha p
STR_GROUP_DELETE_TIP :{BLACK}Borrar o grupo seleccionado
STR_GROUP_RENAME_TIP :{BLACK}Renomear o grupo seleccionado
STR_COMPANY_NAME :{COMPANY}
STR_ENGINE_NAME :{ENGINE}
STR_GROUP_NAME :{GROUP}
@@ -3066,3 +3070,9 @@ STR_VEHICLE_NAME :{VEHICLE}
########
############ Face formatting
########
############ signal GUI
########

View File

@@ -2305,7 +2305,7 @@ STR_7072_VIEW_HQ :{BLACK}Firmensi
STR_RELOCATE_HQ :{BLACK}Firmensitz verlegen
STR_COMPANY_PASSWORD :{BLACK}Passwort
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Sie können Ihre Firma mit einem Passwort schützen, sodass nur ausgewählte Spieler beitreten können.
STR_SET_COMPANY_PASSWORD :Firmenpasswort setzen
STR_SET_COMPANY_PASSWORD :{BLACK}Firmenpasswort setzen
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Weltwirtschaftskrise!{}{}Finanzexperten befürchten schlimmsten Zusammenbruch der Wirtschaft!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Wirtschaftskrise beendet!{}{}Aufschwung des Handels gibt Vertrauen in die Industrie und stärkt die Wirtschaft!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Schalter für großes/kleines Fenster

View File

@@ -2404,7 +2404,7 @@ STR_7072_VIEW_HQ :{BLACK}Székhá
STR_RELOCATE_HQ :{BLACK}FH áthelyezése
STR_COMPANY_PASSWORD :{BLACK}Jelszó
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Védd le a vállalatodat jelszóval ha nem akarod hogy mások csatlakozzanak hozzá.
STR_SET_COMPANY_PASSWORD :Vállalati jelszó beállítása
STR_SET_COMPANY_PASSWORD :{BLACK}Vállalati jelszó beállítása
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Gazdasági visszaesés!{}{}A közgazdászok gazdasági válságtól tartanak!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Vége a visszaesésnek!{}{}A kereskedelem fellendül, ami önbizalmat ad az iparnak, és erősödik a gazdaság!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Kicsi/nagy ablakméret közötti váltás

View File

@@ -2154,7 +2154,7 @@ STR_7072_VIEW_HQ :{BLACK}Skoða H
STR_RELOCATE_HQ :{BLACK}Flytja HS
STR_COMPANY_PASSWORD :{BLACK}Lykilorð
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Til að vernda fyrirtæki þitt frá óboðnum notendum geturðu sett lykilorð á það
STR_SET_COMPANY_PASSWORD :Setja lykilorð á fyrirtæki
STR_SET_COMPANY_PASSWORD :{BLACK}Setja lykilorð á fyrirtæki
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Heimssamdráttur!{}{}Hagfræðingar hræddir um efnahagshrun!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Samdráttur!{}{}Uppslag í viðskiptum gefur bjartari von um betri efnahag!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Stækka/smækka gluggastærð

View File

@@ -1171,6 +1171,7 @@ STR_CONFIG_PATCHES_SMOOTH_ECONOMY :{LTBLUE}Abilita
STR_CONFIG_PATCHES_ALLOW_SHARES :{LTBLUE}Permetti l'acquisto di azioni di altre compagnie
STR_CONFIG_PATCHES_DRAG_SIGNALS_DENSITY :{LTBLUE}Trascinando il cursore, piazza i segnali ogni: {ORANGE}{STRING} quadrato/i
STR_CONFIG_PATCHES_SEMAPHORE_BUILD_BEFORE_DATE :{LTBLUE}Costruisci automaticamente i semafori prima del: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ENABLE_SIGNAL_GUI :{LTBLUE}Abilita l'interfaccia di selezione segnali: {ORANGE}{STRING}
STR_CONFIG_PATCHES_TOWN_LAYOUT_INVALID :{WHITE}L'opzione "Nessuna nuova strada" non è valida nell'editor di scenari
STR_CONFIG_PATCHES_TOWN_LAYOUT :{LTBLUE}Disposizione delle strade cittadine: {ORANGE}{STRING}
@@ -1685,6 +1686,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}Costruis
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}Costruisce un ponte tranviario
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}Costruisce un tunnel stradale
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}Costruisce un tunnel tranviario
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}Attiva/disattiva strade a senso unico
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}Seleziona fra costruzione/rimozione di strade
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}Seleziona fra costruzione/rimozione di tranvie
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}Seleziona l'orientamento del deposito automezzi
@@ -1706,6 +1708,7 @@ STR_TOWN_LABEL :{WHITE}{TOWN}
STR_TOWN_LABEL_TINY_BLACK :{TINYFONT}{BLACK}{TOWN}
STR_TOWN_LABEL_TINY_WHITE :{TINYFONT}{WHITE}{TOWN}
STR_2002 :{TINYFONT}{BLACK}{SIGN}
STR_2002_WHITE :{TINYFONT}{WHITE}{SIGN}
STR_2004_BUILDING_MUST_BE_DEMOLISHED :{WHITE}L'edificio deve essere demolito prima
STR_2005 :{WHITE}{TOWN}
STR_2006_POPULATION :{BLACK}Popolazione: {ORANGE}{COMMA}{BLACK} Case: {ORANGE}{COMMA}
@@ -2309,7 +2312,7 @@ STR_7072_VIEW_HQ :{BLACK}Vedi sed
STR_RELOCATE_HQ :{BLACK}Sposta sede
STR_COMPANY_PASSWORD :{BLACK}Password
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Protegge la compagnia con una password per impedire ad utenti non autorizzati di accedervi.
STR_SET_COMPANY_PASSWORD :Imposta password compagnia
STR_SET_COMPANY_PASSWORD :{BLACK}Imposta password compagnia
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Recessione mondiale!{}{}Il crollo dell'economia porta gli analisti finanziari a temere il peggio!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Recessione finita!{}{}La ripresa del commercio da fiducia alle industrie e rafforza l'economia!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Seleziona dimensione grande/piccola della finestra
@@ -3290,6 +3293,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Altezza
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Centra la minimappa sulla posizione corrente
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Piccolo
@@ -3444,3 +3448,20 @@ STR_FACE_TIE :Cravatta:
STR_FACE_EARRING :Orecchino:
STR_FACE_TIE_EARRING_TIP :{BLACK}Cambia la cravatta o l'orecchino
########
############ signal GUI
STR_SIGNAL_SELECTION :{WHITE}Selezione segnale
STR_SIGNAL_CAN_T_CONVERT_SIGNALS_HERE :{WHITE}Impossibile convertire i segnali qui...
STR_BUILD_SIGNAL_SEMAPHORE_NORM_TIP :{BLACK}Segnale normale (semaforico){}I segnali sono necessari per impedire ai treni di scontrarsi su reti ferroviarie con più di un treno.
STR_BUILD_SIGNAL_SEMAPHORE_ENTRY_TIP :{BLACK}Pre-segnale (semaforico){}Verde se è presente almeno un segnale di uscita verde al termine della sezione di blocco successiva. Altrimenti presenta il rosso.
STR_BUILD_SIGNAL_SEMAPHORE_EXIT_TIP :{BLACK}Segnale di uscita (semaforico){}Si comporta come un segnale normale, ma è necessario per far funzionare correttamente i pre-segnali e i segnali combinati all'ingresso della sezione di blocco.
STR_BUILD_SIGNAL_SEMAPHORE_COMBO_TIP :{BLACK}Segnale combinato (semaforico){}Un segnale combinato funziona contemporaneamente da segnale d'uscita e da pre-segnale. In questo modo è possibile costruire "alberi" di pre-segnali.
STR_BUILD_SIGNAL_ELECTRIC_NORM_TIP :{BLACK}Segnale normale (luminoso){}I segnali sono necessari per impedire ai treni di scontrarsi su reti ferroviarie con più di un treno.
STR_BUILD_SIGNAL_ELECTRIC_ENTRY_TIP :{BLACK}Pre-segnale (luminoso){}Verde se è presente almeno un segnale di uscita verde al termine della sezione di blocco successiva. Altrimenti presenta il rosso.
STR_BUILD_SIGNAL_ELECTRIC_EXIT_TIP :{BLACK}Segnale di uscita (luminoso){}Si comporta come un segnale normale, ma è necessario per far funzionare correttamente i pre-segnali e i segnali combinati all'ingresso della sezione di blocco.
STR_BUILD_SIGNAL_ELECTRIC_COMBO_TIP :{BLACK}Segnale combinato (luminoso){}Un segnale combinato funziona contemporaneamente da segnale d'uscita e da pre-segnale. In questo modo è possibile costruire "alberi" di pre-segnali.
STR_SIGNAL_CONVERT_TIP :{BLACK}Conversione segnali - Se attivato, facendo clic su un segnale esistente lo si converte nel tipo selezionato, mentre con CTRL+clic se ne modifica la variante.
STR_DRAG_SIGNALS_DENSITY_TIP :{BLACK}Distanza fra i segnali costruiti automaticamente trascinando il cursore
STR_DRAG_SIGNALS_DENSITY_DECREASE_TIP :{BLACK}Riduce la distanza fra i segnali costruiti
STR_DRAG_SIGNALS_DENSITY_INCREASE_TIP :{BLACK}Aumenta la distanza fra i segnali costruiti
########

View File

@@ -594,6 +594,9 @@ STR_0208_ACCIDENTS_DISASTERS :{YELLOW}事故
STR_0209_COMPANY_INFORMATION :{YELLOW}会社情報
STR_NEWS_OPEN_CLOSE :{YELLOW}産業の開業/閉業
STR_020A_ECONOMY_CHANGES :{YELLOW}経済の変化
STR_INDUSTRY_CHANGES_SERVED_BY_PLAYER :{YELLOW}プレヤーが運送している産業の生産量が変更したとき
STR_INDUSTRY_CHANGES_SERVED_BY_OTHER :{YELLOW}競争者が運送している産業の生産量が変更したとき
STR_OTHER_INDUSTRY_PRODUCTION_CHANGES :{YELLOW}その他の産業の生産量が変更したとき
STR_020B_ADVICE_INFORMATION_ON_PLAYER :{YELLOW}プレヤーの車両についての情報
STR_020C_NEW_VEHICLES :{YELLOW}車両の新登場
STR_020D_CHANGES_OF_CARGO_ACCEPTANCE :{YELLOW}貨物の受入れの変化
@@ -1680,6 +1683,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}道路
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}路面電車用橋を建設
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}道路のトンネルを建設します
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}路面電車用トンネルを建設
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}一方通行の道路を入/切
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}道路の建設/破壊を切り替えます
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}路面電車線の建設/破壊を切り替えます
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}車庫の配置の選択
@@ -2304,7 +2308,7 @@ STR_7072_VIEW_HQ :{BLACK}本部
STR_RELOCATE_HQ :{BLACK}本部ビルを移動
STR_COMPANY_PASSWORD :{BLACK}パスワード
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}他のプレヤーがこの会社の経営に参加できないようにするには、パスワードで保護します
STR_SET_COMPANY_PASSWORD :会社のパスワードを設定
STR_SET_COMPANY_PASSWORD :{BLACK}会社のパスワードを設定
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}世界中不景気!{}{}経済がスランプに陥る、アナリストの不安説!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}スランプの終わり!{}{}経済が上昇気流、産業が好転!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}大きい/小さいウィンドウサイズを切り替えます
@@ -3285,6 +3289,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}平地
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}予約地図を現在の場所に移動します
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}町空港

View File

@@ -1113,6 +1113,9 @@ STR_CONFIG_PATCHES_RIGHT_MOUSE_BTN_EMU_OFF :끄기
STR_CONFIG_PATCHES_PAUSE_ON_NEW_GAME :{LTBLUE}새로운 게임 시작할 때 자동으로 일시정지: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ADVANCED_VEHICLE_LISTS :{LTBLUE}진보된 차량 목록 사용: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LOADING_INDICATORS :{LTBLUE}적재 정도 표시: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LOADING_INDICATORS_OFF :끄기
STR_CONFIG_PATCHES_LOADING_INDICATORS_OWN :소유한 회사
STR_CONFIG_PATCHES_LOADING_INDICATORS_ALL :모든 회사
STR_CONFIG_PATCHES_TIMETABLE_ALLOW :{LTBLUE}차량에 시간표 사용: {ORANGE}{STRING}
STR_CONFIG_PATCHES_TIMETABLE_IN_TICKS :{LTBLUE}시간표를 일(日)이 아닌 틱으로 표시: {ORANGE}{STRING}
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE :{LTBLUE}기본 철도 종류 (새 게임/불러오기 후): {ORANGE}{STRING}
@@ -1181,6 +1184,7 @@ STR_CONFIG_PATCHES_TOWN_GROWTH_VERY_FAST :매우 빠름
STR_CONFIG_PATCHES_LARGER_TOWNS :{LTBLUE}2배 빠르게 성장하는 마을의 비율: {ORANGE}1 대 {STRING}
STR_CONFIG_PATCHES_LARGER_TOWNS_DISABLED :{LTBLUE}2배 빠르게 성장하는 마을의 비율: {ORANGE}없음
STR_CONFIG_PATCHES_CITY_SIZE_MULTIPLIER :{LTBLUE}초기의 도시 크기 배수: {ORANGE}{STRING}
STR_CONFIG_MODIFIED_ROAD_REBUILD :{LTBLUE}도로 건설 중 부조리한 도로 요소를 제거
STR_CONFIG_PATCHES_GUI :{BLACK}인터페이스
STR_CONFIG_PATCHES_CONSTRUCTION :{BLACK}건설
@@ -1657,7 +1661,9 @@ STR_1809_CAN_T_BUILD_CARGO_TRAM_STATION :{WHITE}여기
STR_180A_ROAD_CONSTRUCTION :도로 건설
STR_180A_TRAMWAY_CONSTRUCTION :전찻길 건설
STR_180B_BUILD_ROAD_SECTION :{BLACK}도로 섹션 건설
STR_BUILD_AUTOROAD_TIP :{BLACK}자동건설 모드로 도로 섹션 건설
STR_180B_BUILD_TRAMWAY_SECTION :{BLACK}전찻길 섹션 건설
STR_BUILD_AUTOTRAM_TIP :{BLACK}자동건설 모드로 전차 섹션 건설
STR_180C_BUILD_ROAD_VEHICLE_DEPOT :{BLACK}차고 건설 (차량의 제작/점검용)
STR_180C_BUILD_TRAM_VEHICLE_DEPOT :{BLACK}차량기지 건설 (차량 건설/점검용)
STR_180D_BUILD_BUS_STATION :{BLACK}버스 정류장 건설
@@ -1668,6 +1674,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}교량
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}철교 건설
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}터널 건설
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}터널 건설
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}일방통행 활성/비활성화
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}도로 제거툴 켜기/끄기
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}전찻길/신호등 제거툴 켜기/끄기
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}차고의 방향을 선택하십시오
@@ -2011,6 +2018,8 @@ STR_5005_UNABLE_TO_EXCAVATE_LAND :{WHITE}지형
STR_5006_MUST_DEMOLISH_TUNNEL_FIRST :{WHITE}터널을 먼저 제거하십시오
STR_5007_MUST_DEMOLISH_BRIDGE_FIRST :{WHITE}다리를 먼저 제거하십시오
STR_5008_CANNOT_START_AND_END_ON :{WHITE}같은 위치에서 시작하고 끝낼 수 없습니다
STR_BRIDGEHEADS_NOT_SAME_HEIGHT :{WHITE}다리는 같은 높이를 연결해야 합니다
STR_BRIDGE_TOO_LOW_FOR_TERRAIN :{WHITE}그 지형은 다리를 건설하기에 너무 낮습니다
STR_500A_START_AND_END_MUST_BE_IN :{WHITE}시작과 끝은 한 줄 위에 있어야 합니다
STR_500B_SITE_UNSUITABLE_FOR_TUNNEL :{WHITE}터널 입구에 알맞지 않은 장소입니다
STR_500D :{GOLD}{STRING},{} {VELOCITY} {WHITE}{CURRENCY}
@@ -2290,7 +2299,7 @@ STR_7072_VIEW_HQ :{BLACK}본사
STR_RELOCATE_HQ :{BLACK}본사 재위치
STR_COMPANY_PASSWORD :{BLACK}암호
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}다른 참가자가 이 회사로의 플레이를 하지 못하도록 암호로 보호합니다
STR_SET_COMPANY_PASSWORD :회사 암호 설정
STR_SET_COMPANY_PASSWORD :{BLACK}회사 암호 설정
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}세계 공황!{}{}경제 전문가들이 경제 슬럼프에 대해 우려를 표망하고 있습니다!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}공황 종료!{}{}무역량의 증대로 경제를 살려낸 결과 산업시설에 대한 신뢰를 가져왔습니다!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}대형/소형 창 크기 토글
@@ -2770,6 +2779,8 @@ STR_NEW_VEHICLE_NOW_AVAILABLE :{BLACK}{BIGFONT
STR_NEW_VEHICLE_TYPE :{BLACK}{BIGFONT}{ENGINE}
STR_NEW_VEHICLE_NOW_AVAILABLE_WITH_TYPE :{BLACK}신형 {STRING} 이(가) 출시되었습니다! - {ENGINE}
STR_CAN_T_SELL_DESTROYED_VEHICLE :{WHITE}폭발한 차량을 팔 수 없습니다...
STR_CAN_T_TIMETABLE_VEHICLE :{WHITE}차량의 시간표를 정할 수 없습니다...
STR_TIMETABLE_ONLY_WAIT_AT_STATIONS :{WHITE}정거장에서만 기다릴 수 있습니다.
STR_TIMETABLE_NOT_STOPPING_HERE :{WHITE}이 차량은 이 정거장에 서지 않습니다.
@@ -3058,7 +3069,9 @@ STR_NEWGRF_ERROR_UNSET_SWITCH :{STRING}(은)
STR_NEWGRF_ERROR_INVALID_PARAMETER :{STRING}의 부적절한 파라미터: 파라미터 {STRING} ({NUM})
STR_NEWGRF_ERROR_LOAD_BEFORE :{STRING}은/는 반드시 {STRING}이전에 불러와야 합니다.
STR_NEWGRF_ERROR_LOAD_AFTER :{STRING}은/는 반드시 {STRING}다음에 불러와야 합니다.
STR_NEWGRF_ERROR_OTTD_VERSION_NUMBER :{STRING}는 OpenTTD {STRING} 버전이나 그 이상이 필요합니다.
STR_NEWGRF_ERROR_AFTER_TRANSLATED_FILE :GRF 파일 자체는 번역용으로 디자인됨
STR_NEWGRF_ERROR_TOO_MANY_NEWGRFS_LOADED :NewGRF이 너무 많습니다.
STR_NEWGRF_ADD :{BLACK}추가
STR_NEWGRF_ADD_TIP :{BLACK}NewGRF 파일을 목록에 추가
@@ -3267,6 +3280,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}평지
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}소형맵을 현재 위치에 위치시킵니다
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}소형 공항
@@ -3373,3 +3387,51 @@ STR_FUND_NEW_INDUSTRY :{BLACK}투자
STR_PROSPECT_NEW_INDUSTRY :{BLACK}예측
STR_BUILD_NEW_INDUSTRY :{BLACK}건설
STR_INDUSTRY_SELECTION_HINT :{BLACK}목록에서 적당한 산업시설을 선택하십시오
############ Face formatting
STR_FACE_ADVANCED :{BLACK}고급
STR_FACE_ADVANCED_TIP :{BLACK}고급 얼굴 선택
STR_FACE_SIMPLE :{BLACK}간단
STR_FACE_SIMPLE_TIP :{BLACK}간단한 얼굴 선택
STR_FACE_LOAD :{BLACK}불러오기
STR_FACE_LOAD_TIP :{BLACK}즐겨찾는 얼굴 불러오기
STR_FACE_LOAD_DONE :{WHITE}당신이 즐겨찾는 얼굴을 OpenTTD 설정 파일로부터 불러왔습니다.
STR_FACE_FACECODE :{BLACK}플레이어 얼굴 없음.
STR_FACE_FACECODE_TIP :{BLACK}플레이어 얼굴 번호 보기/설정
STR_FACE_FACECODE_CAPTION :{WHITE}플레이어 얼굴 번호 보기/설정
STR_FACE_FACECODE_SET :{WHITE}새 얼굴 번호 코드가 설정되었습니다.
STR_FACE_FACECODE_ERR :{WHITE}플레이어 얼굴 번호를 설정할 수 없습니다 - 0에서 4,294,967,295 사이의 값을 입력하십시오!
STR_FACE_SAVE :{BLACK}저장
STR_FACE_SAVE_TIP :{BLACK}즐겨찾는 얼굴로 저장
STR_FACE_SAVE_DONE :{WHITE}이 얼굴이 OpenTTD 설정 파일에 즐겨찾는 얼굴로 저장될 것입니다.
STR_FACE_EUROPEAN :{BLACK}유럽인
STR_FACE_SELECT_EUROPEAN :{BLACK}유럽인 얼굴 선택
STR_FACE_AFRICAN :{BLACK}흑인
STR_FACE_SELECT_AFRICAN :{BLACK}흑인 얼굴 선택
STR_FACE_YES :예
STR_FACE_NO :아니요
STR_FACE_MOUSTACHE_EARRING_TIP :{BLACK}콧수염이나 귀걸이 착용
STR_FACE_HAIR :머리:
STR_FACE_HAIR_TIP :{BLACK}머리 변경
STR_FACE_EYEBROWS :눈썹:
STR_FACE_EYEBROWS_TIP :{BLACK}눈썹 변경
STR_FACE_EYECOLOUR :눈동자 색:
STR_FACE_EYECOLOUR_TIP :{BLACK}눈동자색 변경
STR_FACE_GLASSES :안경:
STR_FACE_GLASSES_TIP :{BLACK}안경 착용
STR_FACE_GLASSES_TIP_2 :{BLACK}안경 변경
STR_FACE_NOSE :코:
STR_FACE_NOSE_TIP :{BLACK}코 변경
STR_FACE_LIPS :입술:
STR_FACE_MOUSTACHE :콧수염:
STR_FACE_LIPS_MOUSTACHE_TIP :{BLACK}입술/콧수염 변경
STR_FACE_CHIN :턱:
STR_FACE_CHIN_TIP :{BLACK}턱 변경
STR_FACE_JACKET :자켓:
STR_FACE_JACKET_TIP :{BLACK}자켓 변경
STR_FACE_COLLAR :옷깃:
STR_FACE_COLLAR_TIP :{BLACK}옷깃 변경
STR_FACE_TIE :넥타이:
STR_FACE_EARRING :귀걸이:
STR_FACE_TIE_EARRING_TIP :{BLACK}넥타이/귀걸이 변경
########

View File

@@ -5,6 +5,8 @@
##case kas ko kam ka kuo kur kreip
##gender vyr mot
#
##id 0x0000
STR_NULL :
STR_0001_OFF_EDGE_OF_MAP :{WHITE}Už žemelapio kraštų
@@ -313,6 +315,7 @@ STR_OSNAME_BEOS :BeOS
STR_OSNAME_MORPHOS :MorphOS
STR_OSNAME_AMIGAOS :AmigaOS
STR_OSNAME_OS2 :OS/2
STR_OSNAME_SUNOS :SunOS
STR_013B_OWNED_BY :{WHITE}...priklauso {STRING}
STR_013C_CARGO :{BLACK}Keliamoji galia
@@ -781,6 +784,7 @@ STR_02A0_ENDS_OF_BRIDGE_MUST_BOTH :{WHITE}...abu t
STR_02A1_SMALL :{BLACK}Mažas
STR_02A2_MEDIUM :{BLACK}Vidutinis
STR_02A3_LARGE :{BLACK}Didelis
STR_SCENARIO_EDITOR_CITY :{BLACK}Miestas
STR_02A4_SELECT_TOWN_SIZE :{BLACK}Išsirinkite miesto dydį
STR_02A5_TOWN_SIZE :{YELLOW}Miesto dydis:
@@ -805,6 +809,7 @@ STR_02C3_GAME_OPTIONS :Žaidimo nustat
STR_02C5_DIFFICULTY_SETTINGS :Sunkumo lygio nustatymai
STR_02C7_CONFIG_PATCHES :Papildomi nustatymai
STR_NEWGRF_SETTINGS :Papild. grafikos nustatymai (NewGRF)
STR_TRANSPARENCY_OPTIONS :Permatomumo nustatymai
STR_GAMEOPTMENU_0A :
STR_02CA_TOWN_NAMES_DISPLAYED :{SETX 12}Rodyti miestų pavadinimus
STR_02CC_STATION_NAMES_DISPLAYED :{SETX 12}Rodyti stotelių pavadinimus
@@ -1060,6 +1065,7 @@ STR_CONFIG_PATCHES_INFLATION :{LTBLUE}Infliac
STR_CONFIG_PATCHES_SELECTGOODS :{LTBLUE}Pristatyti krovini stotelei tiktai tuomet, kai yra poreikis: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LONGBRIDGES :{LTBLUE}Leisti statyti labai ilgus tiltus: {ORANGE}{STRING}
STR_CONFIG_PATCHES_GOTODEPOT :{LTBLUE}Leisti naudoti uzduoti 'Keliauti i depa': {ORANGE}{STRING}
STR_CONFIG_PATCHES_RAW_INDUSTRY_CONSTRUCTION_METHOD_NONE :nėra
STR_CONFIG_PATCHES_MULTIPINDTOWN :{LTBLUE}Leisti kelias panašias pramonės įmones viename mieste: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SAMEINDCLOSE :{LTBLUE}Leisti statyti to paties tipo fabrikus arti vienas kito: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LONGDATE :{LTBLUE}Rodyti pilna data busenos eiluteje: {ORANGE}{STRING}
@@ -1119,6 +1125,8 @@ STR_CONFIG_PATCHES_LIVERIES_OWN :Savo kompanijos
STR_CONFIG_PATCHES_LIVERIES_ALL :Visų kompanijų
STR_CONFIG_PATCHES_PREFER_TEAMCHAT :{LTBLUE}Rašyti komandai naudojant <ĮVESTI> (ENTER): {ORANGE}{STRING}
STR_CONFIG_PATCHES_MAX_TRAINS :{LTBLUE}Maks. traukiniu vienam zaidejui: {ORANGE}{STRING}
STR_CONFIG_PATCHES_MAX_ROADVEH :{LTBLUE}Maks. automobiliu zaidejui: {ORANGE}{STRING}
STR_CONFIG_PATCHES_MAX_AIRCRAFT :{LTBLUE}Maks. lektuvu zaidejui: {ORANGE}{STRING}
@@ -1151,6 +1159,8 @@ STR_CONFIG_PATCHES_SMOOTH_ECONOMY :{LTBLUE}Tolygi
STR_CONFIG_PATCHES_ALLOW_SHARES :{LTBLUE}Leisti pirkti kitų kompanijų akcijas
STR_CONFIG_PATCHES_DRAG_SIGNALS_DENSITY :{LTBLUE}Tempiant, kopijuoti šviesoforus kas: {ORANGE}{STRING} langel{P į lius lių}
STR_CONFIG_PATCHES_SEMAPHORE_BUILD_BEFORE_DATE :{LTBLUE}Automatiškai pastatyti semaforus prieš: {ORANGE}{STRING}
STR_CONFIG_PATCHES_TOOLBAR_POS :{LTBLUE}Pagrindines irankiu juostos pozicija: {ORANGE}{STRING}
STR_CONFIG_PATCHES_TOOLBAR_POS_LEFT :Kaireje
STR_CONFIG_PATCHES_TOOLBAR_POS_CENTER :Centruoti
@@ -1354,12 +1364,12 @@ STR_NETWORK_SET_PASSWORD :{BLACK}Nustatyt
STR_NETWORK_PASSWORD_TIP :{BLACK}Apsaugokite savo zaidima slaptazodziu, jei nenorite, kad jis butu viesai prieinamas
STR_NETWORK_SELECT_MAP :{BLACK}Pasirinkite zemelapi:
STR_NETWORK_SELECT_MAP_TIP :{BLACK}Kuriame zemelapyje norite zaisti?
STR_NETWORK_NUMBER_OF_CLIENTS :{BLACK}Maksimalus klientu skaicius:
STR_NETWORK_NUMBER_OF_CLIENTS_TIP :{BLACK}Pasirinkite maksimalu klientu skaiciu. Nebutinai visos jungtys turi buti uzpildytos
STR_NETWORK_LAN :Vietinis tinklas
STR_NETWORK_INTERNET :Internetas
STR_NETWORK_LAN_INTERNET :Vietinis tinklas/ Internetas
STR_NETWORK_INTERNET_ADVERTISE :Internetas (visiems)
STR_NETWORK_NUMBER_OF_CLIENTS :{BLACK}Maksimalus klientu skaicius:
STR_NETWORK_NUMBER_OF_CLIENTS_TIP :{BLACK}Pasirinkite maksimalu klientu skaiciu. Nebutinai visos jungtys turi buti uzpildytos
STR_NETWORK_NUMBER_OF_COMPANIES :{BLACK}Maksimum kompaniju:
STR_NETWORK_NUMBER_OF_COMPANIES_TIP :{BLACK}Riboti serveri iki tam tikro skaiciaus kompaniju
STR_NETWORK_NUMBER_OF_SPECTATORS :{BLACK}Maksimum ziurovu:
@@ -1878,6 +1888,9 @@ STR_4828_REQUIRES :{BLACK}Reikalau
STR_4829_REQUIRES :{BLACK}Reikalauja: {YELLOW}{STRING.ko}, {STRING.ko}, {STRING.ko}
############ range for requires ends
############ range for produces starts
############ range for produces ends
STR_482A_PRODUCTION_LAST_MONTH :{BLACK}Praėjusio mėnesio produkcija:
STR_482B_TRANSPORTED :{YELLOW}{CARGO}{BLACK} ({COMMA}% transportuota)
STR_482C_CENTER_THE_MAIN_VIEW_ON :{BLACK}Rodyti gamykla ekrano centre
@@ -2184,7 +2197,7 @@ STR_7072_VIEW_HQ :{BLACK}Apziuret
STR_RELOCATE_HQ :{BLACK}Perkelti bustine
STR_COMPANY_PASSWORD :{BLACK}Slaptazodis
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Slaptazodis apsaugo tavo kompanija nuo neleistinu vartotoju prisijungimo.
STR_SET_COMPANY_PASSWORD :Ivesti slaptazodi
STR_SET_COMPANY_PASSWORD :{BLACK}Ivesti slaptazodi
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Pasauline krize!{}{}Ekonomikai griuvant, finansu ekspertai bijo paties blogiausio!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Krize iveikta!{}{}Prekybos pagyvejimas suteikia naujas viltis pramones imonems!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Pakeisti lango dydi
@@ -2518,6 +2531,7 @@ STR_SERVICE_AT_TRAIN_DEPOT :Remontas {TOWN}
STR_880F_GO_NON_STOP_TO_TRAIN_DEPOT :Važiuoti nestojant į {TOWN} traukinių depą
STR_SERVICE_NON_STOP_AT_TRAIN_DEPOT :Remontas nestojant {TOWN} traukiniu depe
STR_HEADING_FOR_TRAIN_DEPOT :{ORANGE}Kursas i {TOWN} depa
STR_HEADING_FOR_TRAIN_DEPOT_VEL :{ORANGE}Kursas i {TOWN} depa, {VELOCITY}
STR_HEADING_FOR_TRAIN_DEPOT_SERVICE :{LTBLUE}Servisas {TOWN} Traukiniu Depe
@@ -2639,6 +2653,9 @@ STR_INCOMPATIBLE_RAIL_TYPES :Nesuderinami be
STR_TRAIN_NO_POWER :{RED}Nėra energijos
STR_TRAIN_START_NO_CATENARY :Šiuose bėgiuose trūkta grandies, taigi traukiniai negali judėti
##id 0x9000
STR_9000_ROAD_VEHICLE_IN_THE_WAY :{WHITE}Automobilis kelyje
STR_9001_ROAD_VEHICLES :{WHITE}{COMPANY} - {COMMA} Automobiliai
@@ -2846,6 +2863,7 @@ STR_A042_CAN_T_REFIT_AIRCRAFT :{WHITE}Negalima
STR_GO_TO_AIRPORT_HANGAR :Kursas: {STATION} angaras
SERVICE_AT_AIRPORT_HANGAR :Remontas {STATION} angare
##id 0xB000
STR_B000_ZEPPELIN_DISASTER_AT :{BLACK}{BIGFONT} Dirizablio katastrofa {STATION}!
STR_B001_ROAD_VEHICLE_DESTROYED :{BLACK}{BIGFONT}Automobilis sunaikintas ateiviu!
@@ -2899,6 +2917,7 @@ STR_NEWGRF_GRF_ID :{BLACK}GRF ID:
STR_NEWGRF_MD5SUM :{BLACK}MD5suma: {SILVER}{STRING}
STR_NEWGRF_CONFIRMATION_TEXT :{YELLOW}Jūs norite atlikti pakeitimus veikiančiam žaidimui: OpenTTD gali pakibti.{}Ar jūs tikrai norite tai atlikti?
STR_NEWGRF_ADD :{BLACK}Pridėti
STR_NEWGRF_ADD_TIP :{BLACK}Pridėti Papild. grafikos failą į sąrašą
STR_NEWGRF_REMOVE :{BLACK}Pašalinti
@@ -3123,4 +3142,24 @@ STR_MEASURE_AREA :{BLACK}Sritis:
STR_MEASURE_LENGTH_HEIGHTDIFF :{BLACK}Atstumas: {NUM}{}Aukščių skirtumas: {NUM} m
STR_MEASURE_AREA_HEIGHTDIFF :{BLACK}Sritis: {NUM} x {NUM}{}Aukščių skirtumas: {NUM} m
############ Date formatting
########
##### Mass Order
#### Improved sign GUI
########
############ Face formatting
########

View File

@@ -595,6 +595,9 @@ STR_0208_ACCIDENTS_DISASTERS :{YELLOW}Ulykker
STR_0209_COMPANY_INFORMATION :{YELLOW}Firmainformasjon
STR_NEWS_OPEN_CLOSE :{YELLOW}Åpninger / Stengninger av industrier
STR_020A_ECONOMY_CHANGES :{YELLOW}Økonomiske endringer
STR_INDUSTRY_CHANGES_SERVED_BY_PLAYER :{YELLOW}Produksjonsendringer hos industrier som får leveranser av spilleren
STR_INDUSTRY_CHANGES_SERVED_BY_OTHER :{YELLOW}Produksjonsendringer hos industrier som får leveranser av motspiller(e)
STR_OTHER_INDUSTRY_PRODUCTION_CHANGES :{YELLOW}Andre produksjonsendringer
STR_020B_ADVICE_INFORMATION_ON_PLAYER :{YELLOW}Råd/informasjon om spillers kjøretøy
STR_020C_NEW_VEHICLES :{YELLOW}Nye kjøretøy
STR_020D_CHANGES_OF_CARGO_ACCEPTANCE :{YELLOW}Endringer i godtatte varer
@@ -1681,6 +1684,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}Bygg bro
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}Bygg bro for trikkespor
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}Bygg tunnel
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}Bygg tunnel for trikkespor
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}Aktiver/deaktiver énveiskjørte veier
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}Velg mellom bygging/fjerning for veibygging
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}Velg mellom bygging/fjerning for trikkesporkonstruksjon
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}Velg garasjens retning
@@ -1702,6 +1706,7 @@ STR_TOWN_LABEL :{WHITE}{TOWN}
STR_TOWN_LABEL_TINY_BLACK :{TINYFONT}{BLACK}{TOWN}
STR_TOWN_LABEL_TINY_WHITE :{TINYFONT}{WHITE}{TOWN}
STR_2002 :{TINYFONT}{BLACK}{SIGN}
STR_2002_WHITE :{TINYFONT}{WHITE}{SIGN}
STR_2004_BUILDING_MUST_BE_DEMOLISHED :{WHITE}Bygningen må rives først
STR_2005 :{WHITE}{TOWN}
STR_2006_POPULATION :{BLACK}Innbyggertall: {ORANGE}{COMMA}{BLACK} Antall hus: {ORANGE}{COMMA}
@@ -2305,7 +2310,7 @@ STR_7072_VIEW_HQ :{BLACK}Se hoved
STR_RELOCATE_HQ :{BLACK}Omplasser hovedkvarter
STR_COMPANY_PASSWORD :{BLACK}Passord
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Passordbeskytt ditt firma for å forhindre uautoriserte brukere fra å bli med. Bruk '*' for å tømme passord.
STR_SET_COMPANY_PASSWORD :Velg firmapassord
STR_SET_COMPANY_PASSWORD :{BLACK}Velg firmapassord
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Verdenskrise!{}{}Økonomer frykter det verste. Nedgangstider i møte.
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Verdenskrise over!{}{}Opptur i markedet gir industrien selvsikkerheten tilbake.
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Bytte mellom stor/liten vindustørrelse
@@ -3286,6 +3291,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Høyde a
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Midstill oversiktskartet på den gjeldende posisjonen
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Liten
@@ -3440,3 +3446,6 @@ STR_FACE_TIE :Slips:
STR_FACE_EARRING :Ørering:
STR_FACE_TIE_EARRING_TIP :{BLACK}Endre slips eller ørering
########
############ signal GUI
########

View File

@@ -2305,7 +2305,7 @@ STR_7072_VIEW_HQ :{BLACK}Sjå hov
STR_RELOCATE_HQ :{BLACK}Omplasser hovudkvarter
STR_COMPANY_PASSWORD :{BLACK}Passord
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Passordbeskytt firmaet ditt slik at ikkje alle og einkvar kan verte med. Bruk '*' for å tømme passord.
STR_SET_COMPANY_PASSWORD :Vel firmapassord
STR_SET_COMPANY_PASSWORD :{BLACK}Vel firmapassord
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Verdskrise!{}{}Økonomar fryktar det verste. Nedgangstider i kjømda.
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Verdskrise over!{}{}Opptur i marknaden gjer industrien sjølvkjensla attende.
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Byt mellom stor/liten storleik på vindauga

View File

@@ -2295,7 +2295,7 @@ STR_7072_VIEW_HQ :{BLACK}Iewvay H
STR_RELOCATE_HQ :{BLACK}Elocateray HQay
STR_COMPANY_PASSWORD :{BLACK}Asswordpay
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Asswordpay-otectpray ouryay ompanycay otay eventpray unauthorisedway usersway omfray oiningjay.
STR_SET_COMPANY_PASSWORD :Etsay ompanycay asswordpay
STR_SET_COMPANY_PASSWORD :{BLACK}Etsay ompanycay asswordpay
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Orldway Ecessionray!{}{}Inancialfay expertsway earfay orstway asway economyway umpsslay!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Ecessionray Overway!{}{}Upturnway inway adetray ivesgay onfidencecay otay industriesway asway economyway engthensstray!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Oggletay argelay/allsmay indowway izesay

View File

@@ -2406,7 +2406,7 @@ STR_7072_VIEW_HQ :{BLACK}Zobacz S
STR_RELOCATE_HQ :{BLACK}Przenieś SG
STR_COMPANY_PASSWORD :{BLACK}Hasło
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Ochrona hasłem Twojej firmy zapobiega nieautoryzowanemu przyłączeniu się
STR_SET_COMPANY_PASSWORD :Ustaw hasło firmy
STR_SET_COMPANY_PASSWORD :{BLACK}Ustaw hasło firmy
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Światowa recesja!{}{}Eksperci finansowi obawiają się najgorszego z powodu kryzysu!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Koniec recesji!{}{}Polepszenie się transakcji handlowych daje pewność przedsiębiorstwom dzięki umacniającej się ekonomii!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Przełącz duży/mały rozmiar okna

View File

@@ -2285,7 +2285,7 @@ STR_7072_VIEW_HQ :{BLACK}Ver sede
STR_RELOCATE_HQ :{BLACK}Mover sede
STR_COMPANY_PASSWORD :{BLACK}Palavra passe
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Usar palavra passe na empresa para prevenir utilizadores não autorizados.
STR_SET_COMPANY_PASSWORD :Definir palavra passe da empresa
STR_SET_COMPANY_PASSWORD :{BLACK}Definir palavra passe da empresa
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Retrocesso Mundial!{}{}Especialistas financeiros temem crise económica!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Fim do retrocesso!{}{}Melhoras no comércio inspiram confiança nas indústrias à medida que a economia se fortalece!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Alternar entre janela grande/pequena

View File

@@ -2304,7 +2304,7 @@ STR_7072_VIEW_HQ :{BLACK}Vezi sed
STR_RELOCATE_HQ :{BLACK}Muta sediu
STR_COMPANY_PASSWORD :{BLACK}Parola
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Protejeaza-ti compania cu o parola pentru a preveni accesul neautorizat.
STR_SET_COMPANY_PASSWORD :Alege parola companiei
STR_SET_COMPANY_PASSWORD :{BLACK}Alege parola companiei
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Recesiune mondială!{}{}Experţii financiari se tem de ceea ce e mai rău odată cu prăbuşirea economică!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Recesiunea s-a încheiat!{}{}Creşterea comerţului dă încredere industriei, iar economia se redresează!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Comutator pentru mărimea ferestrei

View File

@@ -596,6 +596,9 @@ STR_0208_ACCIDENTS_DISASTERS :{YELLOW}Ава
STR_0209_COMPANY_INFORMATION :{YELLOW}Информация о Компании
STR_NEWS_OPEN_CLOSE :{YELLOW}Открытие / закрытие промышленности
STR_020A_ECONOMY_CHANGES :{YELLOW}Изменения в экономике
STR_INDUSTRY_CHANGES_SERVED_BY_PLAYER :{YELLOW}Изменения уровня производства предприятий, обслуживаемых игроком
STR_INDUSTRY_CHANGES_SERVED_BY_OTHER :{YELLOW}Изменения уровня производства предприятий, обслуживаемых соперниками
STR_OTHER_INDUSTRY_PRODUCTION_CHANGES :{YELLOW}Изменения уровня производства предприятий, никем не обслуживаемых
STR_020B_ADVICE_INFORMATION_ON_PLAYER :{YELLOW}Сообщения о транспорте игрока
STR_020C_NEW_VEHICLES :{YELLOW}Новый транспорт
STR_020D_CHANGES_OF_CARGO_ACCEPTANCE :{YELLOW}Изменения в списке принимаемых грузов
@@ -1682,6 +1685,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}Пост
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}Построить трамвайный мост
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}Построить туннель (авто)
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}Построить трамвайный туннель
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}Включить/Отключить односторонние дороги
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}Переключение строительства/удаления автомобильной инфраструктуры
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}Переключение строительства/удаления трамвайной инфраструктуры
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}Выбор ориентации гаража
@@ -1703,6 +1707,7 @@ STR_TOWN_LABEL :{WHITE}{TOWN}
STR_TOWN_LABEL_TINY_BLACK :{TINYFONT}{BLACK}{TOWN}
STR_TOWN_LABEL_TINY_WHITE :{TINYFONT}{WHITE}{TOWN}
STR_2002 :{TINYFONT}{BLACK}{SIGN}
STR_2002_WHITE :{TINYFONT}{WHITE}{SIGN}
STR_2004_BUILDING_MUST_BE_DEMOLISHED :{WHITE}Сначала надо уничтожить здания
STR_2005 :{WHITE}{TOWN}
STR_2006_POPULATION :{BLACK}Население: {ORANGE}{COMMA}{BLACK} Зданий: {ORANGE}{COMMA}
@@ -2317,7 +2322,7 @@ STR_7072_VIEW_HQ :{BLACK}Осмо
STR_RELOCATE_HQ :{BLACK}Переместить
STR_COMPANY_PASSWORD :{BLACK}Пароль
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Защитить вашу компанию паролем, чтобы неавторизованные пользователи не могли присоединиться
STR_SET_COMPANY_PASSWORD :Установить пароль компании
STR_SET_COMPANY_PASSWORD :{BLACK}Установить пароль компании
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Мировой спад{}{}Финансовые эксперты дают ужасные прогнозы в связи с кризисом экономики!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Спад закончился!{}{}Увеличение объемов торговли внушает уверенность владельцам предприятий. Экономика укрепляет свои позиции.
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Большое/маленькое окно
@@ -3089,6 +3094,7 @@ STR_NEWGRF_ERROR_LOAD_BEFORE :{STRING} дол
STR_NEWGRF_ERROR_LOAD_AFTER :{STRING} должен быть загружен после {STRING}.
STR_NEWGRF_ERROR_OTTD_VERSION_NUMBER :{STRING} требует OpenTTD версии {STRING} или выше.
STR_NEWGRF_ERROR_AFTER_TRANSLATED_FILE :файл GRF, который им переводится.
STR_NEWGRF_ERROR_TOO_MANY_NEWGRFS_LOADED :Слишком много загружено новой графики
STR_NEWGRF_ADD :{BLACK}Добавить
STR_NEWGRF_ADD_TIP :{BLACK}Добавить файл NewGRF в список
@@ -3297,6 +3303,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Высо
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Центрировать миникарту по этой позиции
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Малый
@@ -3451,3 +3458,6 @@ STR_FACE_TIE :Галстук:
STR_FACE_EARRING :Серьга:
STR_FACE_TIE_EARRING_TIP :{BLACK}Изменить галстук или серьгу
########
############ signal GUI
########

View File

@@ -2177,7 +2177,7 @@ STR_7072_VIEW_HQ :{BLACK}查看
STR_RELOCATE_HQ :{BLACK}重置总部
STR_COMPANY_PASSWORD :{BLACK}密码
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}设置密码可以防止未经授权的用户随意加入。
STR_SET_COMPANY_PASSWORD :设置公司密码
STR_SET_COMPANY_PASSWORD :{BLACK}设置公司密码
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}大萧条!{}{}金融专家预测世界经济将全面倒退!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}大萧条结束!{}{}贸易复苏带动经济全面启动!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}切换窗口大小

View File

@@ -480,9 +480,9 @@ STR_0162_JAN :Jan
STR_0163_FEB :Feb
STR_0164_MAR :Mar
STR_0165_APR :Apr
STR_0166_MAY :Maj
STR_0167_JUN :Jun
STR_0168_JUL :Jul
STR_0166_MAY :Máj
STR_0167_JUN :Jún
STR_0168_JUL :Júl
STR_0169_AUG :Aug
STR_016A_SEP :Sep
STR_016B_OCT :Okt
@@ -658,12 +658,15 @@ STR_0208_ACCIDENTS_DISASTERS :{YELLOW}Havarie
STR_0209_COMPANY_INFORMATION :{YELLOW}Informacie o spolocnosti
STR_NEWS_OPEN_CLOSE :{YELLOW}Vznik a zánik priemyslu
STR_020A_ECONOMY_CHANGES :{YELLOW}Zmeny v ekonomike
STR_INDUSTRY_CHANGES_SERVED_BY_PLAYER :{YELLOW}Zmeny produkcie priemyslu obsluhovaného hrácom
STR_INDUSTRY_CHANGES_SERVED_BY_OTHER :{YELLOW}Zmeny produkcie priemyslu obsluhovaného konkurenciou
STR_OTHER_INDUSTRY_PRODUCTION_CHANGES :{YELLOW}Ostatné zmeny produkcie priemyslu
STR_020B_ADVICE_INFORMATION_ON_PLAYER :{YELLOW}Oznamenia / Informacie o vozidlach hraca
STR_020C_NEW_VEHICLES :{YELLOW}Nove vozidla
STR_020D_CHANGES_OF_CARGO_ACCEPTANCE :{YELLOW}Zmeny prijmu nakladu
STR_020E_SUBSIDIES :{YELLOW}Dotacie
STR_020F_GENERAL_INFORMATION :{YELLOW}Hlavne informacie
STR_MESSAGES_ALL :{YELLOW}Nastavenie vs. typov sprav (vypnute/strucne/zapnute)
STR_MESSAGES_ALL :{YELLOW}Nastavenie všetkých správ (vypnuté/obsah/plné)
STR_MESSAGE_SOUND :{YELLOW}Prehrat zvuk pre strucne novinove spravy
STR_0210_TOO_FAR_FROM_PREVIOUS_DESTINATIO :{WHITE}...prilis daleko z predchadzajuceho ciela
STR_0211_TOP_COMPANIES_WHO_REACHED :{BIGFONT}{BLACK}Najlepsie spolocnosti, ktore dosiahli {NUM}{}({STRING} uroven)
@@ -880,7 +883,7 @@ STR_EXTRA_VIEW_MOVE_MAIN_TO_VIEW_TT :{BLACK}Nastavit
STR_02E0_CURRENCY_UNITS :{BLACK}Mena
STR_02E1 :{BLACK}{SKIP}{STRING}
STR_02E2_CURRENCY_UNITS_SELECTION :{BLACK}Vyber meny
STR_MEASURING_UNITS :{BLACK}Jednotky vzdialenosti
STR_MEASURING_UNITS :{BLACK}Merné jednotky
STR_02E4 :{BLACK}{SKIP}{SKIP}{STRING}
STR_MEASURING_UNITS_SELECTION :{BLACK}Výber jednotiek vzdialenosti
STR_02E6_ROAD_VEHICLES :{BLACK}Cestné vozidlá
@@ -896,7 +899,7 @@ STR_02F4_AUTOSAVE :{BLACK}Automati
STR_02F5 :{BLACK}{SKIP}{SKIP}{SKIP}{SKIP}{SKIP}{STRING}
STR_02F6_SELECT_INTERVAL_BETWEEN :{BLACK}Vyber interval automatickeho ukladania
STR_02F7_OFF :Vypnute
STR_02F8_EVERY_3_MONTHS :Kazde 3 mesiace
STR_02F8_EVERY_3_MONTHS :Každé 3 mesiace
STR_02F9_EVERY_6_MONTHS :Každých 6 mesiacov
STR_02FA_EVERY_12_MONTHS :Každých 12 mesiacov
STR_02FB_START_A_NEW_GAME :{BLACK}Spustit novu hru
@@ -1018,9 +1021,9 @@ STR_MONTH_JAN :Januar
STR_MONTH_FEB :Februar
STR_MONTH_MAR :Marec
STR_MONTH_APR :April
STR_MONTH_MAY :Maj
STR_MONTH_JUN :Jun
STR_MONTH_JUL :Jul
STR_MONTH_MAY :Máj
STR_MONTH_JUN :Jún
STR_MONTH_JUL :Júl
STR_MONTH_AUG :August
STR_MONTH_SEP :September
STR_MONTH_OCT :Oktober
@@ -1038,7 +1041,7 @@ STR_TONS :ton
STR_LITERS :litrov
STR_ITEMS :kusov
STR_CRATES :debien
STR_RES_OTHER :ine
STR_RES_OTHER :iné
STR_NOTHING :
STR_SMALL_RIGHT_ARROW :{TINYFONT}{RIGHTARROW}
@@ -1083,33 +1086,33 @@ STR_CONFIG_PATCHES_CAPTION :{WHITE}Nastaven
STR_CONFIG_PATCHES_OFF :nie
STR_CONFIG_PATCHES_ON :áno
STR_CONFIG_PATCHES_VEHICLESPEED :{LTBLUE}Zobrazit rychlost vozidla v stavovej liste: {ORANGE}{STRING}
STR_CONFIG_PATCHES_BUILDONSLOPES :{LTBLUE}Umoznit vystavbu na svahoch a na pobrezi: {ORANGE}{STRING}
STR_CONFIG_PATCHES_VEHICLESPEED :{LTBLUE}Zobrazovat rýchlost v stavovej lište vozidla: {ORANGE}{STRING}
STR_CONFIG_PATCHES_BUILDONSLOPES :{LTBLUE}Umožnit výstavbu na svahoch a na pobreží: {ORANGE}{STRING}
STR_CONFIG_PATCHES_AUTOSLOPE :{LTBLUE}Povolit úpravy terénu pod budovami, kolajami, ... : {ORANGE}{STRING}
STR_CONFIG_PATCHES_CATCHMENT :{LTBLUE}Povolit realistickejsiu velkost oblasti pokrytia: {ORANGE}{STRING}
STR_CONFIG_PATCHES_EXTRADYNAMITE :{LTBLUE}Umoznit odstranenie viacerych mestskych ciest, mostov, ... : {ORANGE}{STRING}
STR_CONFIG_PATCHES_MAMMOTHTRAINS :{LTBLUE}Umoznit stavbu dlhych vlakov: {ORANGE}{STRING}
STR_CONFIG_PATCHES_CATCHMENT :{LTBLUE}Povolit realistickejšiu velkost oblasti pokrytia: {ORANGE}{STRING}
STR_CONFIG_PATCHES_EXTRADYNAMITE :{LTBLUE}Umožnit odstránenie viacerých mestských ciest, mostov, ... : {ORANGE}{STRING}
STR_CONFIG_PATCHES_MAMMOTHTRAINS :{LTBLUE}Umožnit stavbu dlhých vlakov: {ORANGE}{STRING}
STR_CONFIG_PATCHES_REALISTICACCEL :{LTBLUE}Zapnut realnu akceleraciu vlakov: {ORANGE}{STRING}
STR_CONFIG_PATCHES_FORBID_90_DEG :{LTBLUE}Zakazat vlakom a lodiam otacanie o 90 st.: {ORANGE}{STRING} {LTBLUE} (vyzaduje NPF)
STR_CONFIG_PATCHES_FORBID_90_DEG :{LTBLUE}Zakázat vlakom a lodiam otácanie o 90 st.: {ORANGE}{STRING} {LTBLUE} (vyžaduje NPF)
STR_CONFIG_PATCHES_JOINSTATIONS :{LTBLUE}Umoznit spajanie stanic: {ORANGE}{STRING}
STR_CONFIG_PATCHES_FULLLOADANY :{LTBLUE}Opustit stanicu ked jeden z nakladov je plny, pri 'plne naloz': {ORANGE}{STRING}
STR_CONFIG_PATCHES_IMPROVEDLOAD :{LTBLUE}Pouzit vylepseny algoritmus nakladania: {ORANGE}{STRING}
STR_CONFIG_PATCHES_GRADUAL_LOADING :{LTBLUE}Postupné nakladanie vozidiel: {ORANGE}{STRING}
STR_CONFIG_PATCHES_INFLATION :{LTBLUE}Inflacia: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SELECTGOODS :{LTBLUE}Vykladat tovar len v stanici kde je dopyt: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LONGBRIDGES :{LTBLUE}Umoznit stavbu dlhych mostov: {ORANGE}{STRING}
STR_CONFIG_PATCHES_GOTODEPOT :{LTBLUE}Umoznit zaradenie depa do zoznamu prikazov: {ORANGE}{STRING}
STR_CONFIG_PATCHES_INFLATION :{LTBLUE}Inflácia: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SELECTGOODS :{LTBLUE}Vykladat náklad len v stanici kde je dopyt: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LONGBRIDGES :{LTBLUE}Umožnit stavbu dlhých mostov: {ORANGE}{STRING}
STR_CONFIG_PATCHES_GOTODEPOT :{LTBLUE}Umožnit zaradenie depa do zoznamu príkazov: {ORANGE}{STRING}
STR_CONFIG_PATCHES_RAW_INDUSTRY_CONSTRUCTION_METHOD :{LTBLUE}Sposob výstavby priemyslu produkujúceho suroviny: {ORANGE}{STRING}
STR_CONFIG_PATCHES_RAW_INDUSTRY_CONSTRUCTION_METHOD_NONE :žiadny
STR_CONFIG_PATCHES_RAW_INDUSTRY_CONSTRUCTION_METHOD_NORMAL :normálny
STR_CONFIG_PATCHES_RAW_INDUSTRY_CONSTRUCTION_METHOD_PROSPECTING :vyhladávací
STR_CONFIG_PATCHES_MULTIPINDTOWN :{LTBLUE}Umoznit viac priemyslu rovnakeho typu v jednom meste: {ORANGE}{STRING}
STR_CONFIG_PATCHES_MULTIPINDTOWN :{LTBLUE}Umoznit viac priemyslu rovnakeho typu pri jednom meste: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SAMEINDCLOSE :{LTBLUE}Rovnaky priemysel moze byt stavany blizko seba: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LONGDATE :{LTBLUE}Zobrazit dlhy format datumu v stavovej liste: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SIGNALSIDE :{LTBLUE}Zobrazit zel. signaly na strane, kde jazdia vozidla: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LONGDATE :{LTBLUE}Zobrazovat dátum v stavovej lište v dlhom formáte: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SIGNALSIDE :{LTBLUE}Zobrazovat žel. signály na rovnakej strane ako jazdia vozidlá: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SHOWFINANCES :{LTBLUE}Zobrazit rozpocet na konci roku: {ORANGE}{STRING}
STR_CONFIG_PATCHES_NEW_NONSTOP :{LTBLUE}TTDPatch kompatibilna interpretacia prikazu nonstop: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ROADVEH_QUEUE :{LTBLUE}Radenie cestnych vozidiel (podla mnozstva tovaru): {ORANGE}{STRING}
STR_CONFIG_PATCHES_ROADVEH_QUEUE :{LTBLUE}Radenie cestných vozidiel (podla množstva nákladu): {ORANGE}{STRING}
STR_CONFIG_PATCHES_AUTOSCROLL :{LTBLUE}Posúvat pohlad ked je kurzor myši na okraji okna: {ORANGE}{STRING}
STR_CONFIG_PATCHES_BRIBE :{LTBLUE}Umoznit podplacanie miestnej spravy: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ALLOW_EXCLUSIVE :{LTBLUE}Povolit zakúpenie exkluzívnych dopravných práv: {ORANGE}{STRING}
@@ -1120,26 +1123,26 @@ STR_CONFIG_PATCHES_FREIGHT_TRAINS :{LTBLUE}Váhov
STR_CONFIG_PATCHES_STOP_ON_TOWN_ROAD :{LTBLUE}Povolit prejazdné zastávky na mestských cestách: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ADJACENT_STATIONS :{LTBLUE}Povolit stavbu oddelených staníc: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SMALL_AIRPORTS :{LTBLUE}Vzdy povolit stavbu malych letisk: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SMALL_AIRPORTS :{LTBLUE}Vždy povolit stavbu malých letísk: {ORANGE}{STRING}
STR_CONFIG_PATCHES_WARN_LOST_TRAIN :{LTBLUE}Upozornit na stratu vlaku: {ORANGE}{STRING}
STR_CONFIG_PATCHES_WARN_LOST_TRAIN :{LTBLUE}Upozornit ak vlak nedokáže nájst cestu: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ORDER_REVIEW :{LTBLUE}Obnovenie prikazov vozidla: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ORDER_REVIEW_OFF :nie
STR_CONFIG_PATCHES_ORDER_REVIEW_EXDEPOT :ano, okrem zastavenych vozidiel
STR_CONFIG_PATCHES_ORDER_REVIEW_ON :ano, u vsetkych vozidiel
STR_CONFIG_PATCHES_WARN_INCOME_LESS :{LTBLUE}Upozornit ak je vlak stratovy: {ORANGE}{STRING}
STR_CONFIG_PATCHES_WARN_INCOME_LESS :{LTBLUE}Upozornit ak je vlak stratový: {ORANGE}{STRING}
STR_CONFIG_PATCHES_NEVER_EXPIRE_VEHICLES :{LTBLUE}Nikdy neprestat s vyrobou starych vozidiel: {ORANGE}{STRING}
STR_CONFIG_PATCHES_AUTORENEW_VEHICLE :{LTBLUE}Automaticka obnova dopravnych prostriedkov, ked su stare
STR_CONFIG_PATCHES_AUTORENEW_MONTHS :{LTBLUE}Obnovit vozidlo {ORANGE}{STRING}{LTBLUE} mesiacov pred/po dosiahnuti max. veku
STR_CONFIG_PATCHES_AUTORENEW_MONEY :{LTBLUE}Min. mnozstvo penazi pre aut. obnovovanie vozidiel: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ERRMSG_DURATION :{LTBLUE}Dlzka zobrazenia chybovej spravy: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ERRMSG_DURATION :{LTBLUE}Dlžka zobrazenia chybovej správy: {ORANGE}{STRING}
STR_CONFIG_PATCHES_POPULATION_IN_LABEL :{LTBLUE}Zobrazit pocet obyvatelov mesta v jeho nazve: {ORANGE}{STRING}
STR_CONFIG_PATCHES_INVISIBLE_TREES :{LTBLUE}Neviditelne stromy (pri priesvitnych budovach): {ORANGE}{STRING}
STR_CONFIG_PATCHES_LAND_GENERATOR :{LTBLUE}Generátor uzemia: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LAND_GENERATOR_ORIGINAL :Povodny
STR_CONFIG_PATCHES_LAND_GENERATOR_TERRA_GENESIS :TerraGenesis
STR_CONFIG_PATCHES_OIL_REF_EDGE_DISTANCE :{LTBLUE}Max. vzdialenost ropnych rafinerii od okraja mapy: {ORANGE}{STRING}
STR_CONFIG_PATCHES_OIL_REF_EDGE_DISTANCE :{LTBLUE}Maximálna vzdialenost ropných rafinérií od okraja mapy: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SNOWLINE_HEIGHT :{LTBLUE}Uroven ciary snehu: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ROUGHNESS_OF_TERRAIN :{LTBLUE}Clenitost terenu (len pre TerraGenesis) : {ORANGE}{STRING}
STR_CONFIG_PATCHES_ROUGHNESS_OF_TERRAIN_VERY_SMOOTH :Velmi rovny
@@ -1157,19 +1160,19 @@ STR_CONFIG_PATCHES_SE_FLAT_WORLD_HEIGHT :{LTBLUE}Vyskova
STR_CONFIG_PATCHES_STATION_SPREAD :{LTBLUE}Max. rozsah stanice: {ORANGE}{STRING} {RED}Pozor: Vysoke hodnoty spomaluju hru
STR_CONFIG_PATCHES_SERVICEATHELIPAD :{LTBLUE}Automatické opravy vrtulníkov v heliporte: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LINK_TERRAFORM_TOOLBAR :{LTBLUE}Otvarat panel uprav terenu s panelom stavby trati, ciest, ... : {ORANGE}{STRING}
STR_CONFIG_PATCHES_LINK_TERRAFORM_TOOLBAR :{LTBLUE}Otvárat panel úprav terénu s panelmi výstavby: {ORANGE}{STRING}
STR_CONFIG_PATCHES_REVERSE_SCROLLING :{LTBLUE}Pri posúvaní pohladu myšou posúvat mapu opacným smerom: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SMOOTH_SCROLLING :{LTBLUE}Plynulé posúvanie pohladu: {ORANGE}{STRING}
STR_CONFIG_PATCHES_MEASURE_TOOLTIP :{LTBLUE}Zobrazit údaje o rozmeroch pri výstavbe: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LIVERIES :{LTBLUE}Zobrazit farebne schemy spolocnosti: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LIVERIES_NONE :Ziadne
STR_CONFIG_PATCHES_LIVERIES_OWN :Vlastná spolocnost
STR_CONFIG_PATCHES_LIVERIES_ALL :Vsetky spolocnosti
STR_CONFIG_PATCHES_LIVERIES :{LTBLUE}Zobrazit farebné schémy spolocnosti: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LIVERIES_NONE :žiadne
STR_CONFIG_PATCHES_LIVERIES_OWN :vlastná spolocnost
STR_CONFIG_PATCHES_LIVERIES_ALL :etky spolocnosti
STR_CONFIG_PATCHES_PREFER_TEAMCHAT :{LTBLUE}Preferovaný teamový chat: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLLING :{LTBLUE}Funkcia scrolovacieho kolieska: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SCROLLWHEEL_ZOOM :Zvacšit mapu
STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLL :Posúvat mapu
STR_CONFIG_PATCHES_SCROLLWHEEL_OFF :Vypnuté
STR_CONFIG_PATCHES_SCROLLWHEEL_ZOOM :zvacšit mapu
STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLL :posúvat pohlad
STR_CONFIG_PATCHES_SCROLLWHEEL_OFF :vypnuté
STR_CONFIG_PATCHES_SCROLLWHEEL_MULTIPLIER :{LTBLUE}Rychlost posúvania pohladu: {ORANGE}{STRING}
STR_CONFIG_PATCHES_RIGHT_MOUSE_BTN_EMU :{LTBLUE}Funkcia pravého tlacidla myši: {ORANGE}{STRING}
@@ -1182,20 +1185,20 @@ STR_CONFIG_PATCHES_ADVANCED_VEHICLE_LISTS :{LTBLUE}Použit
STR_CONFIG_PATCHES_ADVANCED_VEHICLE_LISTS_OFF :Vypnutý
STR_CONFIG_PATCHES_ADVANCED_VEHICLE_LISTS_OWN :Vlastná spolocnost
STR_CONFIG_PATCHES_ADVANCED_VEHICLE_LISTS_ALL :Všetky spolocnosti
STR_CONFIG_PATCHES_LOADING_INDICATORS :{LTBLUE}Zobrazovat ukazovatele nakladania a vykladania: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LOADING_INDICATORS_OFF :Vypnuté
STR_CONFIG_PATCHES_LOADING_INDICATORS_OWN :Vlastná spolocnost
STR_CONFIG_PATCHES_LOADING_INDICATORS_ALL :Všetky spolocnosti
STR_CONFIG_PATCHES_TIMETABLE_ALLOW :{LTBLUE}Povolit cestovné poriadky pre vozidlá: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LOADING_INDICATORS :{LTBLUE}Zobrazovat ukazovatele nakladania/vykladania: {ORANGE}{STRING}
STR_CONFIG_PATCHES_LOADING_INDICATORS_OFF :vypnuté
STR_CONFIG_PATCHES_LOADING_INDICATORS_OWN :vlastná spolocnost
STR_CONFIG_PATCHES_LOADING_INDICATORS_ALL :všetky spolocnosti
STR_CONFIG_PATCHES_TIMETABLE_ALLOW :{LTBLUE}Používat cestovné poriadky pre vozidlá: {ORANGE}{STRING}
STR_CONFIG_PATCHES_TIMETABLE_IN_TICKS :{LTBLUE}Zobrazovat cestovné poriadky v tikoch namiesto dní: {ORANGE}{STRING}
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE :{LTBLUE}Predvolený typ kolají (v novej/nahranej hre): {ORANGE}{STRING}
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE_RAIL :Normálne
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE_ELRAIL :Elektrifikované
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE_RAIL :normálne
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE_ELRAIL :elektrifikované
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE_MONORAIL :Monorail
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE_MAGLEV :Maglev
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE_FIRST :Prvé dostupné
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE_LAST :Posledné dostupné
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE_MOST_USED :Najpoužívanejšie
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE_FIRST :prvé dostupné
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE_LAST :posledné dostupné
STR_CONFIG_PATCHES_DEFAULT_RAIL_TYPE_MOST_USED :najpoužívanejšie
STR_CONFIG_PATCHES_ALWAYS_BUILD_INFRASTRUCTURE :{LTBLUE}Zobrazit nástroje výstavby ak nie sú dostupné vhodné vozidlá: {ORANGE}{STRING}
STR_CONFIG_PATCHES_MAX_TRAINS :{LTBLUE}Maximalny pocet vlakov hraca: {ORANGE}{STRING}
@@ -1220,39 +1223,39 @@ STR_CONFIG_PATCHES_SERVINT_AIRCRAFT_DISABLED :{LTBLUE}Implici
STR_CONFIG_PATCHES_SERVINT_SHIPS :{LTBLUE}Implicitny servisny interval pre lode: {ORANGE}{STRING} dni/%
STR_CONFIG_PATCHES_SERVINT_SHIPS_DISABLED :{LTBLUE}Implicitny servisny interval pre lode: {ORANGE}vypnuty
STR_CONFIG_PATCHES_NOSERVICE :{LTBLUE}Vypnut servisy, ak su vypnute poruchy: {ORANGE}{STRING}
STR_CONFIG_PATCHES_WAGONSPEEDLIMITS :{LTBLUE}Obmedzenie rychlosti pre vagony: {ORANGE}{STRING}
STR_CONFIG_PATCHES_WAGONSPEEDLIMITS :{LTBLUE}Obmedzenie rýchlosti pre vagóny: {ORANGE}{STRING}
STR_CONFIG_PATCHES_DISABLE_ELRAILS :{LTBLUE}Zakázat elektrifikovanú železnicu: {ORANGE}{STRING}
STR_CONFIG_PATCHES_COLORED_NEWS_YEAR :{LTBLUE}Farebne spravy sa prvykrat objavia v roku: {ORANGE}{STRING}
STR_CONFIG_PATCHES_COLORED_NEWS_YEAR :{LTBLUE}Zobrazovat správy farebne od roku: {ORANGE}{STRING}
STR_CONFIG_PATCHES_STARTING_YEAR :{LTBLUE}Zaciatok hry v roku: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ENDING_YEAR :{LTBLUE}Koniec hry v roku: {ORANGE}{STRING}
STR_CONFIG_PATCHES_SMOOTH_ECONOMY :{LTBLUE}Mierne zmeny ekonomiky (viac mensich zmien)
STR_CONFIG_PATCHES_ALLOW_SHARES :{LTBLUE}Povolit nakup akcii ostatnych spolocnosti
STR_CONFIG_PATCHES_DRAG_SIGNALS_DENSITY :{LTBLUE}Pri stavbe tahanim umiestnit semafory na kazde: {ORANGE}{STRING}. pole
STR_CONFIG_PATCHES_SEMAPHORE_BUILD_BEFORE_DATE :{LTBLUE}Automatická stavba semafórov pred: {ORANGE}{STRING}
STR_CONFIG_PATCHES_ALLOW_SHARES :{LTBLUE}Povolit kupovanie podielov v ostatných spolocnostiach
STR_CONFIG_PATCHES_DRAG_SIGNALS_DENSITY :{LTBLUE}Pri stavbe tahaním umiestnit signály na každé: {ORANGE}{STRING}. pole
STR_CONFIG_PATCHES_SEMAPHORE_BUILD_BEFORE_DATE :{LTBLUE}Automaticky stavat semafóry namiesto signálov pred rokom: {ORANGE}{STRING}
STR_CONFIG_PATCHES_TOWN_LAYOUT_INVALID :{WHITE}Struktúra mesta "žiadne cesty naviac" nie je platná v editore scenárov
STR_CONFIG_PATCHES_TOWN_LAYOUT :{LTBLUE}Struktúra mestských ciest: {ORANGE}{STRING}
STR_CONFIG_PATCHES_TOWN_LAYOUT_NO_ROADS :žiadne cesty naviac
STR_CONFIG_PATCHES_TOWN_LAYOUT_NO_ROADS :žiadne cesty
STR_CONFIG_PATCHES_TOWN_LAYOUT_DEFAULT :štandardná
STR_CONFIG_PATCHES_TOWN_LAYOUT_BETTER_ROADS :lepšie cesty
STR_CONFIG_PATCHES_TOWN_LAYOUT_2X2_GRID :mriežka 2x2
STR_CONFIG_PATCHES_TOWN_LAYOUT_3X3_GRID :mriežka 3x3
STR_CONFIG_PATCHES_TOWN_LAYOUT_BETTER_ROADS :zdokonalená
STR_CONFIG_PATCHES_TOWN_LAYOUT_2X2_GRID :bloky 2x2
STR_CONFIG_PATCHES_TOWN_LAYOUT_3X3_GRID :bloky 3x3
STR_CONFIG_PATCHES_TOOLBAR_POS :{LTBLUE}Pozicia hlavneho menu: {ORANGE}{STRING}
STR_CONFIG_PATCHES_TOOLBAR_POS_LEFT :Nalavo
STR_CONFIG_PATCHES_TOOLBAR_POS_CENTER :V strede
STR_CONFIG_PATCHES_TOOLBAR_POS_RIGHT :Napravo
STR_CONFIG_PATCHES_TOOLBAR_POS :{LTBLUE}Pozícia hlavného menu: {ORANGE}{STRING}
STR_CONFIG_PATCHES_TOOLBAR_POS_LEFT :vlavo
STR_CONFIG_PATCHES_TOOLBAR_POS_CENTER :v strede
STR_CONFIG_PATCHES_TOOLBAR_POS_RIGHT :vpravo
STR_CONFIG_PATCHES_SNAP_RADIUS :{LTBLUE}Vzdialenost pre prichytenie okna: {ORANGE}{STRING} bodov
STR_CONFIG_PATCHES_SNAP_RADIUS_DISABLED :{LTBLUE}Vzdialenost pre prichytenie okna: {ORANGE}vypnute
STR_CONFIG_PATCHES_SNAP_RADIUS_DISABLED :{LTBLUE}Vzdialenost pre prichytenie okna: {ORANGE}vypnuté
STR_CONFIG_PATCHES_TOWN_GROWTH :{LTBLUE}Rozvoj miest: {ORANGE}{STRING}
STR_CONFIG_PATCHES_TOWN_GROWTH_NONE :Žiadny
STR_CONFIG_PATCHES_TOWN_GROWTH_SLOW :Pomalý
STR_CONFIG_PATCHES_TOWN_GROWTH_NORMAL :Normálny
STR_CONFIG_PATCHES_TOWN_GROWTH_FAST :Rýchly
STR_CONFIG_PATCHES_TOWN_GROWTH_VERY_FAST :Velmi rýchly
STR_CONFIG_PATCHES_TOWN_GROWTH_NONE :žiadny
STR_CONFIG_PATCHES_TOWN_GROWTH_SLOW :pomalý
STR_CONFIG_PATCHES_TOWN_GROWTH_NORMAL :normálny
STR_CONFIG_PATCHES_TOWN_GROWTH_FAST :rýchly
STR_CONFIG_PATCHES_TOWN_GROWTH_VERY_FAST :velmi rýchly
STR_CONFIG_PATCHES_LARGER_TOWNS :{LTBLUE}Pomer miest, ktoré sa budú rozvíjat rýchlejšie: {ORANGE}1 z {STRING}
STR_CONFIG_PATCHES_LARGER_TOWNS_DISABLED :{LTBLUE}Pomer miest, ktoré sa budú rozvíjat rýchlejšie: {ORANGE}Žiadny
STR_CONFIG_PATCHES_LARGER_TOWNS_DISABLED :{LTBLUE}Pomer miest, ktoré sa budú rozvíjat rýchlejšie: {ORANGE}žiadne
STR_CONFIG_PATCHES_CITY_SIZE_MULTIPLIER :{LTBLUE}Násobok pociatocnej velkosti mesta: {ORANGE}{STRING}
STR_CONFIG_MODIFIED_ROAD_REBUILD :{LTBLUE}Odstránit nezmyselné casti pri rekonštrukcii ciest
@@ -1744,6 +1747,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}Postavit
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}Postavit most s elektrickovou dráhou
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}Postavit cestny tunel
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}Postavit tunel s elektrickovou dráhou
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}Prepnút stavbu jednosmerných ciest
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}Prepnut stavbu/odstranovanie cesty
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}Prepnút stavbu/odstranovanie elektrickovej dráhy
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}Vybrat orientaciu garaze
@@ -1765,6 +1769,7 @@ STR_TOWN_LABEL :{WHITE}{TOWN}
STR_TOWN_LABEL_TINY_BLACK :{TINYFONT}{BLACK}{TOWN}
STR_TOWN_LABEL_TINY_WHITE :{TINYFONT}{WHITE}{TOWN}
STR_2002 :{TINYFONT}{BLACK}{SIGN}
STR_2002_WHITE :{TINYFONT}{WHITE}{SIGN}
STR_2004_BUILDING_MUST_BE_DEMOLISHED :{WHITE}Budova sa musi zburat
STR_2005 :{WHITE}{TOWN}
STR_2006_POPULATION :{BLACK}Obyvatelstvo: {ORANGE}{COMMA}{BLACK} Domov: {ORANGE}{COMMA}
@@ -2067,7 +2072,7 @@ STR_482F_COST :{BLACK}Cena: {Y
STR_4830_CAN_T_CONSTRUCT_THIS_INDUSTRY :{WHITE}Tento typ priemyslu sa tu neda postavit ...
STR_4831_FOREST_CAN_ONLY_BE_PLANTED :{WHITE}... les sa moze sadit len pod ciarou snehu
STR_4832_ANNOUNCES_IMMINENT_CLOSURE :{BLACK}{BIGFONT}{STRING} oznamuje skore uzavretie!
STR_4833_SUPPLY_PROBLEMS_CAUSE_TO :{BLACK}{BIGFONT}Zasobovacie problemy donutili {STRING} oznamit skore uzavretie!
STR_4833_SUPPLY_PROBLEMS_CAUSE_TO :{BLACK}{BIGFONT}Kvôli zásobovacím problémom {STRING} oznamuje skoré uzavretie!
STR_4834_LACK_OF_NEARBY_TREES_CAUSES :{BLACK}{BIGFONT}Nedostatok dostupnej drevnej suroviny donutil {STRING} oznamit skore uzavretie!
STR_4835_INCREASES_PRODUCTION :{BLACK}{BIGFONT}{INDUSTRY} zvyšuje produkciu!
STR_4836_NEW_COAL_SEAM_FOUND_AT :{BLACK}{BIGFONT}Nove nalezisko uhlia sa objavilo v {INDUSTRY}!{}Ocakava sa zdvojnasobenie produkcie!
@@ -2122,7 +2127,7 @@ STR_5028_TUBULAR_ROAD_BRIDGE :Kryty cestny mo
##id 0x5800
STR_5800_OBJECT_IN_THE_WAY :{WHITE}V ceste je prekazka
STR_5801_TRANSMITTER :Vysielac
STR_5802_LIGHTHOUSE :Majak
STR_5802_LIGHTHOUSE :Maják
STR_5803_COMPANY_HEADQUARTERS :Sidlo firmy
STR_5804_COMPANY_HEADQUARTERS_IN :{WHITE}... sidlo firmy v ceste
STR_5805_COMPANY_OWNED_LAND :Spolocnostou vlastneny pozemok
@@ -2189,20 +2194,20 @@ STR_6804_CUSTOM :{BLACK}Vlastná
############ range for difficulty levels ends
############ range for difficulty settings starts
STR_6805_MAXIMUM_NO_COMPETITORS :{LTBLUE}Max. pocet konkurentov: {ORANGE}{COMMA}
STR_6805_MAXIMUM_NO_COMPETITORS :{LTBLUE}Maximálny pocet konkurentov: {ORANGE}{COMMA}
STR_6806_COMPETITOR_START_TIME :{LTBLUE}Vznik konkurencie: {ORANGE}{STRING}
STR_6807_NO_OF_TOWNS :{LTBLUE}Pocet miest: {ORANGE}{STRING}
STR_6808_NO_OF_INDUSTRIES :{LTBLUE}Pocet priemyslu: {ORANGE}{STRING}
STR_6809_MAXIMUM_INITIAL_LOAN_000 :{LTBLUE}Maximálny prvotný úver: {ORANGE}{CURRENCY}
STR_680A_INITIAL_INTEREST_RATE :{LTBLUE}Pociatocny urok: {ORANGE}{COMMA}%
STR_680B_VEHICLE_RUNNING_COSTS :{LTBLUE}Náklady na prevádzku vozidiel: {ORANGE}{STRING}
STR_680B_VEHICLE_RUNNING_COSTS :{LTBLUE}Nákladnost prevádzky vozidiel: {ORANGE}{STRING}
STR_680C_CONSTRUCTION_SPEED_OF_COMPETITOR :{LTBLUE}Rychlost konkurencie: {ORANGE}{STRING}
STR_680D_INTELLIGENCE_OF_COMPETITORS :{LTBLUE}Inteligencia konkurencie: {ORANGE}{STRING}
STR_680E_VEHICLE_BREAKDOWNS :{LTBLUE}Poruchy vozidiel: {ORANGE}{STRING}
STR_680F_SUBSIDY_MULTIPLIER :{LTBLUE}Nasobok dotacii: {ORANGE}{STRING}
STR_6810_COST_OF_CONSTRUCTION :{LTBLUE}Náklady na výstavbu: {ORANGE}{STRING}
STR_6810_COST_OF_CONSTRUCTION :{LTBLUE}Nákladnost výstavby: {ORANGE}{STRING}
STR_6811_TERRAIN_TYPE :{LTBLUE}Typ terénu: {ORANGE}{STRING}
STR_6812_QUANTITY_OF_SEA_LAKES :{LTBLUE}Rozsah oceanov/jazier: {ORANGE}{STRING}
STR_6812_QUANTITY_OF_SEA_LAKES :{LTBLUE}Rozloha vodnej plochy: {ORANGE}{STRING}
STR_6813_ECONOMY :{LTBLUE}Ekonomika: {ORANGE}{STRING}
STR_6814_TRAIN_REVERSING :{LTBLUE}Otacanie vlakov: {ORANGE}{STRING}
STR_6815_DISASTERS :{LTBLUE}Havarie: {ORANGE}{STRING}
@@ -2221,13 +2226,13 @@ STR_681C_SLOW :Pomale
STR_681D_MEDIUM :Stredne
STR_681E_FAST :Rychle
STR_681F_VERY_FAST :Velmi rychle
STR_VERY_LOW :Velmi nizke
STR_6820_LOW :Nízky
STR_6821_MEDIUM :Stredne
STR_6822_HIGH :Vysoký
STR_VERY_LOW :Velmi nízka
STR_6820_LOW :Nízka
STR_6821_MEDIUM :Stredná
STR_6822_HIGH :Vysoká
STR_6823_NONE :Ziadne
STR_6824_REDUCED :Znizene
STR_6825_NORMAL :Normálny
STR_6824_REDUCED :Obmedzené
STR_6825_NORMAL :Normálne
STR_6826_X1_5 :x1.5
STR_6827_X2 :x2
STR_6828_X3 :x3
@@ -2368,7 +2373,7 @@ STR_7072_VIEW_HQ :{BLACK}Pozriet
STR_RELOCATE_HQ :{BLACK}Premiestnit sidlo
STR_COMPANY_PASSWORD :{BLACK}Heslo
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Heslo-ochrana vasej spolocnosti proti neautorizovanemu pripojeniu hracov
STR_SET_COMPANY_PASSWORD :Nastavte heslo spolocnosti
STR_SET_COMPANY_PASSWORD :{BLACK}Nastavte heslo spolocnosti
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Svetova kriza!{}{}Financni experti maju obavy z prepadu ekonomiky!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Koniec krizy!{}{}Ocakava sa vzostup predaja a posilnenie ekonomiky!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Prepnut velkost okna
@@ -2752,7 +2757,7 @@ STR_8828_UNLOAD :{BLACK}Vylozit
STR_REFIT :{BLACK}Prestavba
STR_REFIT_TIP :{BLACK}Vyberte typ nákladu na prestavbu v tomto poradí. CTRL+klik na odstránenie príkazu prestavby
STR_REFIT_ORDER :(Prestavba na {STRING})
STR_TIMETABLE_VIEW :{BLACK}Cestovný poriadok
STR_TIMETABLE_VIEW :{BLACK}CP
STR_TIMETABLE_VIEW_TOOLTIP :{BLACK}Prepnút na zobrazenie cestovného poriadku
STR_8829_ORDERS :{WHITE}{VEHICLE} (Prikazy)
STR_882A_END_OF_ORDERS :{SETX 10}- - Koniec prikazov - -
@@ -2858,8 +2863,8 @@ STR_TIMETABLE_STATUS_ON_TIME :Toto vozidlo id
STR_TIMETABLE_STATUS_LATE :Toto vozidlo mešká {STRING}
STR_TIMETABLE_STATUS_EARLY :Toto vozidlo ide {STRING} skor
STR_TIMETABLE_TOTAL_TIME :Na dokoncenie cestovného poriadku je potrebných {STRING}
STR_TIMETABLE_TOTAL_TIME_INCOMPLETE :Na dokoncenie cestovného poriadku je potrebných najmenej {STRING} (nie všetko je urcené)
STR_TIMETABLE_AUTOFILL :{BLACK}Autovyplnenie
STR_TIMETABLE_TOTAL_TIME_INCOMPLETE :Na dokoncenie cestovného poriadku je potrebných min. {STRING} (nie všetko je urcené)
STR_TIMETABLE_AUTOFILL :{BLACK}Vyplnit
STR_TIMETABLE_AUTOFILL_TOOLTIP :{BLACK}Vyplnit cestovný poriadok automaticky hodnotami z prvej cesty
##id 0x9000
@@ -3295,17 +3300,17 @@ STR_PURCHASE_INFO_MAX_TE :{BLACK}Max. tra
########### String for New Landscape Generator
STR_GENERATE :{WHITE}Generovat
STR_GENERATE :{WHITE}Vytvorit
STR_RANDOM :{BLACK}Nový kód
STR_RANDOM_HELP :{BLACK}Zmenit nahodny kod pre generovanie terenu
STR_WORLD_GENERATION_CAPTION :{WHITE}Generovanie krajiny
STR_WORLD_GENERATION_CAPTION :{WHITE}Vytvorenie krajiny
STR_RANDOM_SEED :{BLACK}Náhodný kód:
STR_RANDOM_SEED_HELP :{BLACK}Kliknite pre zadanie nahodneho kodu
STR_LAND_GENERATOR :{BLACK}Generátor krajiny:
STR_TREE_PLACER :{BLACK}Generátor stromov:
STR_HEIGHTMAP_ROTATION :{BLACK}Orientacia vyskovej mapy:
STR_TERRAIN_TYPE :{BLACK}Typ terénu:
STR_QUANTITY_OF_SEA_LAKES :{BLACK}Mnozstvo jazier:
STR_QUANTITY_OF_SEA_LAKES :{BLACK}Rozloha mora:
STR_SMOOTHNESS :{BLACK}Clenitost:
STR_SNOW_LINE_HEIGHT :{BLACK}Vyska linie snehu:
STR_DATE :{BLACK}Rok:
@@ -3329,7 +3334,7 @@ STR_GENERATION_ABORT_CAPTION :{WHITE}Ukoncit
STR_GENERATION_ABORT_MESSAGE :{YELLOW}Skutocne chcete ukoncit generovanie?
STR_PROGRESS :{WHITE}{NUM}% hotovych
STR_GENERATION_PROGRESS :{BLACK}{NUM} / {NUM}
STR_WORLD_GENERATION :{BLACK}Generovanie krajiny
STR_WORLD_GENERATION :{BLACK}Vytvorenie krajiny
STR_TREE_GENERATION :{BLACK}Generovanie stromov
STR_UNMOVABLE_GENERATION :{BLACK}Nepohyblive generovanie
STR_CLEARING_TILES :{BLACK}Generovanie nerovnosti a skal
@@ -3349,6 +3354,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Vyska ro
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Vycentrovat malu mapu na aktualnu poziciu
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Male

View File

@@ -636,6 +636,9 @@ STR_0208_ACCIDENTS_DISASTERS :{YELLOW}Nesreč
STR_0209_COMPANY_INFORMATION :{YELLOW}Informacije o podjetju
STR_NEWS_OPEN_CLOSE :{YELLOW}Odpiranje / zapiranje industrij
STR_020A_ECONOMY_CHANGES :{YELLOW}Ekonomske spremembe
STR_INDUSTRY_CHANGES_SERVED_BY_PLAYER :{YELLOW}Proizvodne spremembe industrij v igralčevi oskrbi
STR_INDUSTRY_CHANGES_SERVED_BY_OTHER :{YELLOW}Proizvodne spremembe industrij v oskrbi tekmecev
STR_OTHER_INDUSTRY_PRODUCTION_CHANGES :{YELLOW}Spremembe proizvodnje drugih industrij
STR_020B_ADVICE_INFORMATION_ON_PLAYER :{YELLOW}Nasveti / informacije o igralčevem vozilu
STR_020C_NEW_VEHICLES :{YELLOW}Nova vozila
STR_020D_CHANGES_OF_CARGO_ACCEPTANCE :{YELLOW}Spremebe v sprejemanju tovora
@@ -1722,6 +1725,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}Zgradi c
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}Zgradi most za tramvaj
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}Zgradi cestni predor
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}Zgradi predor za tramvaj
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}Omogoči/onemogoči enosmerne ceste
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}Preklopi gradnja/rušenje cestnih konstrukcij
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}Preklop gradi/odstrani za tramvaj progo
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}Izberi smer garaže
@@ -1743,6 +1747,7 @@ STR_TOWN_LABEL :{WHITE}{TOWN}
STR_TOWN_LABEL_TINY_BLACK :{TINYFONT}{BLACK}{TOWN}
STR_TOWN_LABEL_TINY_WHITE :{TINYFONT}{WHITE}{TOWN}
STR_2002 :{TINYFONT}{BLACK}{SIGN}
STR_2002_WHITE :{TINYFONT}{WHITE}{SIGN}
STR_2004_BUILDING_MUST_BE_DEMOLISHED :{WHITE}Najprej mora biti stavba porušena
STR_2005 :{WHITE}{TOWN}
STR_2006_POPULATION :{BLACK}Prebivalstvo: {ORANGE}{COMMA}{BLACK} Število stavb: {ORANGE}{COMMA}
@@ -2384,7 +2389,7 @@ STR_7072_VIEW_HQ :{BLACK}Poglej s
STR_RELOCATE_HQ :{BLACK}Preseli sedež
STR_COMPANY_PASSWORD :{BLACK}Geslo
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Zaščiti svoje podjetje z geslom, da preprečiš priključitev drugih uporabnikov k podjetju.
STR_SET_COMPANY_PASSWORD :Nastavi geslo podjetja
STR_SET_COMPANY_PASSWORD :{BLACK}Nastavi geslo podjetja
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}Svetovna recesija!{}{}Ekonomisti se bojijo najhujšega ob trenutnem poteku dogodkov!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}Konec recesije!{}{}Izboljšanje trgovanja povečuje zaupanje domače industrije, gospodarstvo napreduje!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Preklopi veliko/majhno velikost okna
@@ -3365,6 +3370,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Višina
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Centrira majhen zemljevid na trenutno točko
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Majno letališče
@@ -3519,3 +3525,6 @@ STR_FACE_TIE :Kravata:
STR_FACE_EARRING :Uhani:
STR_FACE_TIE_EARRING_TIP :{BLACK}Spremeni kravato ali uhane
########
############ signal GUI
########

View File

@@ -595,6 +595,9 @@ STR_0208_ACCIDENTS_DISASTERS :{YELLOW}Acciden
STR_0209_COMPANY_INFORMATION :{YELLOW}Información de la empresa
STR_NEWS_OPEN_CLOSE :{YELLOW}Aperturas/ cierres de industrias
STR_020A_ECONOMY_CHANGES :{YELLOW}Cambios en la economía
STR_INDUSTRY_CHANGES_SERVED_BY_PLAYER :{YELLOW}Cambios de producción en las industrias servidas por el jugador
STR_INDUSTRY_CHANGES_SERVED_BY_OTHER :{YELLOW}Cambios de producción en las industrias servidas por los competidores
STR_OTHER_INDUSTRY_PRODUCTION_CHANGES :{YELLOW}Cambios de producción de otras industrias
STR_020B_ADVICE_INFORMATION_ON_PLAYER :{YELLOW}Sugerencias/info. sobre vehículos del jugador
STR_020C_NEW_VEHICLES :{YELLOW}Nuevos vehículos
STR_020D_CHANGES_OF_CARGO_ACCEPTANCE :{YELLOW}Cambios en la aceptación de carga
@@ -1681,6 +1684,7 @@ STR_180F_BUILD_ROAD_BRIDGE :{BLACK}Construi
STR_180F_BUILD_TRAMWAY_BRIDGE :{BLACK}Construir puente de tranvía
STR_1810_BUILD_ROAD_TUNNEL :{BLACK}Construir túnel de carretera
STR_1810_BUILD_TRAMWAY_TUNNEL :{BLACK}Construir tunel de tranvía
STR_TOGGLE_ONE_WAY_ROAD :{BLACK}Activar/Desactivar carreteras de un sentido
STR_1811_TOGGLE_BUILD_REMOVE_FOR :{BLACK}Cambiar entre construir/retirar carretera
STR_1811_TOGGLE_BUILD_REMOVE_FOR_TRAMWAYS :{BLACK}Activar construir/quitar para construcciones de tranvía
STR_1813_SELECT_ROAD_VEHICLE_DEPOT :{BLACK}Elegir orientación del depósito de carretera
@@ -1702,6 +1706,7 @@ STR_TOWN_LABEL :{WHITE}{TOWN}
STR_TOWN_LABEL_TINY_BLACK :{TINYFONT}{BLACK}{TOWN}
STR_TOWN_LABEL_TINY_WHITE :{TINYFONT}{WHITE}{TOWN}
STR_2002 :{TINYFONT}{BLACK}{SIGN}
STR_2002_WHITE :{TINYFONT}{WHITE}{SIGN}
STR_2004_BUILDING_MUST_BE_DEMOLISHED :{WHITE}El edificio debe demolerse primero
STR_2005 :{WHITE}{TOWN}
STR_2006_POPULATION :{BLACK}Habitantes: {ORANGE}{COMMA}{BLACK} Casas: {ORANGE}{COMMA}
@@ -2305,7 +2310,7 @@ STR_7072_VIEW_HQ :{BLACK}Ver Sede
STR_RELOCATE_HQ :{BLACK}Reubicar Sede
STR_COMPANY_PASSWORD :{BLACK}Contraseña
STR_COMPANY_PASSWORD_TOOLTIP :{BLACK}Protege por contraseña tu empresa para prevenir que usuarios no autorizados se unan a ella.
STR_SET_COMPANY_PASSWORD :Configurar contraseña de empresa
STR_SET_COMPANY_PASSWORD :{BLACK}Configurar contraseña de empresa
STR_7073_WORLD_RECESSION_FINANCIAL :{BIGFONT}{BLACK}¡Recesión Mundial!{}{}¡Los expertos financieros son pesimistas mientras la economía se hunde!
STR_7074_RECESSION_OVER_UPTURN_IN :{BIGFONT}{BLACK}¡Fin de la Recesión!{}{}¡Mejora en el comercio da ánimos a las industrias mientras la economía se fortalece!
STR_7075_TOGGLE_LARGE_SMALL_WINDOW :{BLACK}Cambiar entre tamaño de ventana grande/pequeño
@@ -3286,6 +3291,7 @@ STR_FLAT_WORLD_HEIGHT :{BLACK}Altura t
STR_FLAT_WORLD_HEIGHT_NUM :{NUM}
STR_SMALLMAP_CENTER :{BLACK}Centrar el mapa pequeño a la posición actual
STR_SMALLMAP_INDUSTRY :{TINYFONT}{STRING} ({NUM})
########### String for new airports
STR_SMALL_AIRPORT :{BLACK}Pequeño
@@ -3440,3 +3446,6 @@ STR_FACE_TIE :Corbata:
STR_FACE_EARRING :Pendientes:
STR_FACE_TIE_EARRING_TIP :{BLACK}Cambiar corbata o pendientes
########
############ signal GUI
########

Some files were not shown because too many files have changed in this diff Show More