tron
559babcdc9
(svn r2673) Include functions.h directly, not globally via openttd.h
2005-07-22 07:02:20 +00:00
tron
e53c4db866
(svn r2664) Remove depedency on player.h from variables.h
2005-07-21 19:36:43 +00:00
tron
284d9ed7fb
(svn r2663) Include variables.h only in these files which need it, not globally via openttd.h
2005-07-21 18:44:27 +00:00
tron
d71788c402
(svn r2660) Get rid of some more shifting/anding/casting
2005-07-21 06:31:02 +00:00
tron
ac66e3e28f
(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
6013b327f7
(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
8c1d74162f
(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
ab7b8b50e3
(svn r2492) Remove some pointless casts and fix some nearby indentation
2005-06-27 06:57:24 +00:00
tron
bec5e4fb4c
(svn r2487) Replace TILE_XY by TileXY/TileDiffXY
2005-06-25 16:44:57 +00:00
tron
61f6f07edd
(svn r2486) Turn TILE_FROM_XY into an inline function and rename it to TileVirtXY
2005-06-25 06:15:43 +00:00
tron
cea090af09
(svn r2485) Missed two uint -> TileIndex, thanks _Luca_
2005-06-24 17:41:08 +00:00
tron
3154e7148d
(svn r2483) Replace almost 500 "uint tile" (and variants) with "TileIndex tile"
2005-06-24 12:38:35 +00:00
tron
0c4ecbe9ec
(svn r2407) Use {Get,Is}TileOwner to get/check the owner of a tile and fix some bogus reads of _map_owner
2005-06-04 11:56:32 +00:00
Darkvater
b438b1248c
(svn r2397) - CodeChange: rename all "ttd" files to "openttd" files.
2005-06-02 19:30:21 +00:00
Darkvater
0cd53574ec
(svn r2384) - Fix: Check selling land and setting player colour. Also an extra map-bounds check for terraforming; inspired by the monkey (and Tron :) )
2005-05-30 15:50:20 +00:00
Darkvater
033995ec6e
(svn r2300) - CodeChange: check the last number of commands, now only the refit ones remain, and some server-only commands.
...
- CodeChange: remove cmd-misuses CmdStartScenario() and CmdDestroyCompanyHQ()
- Fix (invisible): when parameter checking CmdRestoreOrderIndex() the vehicle did not have its orders yet, so it would fail. So move doing this until AFTER the orders have been added back in RestoreVehicleOrders()
2005-05-12 23:46:01 +00:00
Darkvater
edd8c87502
(svn r2286) - CodeChange: paramcheck the next batch of commands.
...
- Fix (regression): fix up terraform land where every player can terraform land (towns, map generation), and player can terraform different corners; used for building tunnels
2005-05-09 16:37:40 +00:00
Darkvater
3ad11e0ad4
(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
truelight
cef2e24ec4
(svn r2075) -Fix: added missing breaks in switches
...
-Fix: added const for a const variable
2005-03-26 12:08:56 +00:00
tron
77b3a76919
(svn r1802) Fix typos made in r1797
2005-02-05 15:49:57 +00:00
tron
b4c3f9aaf0
(svn r1797) Clean up TileLoopClearHelper() a bit:
...
- if cascades -> switch
- uint -> TileIndex
- (uint)-1 -> INVALID_TILE
- don't treat non-flags as flags
2005-02-04 20:17:15 +00:00
tron
5885b31bb4
(svn r1713) Split off several functions which query/set information about a single tile from map.h and put them into a seperate file tile.h
2005-01-29 12:19:05 +00:00
tron
3617d24318
(svn r1706) Implement ScaleByMapSize() and ScaleByMapSize1D()
...
These scale a number relative to the map size/circumference.
Use them to scale the amount of map objects.
Of course at the moment they return just the input, because there are no bigger/smaller maps yet.
2005-01-28 15:31:04 +00:00
dominik
29e0ded977
(svn r1631) A couple of fixes for the signed/unsigned warnings. Only train_cmd.c remains to need fixing...
2005-01-23 23:58:35 +00:00
tron
e5cd6b6193
(svn r1596) Add some more statics
2005-01-22 22:47:58 +00:00
tron
189ca73707
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
2005-01-22 20:23:18 +00:00
tron
31d6f87d80
(svn r1560) Introduce SetTileType() and SetTileHeight()
...
Replace direct references to _map_type_and_height with these
2005-01-18 18:41:56 +00:00
tron
022b8cea37
(svn r1545) Add TileHeight() which returns the height (not multiplied by 8)
...
Replace some direct references to _map_type_and_height with TileHeight()/IsTileType()
2005-01-16 14:50:01 +00:00
tron
ae796740aa
(svn r1536) Move GET_TILEHEIGHT, GET_TILETYPE and IS_TILETYPE to map.h, turn them into inline functions and add some asserts
2005-01-16 11:24:58 +00:00
tron
7ca6b2b8b0
(svn r1414) Move TileIndex, TILE_MASK and GET_TILE_[XY] to map.h and turn the latter into inline functions names Tile[XY]
2005-01-07 17:02:43 +00:00
tron
f8c95a1dbe
(svn r1396) Introduce TileIndexDiffC - the compile time version of TileIndexDiff
2005-01-06 11:39:00 +00:00
tron
67161506ad
(svn r1386) Move TileIndexDiff to map.h
...
Move _tileoffs_by_dir to map.[ch] and encapsulate it in TileOffsByDir()
2005-01-05 13:32:03 +00:00
darkvater
6edb21231e
(svn r1375) -Fix: [1050990] Buying trains sometimes accounted for incorrectly. Was the result of the cost getting reset in a recursive call of docommand. That is fixed. In addition all cost-commands are typed explicitely. Please do not forget to do so or your costs will be credited to construction if you are unlucky.
2005-01-04 17:11:03 +00:00
tron
c0702318d2
(svn r1344) Use MapSize[XY]() (or MapSize()/MapMax[XY]() where appropriate) instead of TILES_[XY]
2005-01-03 18:59:58 +00:00
tron
32bfe0dddd
(svn r1337) Use MapMax[XY]() (or MapSize[XY]() if appropriate) instead of TILE_MAX_[XY]
...
While here replace one erroneous TILE_MAX_X with MapMaxY()
2005-01-03 12:56:22 +00:00
tron
765ecfed84
(svn r1117) Move map arrays and some related macros into their own files map.c and map.h
2004-12-15 22:18:54 +00:00
tron
acbd1801c7
(svn r815) Include strings.h only in the files which need it.
...
This should reduce the compile time after altering english.txt by about 1/3, because "only" 62 instead of 90 .c files must be recompiled.
2004-11-25 10:47:30 +00:00
tron
57adc97733
(svn r724) Remove restriction that a tile can only accept 3 cargo types.
...
This especially enables houses to accept passengers, mail, goods AND food.
Add string templates for up to 5 cargo types for the tile info window. If more are needed just add them.
Simplify (de-uglify) the logic for cargo acceptence for houses and split the goods/food table into two. The acceptance is unmodified, but accepting goods AND food is now trivially possible. The exact amounts have to be decided.
This is based on Celestar's changes in the map branch plus some further bits that will be merged there soon.
2004-11-21 10:49:40 +00:00
tron
249a170ace
(svn r607) -Patch: [ 985102 ] static cleanup
...
Thanks to lvoge
2004-11-14 19:44:06 +00:00
tron
37e199cd2b
(svn r526) -Fix: [1035303] bug about lowering tracks built on slopes
...
While here make sure that the failing tile gets a red error marker
2004-11-08 09:11:55 +00:00
truelight
eb49a19460
(svn r194) -Codechange: stripping trailing-spaces. Please keep this that way!
2004-09-10 19:02:27 +00:00
truelight
10d54ac604
(svn r160) -Codechange: made GetTileTrackStatus more readable (blathijs)
...
-Fix: some minor fixes around GetTileTrackStatus (blathijs)
2004-09-05 16:15:22 +00:00
darkvater
7b02cd3248
(svn r150) -Fix: [1010833] Turning on the magic bulldozer removes oil rigs
...
-Fix: [993493] Buildings on water
-Feature: Water floods everything, including vehicles.
2004-09-03 17:57:27 +00:00
dominik
ca120eedad
(svn r40) Final slope graphics fix
2004-08-13 18:27:33 +00:00
truelight
efaeb275f7
(svn r1) Import of revision 975 of old (crashed) SVN
2004-08-09 17:04:08 +00:00