Darkvater
65e051fe93
(svn r7094) -Codechange: Get rid of the window-specific code in DoZoomInOutWindow (enable, disable
...
buttons depending on calling window, game-mode); handle it by broadcasting messages
to the calling window, because that knows how and what buttons to set.
18 years ago
tron
a763e7e52e
(svn r7068) if () cascades -> switch ()
18 years ago
tron
f9fa8437eb
(svn r7067) Remove the unused parameter params_3 from AddStringToDraw()
18 years ago
tron
24cce7bfa1
(svn r7066) -Codechange: Factorise common code
18 years ago
Darkvater
a9fa6fd506
(svn r7047) -Fix [FS#317]: Zooming out near map-borders would previously fail because the new centre
...
would be outside the map. Change behaviour so that a reasonable approximation is
returned so that zooming (out) still works (GrimRC)
18 years ago
Darkvater
ee27bb497c
(svn r6884) -Codechange: Add strict bounds checking in string formatting system.
...
The last parameter should point to the end of the buffer (eg lastof(buf))
Courtesy of Tron.
18 years ago
glx
f730a2864f
(svn r6822) -Fix r6821: add type for measure_strings_length[]
18 years ago
Darkvater
2d48fd2861
(svn r6821) -Codechange: For the measurement tool do not show the tooltip when the selection
...
is only a single tile. Seems this was a bit annoying to some ;)
18 years ago
Darkvater
22774d093c
(svn r6764) -Fix (r6758): Wrong height difference calculated because invalid drag-type
...
was passed to the function. Thanks peter1138.
18 years ago
Darkvater
0ae642b914
(svn r6758) -Feature: Add a measurement tool that will show dimensions and height
...
differences of various draggable tools (inspiration, concept and double
checking by MeusH).
18 years ago
Darkvater
4d7c539889
(svn r6721) -Codechange: some comments, aligning, types and variable localization.
18 years ago
belugas
1c56a5ae0f
(svn r6499) -Codechange: Finally, got "byte event" outside of the union WindowEvent, which is now a struct
18 years ago
Darkvater
3ccc87b376
(svn r6462) -Codechange: Have GetStringWidth() return width as well as the height bounding
...
box of the string. Therefore rename the function to GetStringBoundingRect()
and have it return a BoundingRect type of width/height
18 years ago
Darkvater
f5bda65b05
(svn r6368) -Fix [FS#136]: Station catchment area persists after switching tools. The
...
correct fix was to reset the highlight box if any size changes (grimrc)
18 years ago
tron
da30222a91
(svn r6348) -Codechange: Remove redundant assignment
18 years ago
tron
a286726fe9
(svn r6347) Undo
18 years ago
tron
5f7d99fb6d
(svn r6346) -Codechange: Remove redundant assignment
18 years ago
tron
45e34d555c
(svn r6256) if () cascades -> switch ()
18 years ago
tron
b83a3f8726
(svn r6222) Remove struct ColorList, because the names of its attributes are plain confusing
...
All the struct holds is a simple colour gradient, so using a simple array with 8 entries is more clear
Also add the names of colour the gradients as enum
18 years ago
tron
39353d81fc
(svn r6211) Commit file forgotten in r6210
18 years ago
truelight
b34d77ca3f
(svn r6050) -Codechange: mass-renamed SignStruct -> Sign and ss -> si. Now functions and variables all match eachother
18 years ago
truelight
0461d89612
(svn r6047) -Codechange: FOR_ALL now _only_ loops valid items, and skips invalid ones
...
-Codechange: use IsValidXXX where ever possible
Note: both changes to prepare for new pool system, which needs those changes.
For every pool there are 2 ugly lines, which will be removed when done
implementing new pool system.
Based on FS#13 by blathijs, partly implemented.
18 years ago
truelight
2e0f68014e
(svn r6041) -Fix r6040: forgot to declare a function in viewport.c
18 years ago
truelight
7c6ec91ef7
(svn r6040) -Add: when clicking twice on a Location Button, the SmallMap centers on your position (based on FS#54 by thomasdev)
...
-Add: when clicking twice in SmallMap on a position, it centers there (based on FS#54 by thomasdev)
-Add: add a button in SmallMap that centers the SmallMap on your current position (based on FS#54 by thomasdev)
18 years ago
Darkvater
323a3160f7
(svn r6035) -Revert r5900 which supposedly fixed an invalid warning caused by buggy MS software
18 years ago
Darkvater
939e334ce2
(svn r5900) -Fix [FS#84]: Warning silencing fix for OpenTTD on Windows x64 (michi_cc)
18 years ago
tron
b3cda6ee62
(svn r5806) Inline FindLandscapeHeight() into its only remaining caller and remove the attribute "type" from struct TileInfo
18 years ago
tron
3254155930
(svn r5794) Pass the TileIndex plus x and y coordinates into GetSlopeZ_* instead of a TileInfo
18 years ago
tron
fef9818d3c
(svn r5631) Don't allocate memory for information about a sprite which isn't drawn
18 years ago
tron
82ebf842d1
(svn r5630) Replace a boolean variable by continue
18 years ago
tron
ea51ace5f4
(svn r5629) Simplify the test whether two bounding boxes overlap
18 years ago
tron
2e443e2b6f
(svn r5628) Rename the attributes for the bounding box of struct ParentSpriteToDraw to something sensible. Half of them was totally off: right is left, bottom is top *sigh*
18 years ago
belugas
6082507fea
(svn r5609) CodeChange : Apply coding style
18 years ago
tron
79e1f4eea0
(svn r5597) Remove the unused attribute ground_child from struct ViewportDrawer
18 years ago
tron
2b27073156
(svn r5391) Miscellaneous, mostly bracing and whitespace, nothing spectacular
18 years ago
tron
0a72639c2d
(svn r5210) Many small changes which piled up: const, unsigned, variable scope, CSE for readability, DeMorgan, if cascades -> switch, whitespace, parentheses, bracing, misc.
18 years ago
celestar
26f17e3e01
(svn r4819) -Debug: When clicking on a vehicle in the viewport, the index and address of the vehicle get dumped for "misc" debug levels >= 2
19 years ago
peter1138
fd778ecafa
(svn r4802) - Codechange: replace _stringwidth_base and associated magic numbers with a FontSize enum, using the numbers (which are SpriteIDs) in only the places needed.
19 years ago
tron
c1dc517dab
(svn r4554) Replace magic numbers by TILE_{HEIGHT,SIZE}
19 years ago
tron
0347fb2ab6
(svn r4541) Add a type for slopes and replace many magic numbers by the appropriate enums
19 years ago
celestar
caea7f845c
(svn r4502) -Cleanup: Remove code unused since rev1. (Rubidium)
19 years ago
celestar
3aa1e38be6
(svn r4246) -Codechange. Replaced about 100 occurences of '16' by TILE_SIZE
19 years ago
celestar
a175840697
(svn r3995) -Fix: Committed one file too much in 3992 (Thanks to Tron for pointing it out)
19 years ago
celestar
fc32e20195
(svn r3992) -Fix: Rewrote the code to determine whether a rail-tile can be terraformed.
...
Fixes a bug where you could terraform a tunnel (fixed by r3228, but reverted that one)
Fixes a bug introduced by r3228 which allowed steep rail tiles resulting in ... unwanted effects such as display artifacts.
That means the terraform feature should not work as intended; it also uses _valid_tileh_slopes to determine valid configurations instead of hand-brewn stuff.
TODO: _terraform_err_tile and similar TileIndices should have INVALID_TILE as "unused", not 0. (0 is a valid tile).
19 years ago
tron
84fb96fe85
(svn r3511) More whitespace ([FS#46] by Rubidium)
19 years ago
tron
e272b03fee
(svn r3365) Staticise 36 functions
19 years ago
tron
980e8f525b
(svn r3364) Remove 3 unused functions (ScrollWindowToTile, AllocateWindowAutoPlace, AllocateWindowAutoPlace2)
19 years ago
Darkvater
bfeddf1db1
(svn r3254) - Fix: graphical glitch with autorail tool on a certain tile-type.
...
- CodeChange: adhere the global variables in autorail.h to the coding style (eg. start with underscore).
19 years ago
bjarni
22a4679837
(svn r3218) -Feature: Multiheaded train engines will now stay in the same train
...
This means that any user attempt to remove a rear engine will tell the user to move the front engine instead
This fixes the assert when moving multiheaded engines (introduced in r3144)
Note: to make old savegames use this feature, some engines might be turned around in order to link engines in pairs
-Codechange: train subtype is now a bitmask
This allows fast access to info like if it is a wagon or engine and if it is in front and so on
Note: savegame version bump
19 years ago
tron
8cebe2f607
(svn r3204) Make handling of clicking on vehicles a bit less ugly by avoiding function declarations in .c files and unnecessary indirection
19 years ago