tron
6dbc9c9ced
(svn r4554) Replace magic numbers by TILE_{HEIGHT,SIZE}
2006-04-23 19:35:36 +00:00
tron
dd180a1e18
(svn r4541) Add a type for slopes and replace many magic numbers by the appropriate enums
2006-04-23 13:48:16 +00:00
celestar
093984ea30
(svn r4385) -Codechange: remove map5 from the TileInfo struct as it is now unused. This effort is starting to pay off ...
2006-04-12 12:58:53 +00:00
tron
c5bc91eb0c
(svn r4344) Use tile coordinates or even TileIndices instead of virtual tile coordinates where it suffices.
2006-04-10 12:36:04 +00:00
tron
35e93e451f
(svn r4342) Change the first two parameters of commands - virtual pixel coordinates of the tile to operate on - to a TileIndex
...
Remove DoCommandByTile(), because now it does the same as DoCommand()
2006-04-10 07:15:58 +00:00
tron
aa5777c874
(svn r4279) s/\<CL_/CLEAR_/
2006-04-04 21:35:13 +00:00
celestar
69e1c716e8
(svn r4249) -Codechange: Replace more occurences of 16 by TILE_SIZE and of 8 by TILE_HEIGHT. Reverted one change from the previous commit because it was faulty
2006-04-03 09:07:21 +00:00
tron
7163a64c25
(svn r4242) Pass TileIndex and slope to GetSlopeTileh_*() instead of TileInfo
2006-04-02 12:49:18 +00:00
tron
dd688cecdd
(svn r4231) Remove ModifyTile(), it's not used anymore, yay!
2006-04-02 07:30:01 +00:00
belugas
1b28d92fc8
(svn r4181) CodeChange : Replaced [G/S]etMapExtraBits by [G/S]etTropicZone. Although it was an accessor, nor his usage nor the values were clear.
2006-03-30 19:16:44 +00:00
tron
c712f65e4f
(svn r4028) The last external user of FindLandscapeHeightByTile() is gone (r4027).
...
Move its implementation into its only caller - FindLandscapeHeight() - and remove it
2006-03-22 19:16:58 +00:00
tron
4efa560ffc
(svn r3763) Adapt to the new 'map accessors go in foo_map.h'-scheme
2006-03-05 10:19:33 +00:00
tron
116fb6dff6
(svn r3714) Add functions to turn tiles into water and shore tiles
2006-03-01 21:00:44 +00:00
tron
c18791022e
(svn r3667) Fix the cause of an assertion I triggered in r3665
2006-02-24 20:35:37 +00:00
tron
3cde68077e
(svn r3665) Add a function to turn a tile into a clear tile
2006-02-24 19:56:24 +00:00
tron
6b7d4721bd
(svn r3664) Add a function to turn a tile into a void tile
2006-02-24 19:52:26 +00:00
tron
5352e9fbcb
(svn r3597) Miscellaneous (I like that word) changes: Fix some indentation, add consts, reduce indentation level by short-circuit logic, convert if cascades to switch, whitespace, bracing, plus some minor stuff
2006-02-13 21:15:00 +00:00
tron
5e0c8a239e
(svn r3514) -Codechange: Replace direct fiddling of bits for the ground type and density of clear tiles with symbolic names and accessors.
...
See clear.h for details
2006-02-01 15:31:21 +00:00
tron
1c3e8630fe
(svn r3511) More whitespace ([FS#46] by Rubidium)
2006-02-01 07:36:15 +00:00
tron
9712d6f639
(svn r3510) Fiddle with whitespace and parentheses
2006-02-01 06:32:03 +00:00
tron
244d4ab5cb
(svn r3490) -Fix: A bunch (10) of off-by-one errors when checking if a TileIndex points to a tile on the map
2006-01-30 17:18:45 +00:00
tron
9d0e7b6458
(svn r3181) -Bracing
...
-Indentation
-Whitespace
-DeMorgan's Law
-Test with NULL or 0 for non-booleans
-'\0' instead of 0 for chars
-Remove redundantly redundant comments (like DoFoo(); // Do foo)
-Join multiple short lines with a single statement
-Split single lines with multiple statements
-Avoid assignments in if
2005-11-14 19:48:04 +00:00
tron
0b936c3222
(svn r3077) static, const, bracing, indentation, 0 -> '\0'/NULL, typos in comments, excess empty lines, minor other changes
...
nothing spectacular, just some stuff, which piled up
2005-10-22 06:39:32 +00:00
tron
b17b87469c
(svn r3064) Replace some numbers by sprite names
2005-10-19 06:46:41 +00:00
tron
8980891b09
(svn r3024) -Codechange: Another batch of replacements of int/uint/int16/byte/-1 with proper types and constants
2005-10-07 07:35:15 +00:00
tron
8b74a95d36
(svn r2886) Rename the "owner" attribute to "m1", because when it stores an owner it is accessed by [GS]etOwner anyway and when it doesn't store an owner, but arbitrary data, accessing a field called "owner" is confusing.
2005-08-23 18:47:04 +00:00
tron
647cbd6bdd
(svn r2701) Insert Id tags into all source files
2005-07-24 14:12:37 +00:00
tron
54cbd01825
(svn r2673) Include functions.h directly, not globally via openttd.h
2005-07-22 07:02:20 +00:00
tron
71140a5768
(svn r2669) Shuffle some more stuff around to reduce dependencies
2005-07-21 22:15:02 +00:00
tron
8b05455903
(svn r2664) Remove depedency on player.h from variables.h
2005-07-21 19:36:43 +00:00
tron
6ad3895306
(svn r2660) Get rid of some more shifting/anding/casting
2005-07-21 06:31:02 +00:00
tron
f09638ad3d
(svn r2650) Convert many explicit shifts+ands to extract bits to invocations of GB - should be a bit nicer to read
2005-07-20 15:29:28 +00:00
ludde
8086017097
(svn r2564) Fix: Fixed conceptual issue in network_gui.c. AllocateName is not meant to be used by GUI-code, because it modifies the "game-state".
...
Added a way to bind a C-string to an openttd string which doesn't modify the game state.
2005-07-14 09:43:59 +00:00
ludde
2123deff13
(svn r2560) Fix: various minor code changes.
...
Added RandomTile/RandomTileSeed functions to generate a random tile.
Changed landscape routines so they don't assume that the Y map side is a power of two. (support for this is not complete, though)
Changed some frequently used map macros to not compute the values each time.
Silence some warnings on MSVC.
2005-07-13 19:51:31 +00:00
tron
a4bf608d40
(svn r2558) Change the internal map format from 7 arrays to one array of structs, this doesn't change the saved format for now. It's a stepping stone for further changes.
2005-07-13 18:04:01 +00:00
tron
6923badbba
(svn r2505) Remove some unnecessary #includes
2005-07-01 15:46:27 +00:00
tron
9617614b04
(svn r2487) Replace TILE_XY by TileXY/TileDiffXY
2005-06-25 16:44:57 +00:00
tron
2b73dec567
(svn r2486) Turn TILE_FROM_XY into an inline function and rename it to TileVirtXY
2005-06-25 06:15:43 +00:00
tron
7ea9ddacbb
(svn r2464) Move definition of _inclined_tileh out of variables.h
2005-06-20 20:08:10 +00:00
tron
ff0030936e
(svn r2408) Introduce SetTileOwner() and use it
2005-06-04 12:13:24 +00:00
Darkvater
ba8c649fac
(svn r2397) - CodeChange: rename all "ttd" files to "openttd" files.
2005-06-02 19:30:21 +00:00
Darkvater
562a32c3ee
(svn r2297) - CodeChange: server-check the next batch of commands.
...
- CodeChange: since only the server will be able to modify difficulty settings, leave the checking of correct values besides, and trust users will join legit servers.
- CodeChange: for renaming signs, only check if GetDParam(); eg _decode_parameters is empty ('\0') or not, instead of the extra check of players, etc. That basically does the same thing. Also dirty sign two times when renaming, once before, once after the action. Because if the name becomes shorter and you update only after, garbage remains on the screen.
- CodeChange: made GetMaskOfTownActions() available to the town-cmd to double-check if the action was available to the player. For this purpose the hardcoded _local_player has been removed from the function and is now passed as a parameter.
2005-05-12 00:11:37 +00:00
Darkvater
419af5cece
(svn r2279) - Fix: Check the parameters of the first 10 Commands. While there also add proper comments for the functions and fix up CmdFailed()
2005-05-07 10:26:12 +00:00
tron
1086f772bb
(svn r2093) uint -> TileIndex, remove commented out code and a local variable, which was only used once
2005-03-27 18:15:27 +00:00
tron
6b736738ba
(svn r1888) The landscape template sprites are ordinary sprites, treating them as non-sprites resulted in yet another endianess issue. This fixes the problem introduced in r1855
2005-02-18 21:20:55 +00:00
tron
830565514c
(svn r1867) Include tables/sprites.h only in files which need it
2005-02-13 11:18:02 +00:00
tron
6d2b9d2c3a
(svn r1863) Give the effect vehicle type enums more descriptive names and use the enum as parameter type for CreateEffectVehicle*()
...
-Fix: [1116619] Generate the correct smoke type for diesel trains
2005-02-12 15:53:32 +00:00
tron
d2703fd672
(svn r1854) Split GetSpritePtr() into GetSprite() for regular sprites (returning a Sprite*) and GetNonSprite() for "sprites" of type 0xFF (returning byte*)
2005-02-10 12:14:38 +00:00
tron
7cd19fe07a
(svn r1853) Move spritecache function declarations into a header of their own and use SpriteID as parameter type where appropriate
2005-02-10 05:43:30 +00:00
tron
7d56d1d841
(svn r1839) Move GetTileSlope() and GetTileZ() into tile.[ch] and use more explicit types as parameters
2005-02-07 10:41:45 +00:00