Tyler Trahan
37d318c410
Fix #9870 : Don't update infrastructure totals when overbuilding object on canal
2022-05-14 16:54:36 +02:00
Tyler Trahan
89dba56782
Fix e740c24: Use correct command flag, not just DC_EXEC
2022-02-23 01:36:24 +01:00
J0anJosep
d9a37c915f
Cleanup #9725 : Replace cmd_helper related functions and remove cmd_helper.h.
2022-02-02 21:30:15 +01:00
Michael Lutz
c6d7b98808
Codechange: Un-bitstuff landscape commands.
2021-12-16 22:28:32 +01:00
Michael Lutz
46bd2f1ced
Codechange: Un-bitstuff remaining transport infrastructure commands.
2021-12-16 22:28:32 +01:00
Michael Lutz
6fe445e6c0
Codechange: Un-bitstuff station/depot/waypoint commands.
2021-12-16 22:28:32 +01:00
Michael Lutz
e740c24eb7
Codechange: Template DoCommand to automagically reflect the parameters of the command proc.
...
When finished, this will allow each command handler to take individually
different parameters, obliviating the need for bit-packing.
2021-12-16 22:28:32 +01:00
Michael Lutz
b0990fcff7
Codechange: Make TileIndex a "strong" typedef to give it a distinct type.
...
This is accomplished by changing it to a single member struct with the
appropriate operator overloads to make it all work with not too much
source modifications.
2021-12-16 22:28:32 +01:00
Michael Lutz
7048e1522f
Codechange: Move flags in CommandProc in front of the command arguments.
2021-12-16 22:28:32 +01:00
Michael Lutz
33ca4f2b99
Codechange: Let the compile generate the master command table out of templated command traits.
...
This is using a non-intrusive type-traits like templated system, which
allows compile-time validation that the command table and the command
enum match up.
2021-12-16 22:28:32 +01:00
Michael Lutz
b6933a2ebd
Codechange: Move command arguments to the back of the DoCommand function call.
2021-12-16 22:28:32 +01:00
SamuXarick
45edd9f326
Fix: Incorrect error messages on placing water on scenario editor ( #9560 )
...
Additionally changes the behaviour of placing sea on sea/river/canal and placing canal/river on canal to (over)build, instead of disallowing it
2021-09-19 23:14:07 +02:00
SamuXarick
b335b0501c
Fix: wrong error message when building canals over ship depots / locks
...
IsTileType() also considers ship depots and locks water. IsWaterTile() does the right thing.
2021-09-18 13:24:49 +02:00
SamuXarick
6ce74b2a1b
Fix: reduce cost of building canals over objects on sea
...
It is not like we will drain the sea first, to put water back in it after.
Besides, the cost for draining the sea isn't calculated for all other cases either.
2021-09-18 13:24:49 +02:00
glx22
89ab8b79a5
Codechange: Remove FOR_EACH_SET_BIT
2021-07-09 21:36:09 +02:00
rubidium42
2e136285e1
Codechange: move from C-string to std::string for DoCommand
2021-05-29 19:02:18 +02:00
rubidium42
b791ffc6de
Fix: do not hide parameter by local variable with the same name
2021-05-27 18:30:56 +02:00
glx22
38c97e1492
Codechange: Replace TILE_AREA_LOOP with range-based for loops
2021-05-13 00:13:54 +02:00
Tyler Trahan
adb9fa3b36
Feature: Press ctrl to build diagonal rivers in Scenario Editor ( #8880 )
2021-04-02 10:13:27 +02:00
Patric Stout
dff7ee8e1c
Fix #7611 : keeps news about accidents around after vehicle is cleaned up ( #8497 )
...
When a vehicle is cleaned up, all news that points to the news is
also removed. This was a bit evil, as it would also remove any
news related to crashed, acting like the crash never happened.
This left players a bit in the dark what was going on exactly.
2021-01-05 21:39:23 +01:00
SamuXarick
57553cd809
Fix #8020 : Add missing docking tiles around industry neutral stations
2020-03-30 08:21:40 +02:00
Samu
30fe0015e2
Fix #7944 : Demolishing locks built on rivers didn't always restore the river
2020-02-09 20:56:30 +01:00
S. D. Cloudt
13cc8a0cee
Cleanup: Removed SVN headers
2019-11-10 17:59:20 +00:00
peter1138
ec2656ab7e
Codechange: Restrict docking points of docks.
2019-06-30 16:46:32 +02:00
peter1138
f538179878
Feature: Multi-tile docks and docking points.
2019-06-30 16:46:32 +02:00
Charles Pigott
5b34c8019f
Codechange: Remove Company/OwnerByte types
2019-04-29 17:40:22 +01:00
Henry Wilson
7c8e7c6b6e
Codechange: Use null pointer literal instead of the NULL macro
2019-04-10 23:22:20 +02:00
SamuXarick
4adb91202d
Fix: Remove desert around lakes upon generation
2019-02-23 13:16:12 +01:00
Charles Pigott
52ed3bcbaa
Remove: A few bits of dead code
2018-10-31 12:41:49 +01:00
J0anJosep
79a551a83c
Codechange: Use TileAddBy(Diag)Dir when possible.
2018-04-30 18:55:04 +02:00
Michael Lutz
f240274b7e
Codechange: Replace magic numbers with the proper enum.
2018-04-15 00:33:57 +02:00
peter1138
50fb460203
(svn r27973) -Fix: [FS#6662] Avoid tile operations outside map border when building lock.
2018-03-05 22:57:49 +00:00
frosch
b4b98e5165
(svn r27893) -Codechange: Use fallthrough attribute. (LordAro)
2017-08-13 18:38:42 +00:00
frosch
7e12a1a985
(svn r27254) -Fix [FS#6264]: When building a lock on DC_AUTO-removable water-based objects, the water class was always set to canal.
2015-04-26 10:50:36 +00:00
rubidium
9daf7e749c
(svn r26879) -Codechange: remove most MayHaveBridgeAbove calls since the data is now always accessible
2014-09-21 11:24:51 +00:00
rubidium
0463dbdc9e
(svn r26482) -Codechange: add an include that allows us to undefine/redefine "unsafe" functions to prevent them from being used, and thus having to care about certain aspects of their return values
2014-04-23 20:13:33 +00:00
planetmaker
40f61eaf15
(svn r26344) -Change [FS#5907]: Do not flood shores of type MP_TREE needlessly (MJP)
2014-02-16 17:03:58 +00:00
zuu
dfb5663313
(svn r25849) -Codechange: Introduce IsTileFlat to not compute full slope information for situations when we only want to know if a tile is flat or not (cirdan, LordAro)
2013-10-12 22:07:58 +00:00
planetmaker
a8ba748434
(svn r25229) -Feature: [NewGRF] Variable 0x82 for canals and rivers (dike map)
2013-05-06 20:48:18 +00:00
frosch
02924a1d3e
(svn r25220) -Change [FS#Eddi]: Consider map border as water wrt. river/canal continuation.
2013-05-06 12:49:04 +00:00
rubidium
00530f4ccf
(svn r24972) -Fix [FS#5258]: do not make overbuilding rivers with canals insanely expensive; there is no real need to fill the river with dirt first, just excavate it a bit and build borders
2013-02-05 21:07:24 +00:00
planetmaker
9823fac63b
(svn r24924) -Fix (r24923): Make sure that autoslope on steep coast tiles cannot not leave invalid canals
2013-01-20 13:50:10 +00:00
planetmaker
42883b9543
(svn r24923) -Fix [FS#5441]: When an object built on a river is removed, restore the river, if possible also on slopes (based on patch by Supercheese)
2013-01-20 12:43:25 +00:00
frosch
3ce8d2ce70
(svn r24846) -Add: Advanced settings to disable certain sound effects.
2012-12-23 21:09:09 +00:00
frosch
a8c88f43b6
(svn r24284) -Codechange: Remove NewsSubtypes and directly use NewsTypes and NewsFlag instead.
2012-05-26 14:16:03 +00:00
frosch
07f69d8b88
(svn r23920) -Fix: Consider only the middle tile of a lock for lock-infrastructure costs. The other two tiles may be owned by other companies. Also do not count the middle tile of a lock as canal, independent of whether it is build on ground or river slope.
2012-02-09 22:38:39 +00:00
rubidium
e40eb8177a
(svn r23735) -Codechange: remove ~50 includes from headers that weren't needed
2012-01-03 20:26:05 +00:00
yexo
f5caf142c0
(svn r23725) -Fix (r23723): compile before commit
2012-01-03 00:47:56 +00:00
yexo
5f79b4c5d1
(svn r23724) -Codechange: split of the check to see if ambient sounds are enabled to a header file allowing compilers to inline that check
2012-01-03 00:45:22 +00:00
yexo
b9e19cc6c1
(svn r23723) -Codechange: speedup flood checks a bit
2012-01-03 00:44:23 +00:00