summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortron <tron@openttd.org>2006-04-02 07:30:01 +0000
committertron <tron@openttd.org>2006-04-02 07:30:01 +0000
commitdd688cecdd725b9a78cd03b6a0bac45e230e79ae (patch)
tree573b5b763f9c6a8b01b76e4ab5f65bd5a354cadb
parentb5eb55d527817ac4cbd74a916f77a6d23d4b6cd5 (diff)
downloadopenttd-dd688cecdd725b9a78cd03b6a0bac45e230e79ae.tar.xz
(svn r4231) Remove ModifyTile(), it's not used anymore, yay!
-rw-r--r--functions.h1
-rw-r--r--landscape.c47
-rw-r--r--openttd.h20
3 files changed, 0 insertions, 68 deletions
diff --git a/functions.h b/functions.h
index 18fd82d5e..2603fa0c7 100644
--- a/functions.h
+++ b/functions.h
@@ -7,7 +7,6 @@
void FindLandscapeHeight(TileInfo *ti, uint x, uint y);
void DoClearSquare(TileIndex tile);
-void CDECL ModifyTile(TileIndex tile, uint flags, ...);
void RunTileLoop(void);
uint GetPartialZ(int x, int y, int corners);
diff --git a/landscape.c b/landscape.c
index 4ba7f12e4..033ef3205 100644
--- a/landscape.c
+++ b/landscape.c
@@ -342,53 +342,6 @@ int32 CmdClearArea(int ex, int ey, uint32 flags, uint32 p1, uint32 p2)
}
-/* utility function used to modify a tile */
-void CDECL ModifyTile(TileIndex tile, uint flags, ...)
-{
- va_list va;
- int i;
-
- va_start(va, flags);
-
- if ((i = GB(flags, 8, 4)) != 0) {
- SetTileType(tile, i - 1);
- }
-
- if (flags & (MP_MAP2_CLEAR | MP_MAP2)) {
- int x = 0;
- if (flags & MP_MAP2) x = va_arg(va, int);
- _m[tile].m2 = x;
- }
-
- if (flags & (MP_MAP3LO_CLEAR | MP_MAP3LO)) {
- int x = 0;
- if (flags & MP_MAP3LO) x = va_arg(va, int);
- _m[tile].m3 = x;
- }
-
- if (flags & (MP_MAP3HI_CLEAR | MP_MAP3HI)) {
- int x = 0;
- if (flags & MP_MAP3HI) x = va_arg(va, int);
- _m[tile].m4 = x;
- }
-
- if (flags & (MP_MAPOWNER|MP_MAPOWNER_CURRENT)) {
- PlayerID x = _current_player;
- if (flags & MP_MAPOWNER) x = va_arg(va, int);
- _m[tile].m1 = x;
- }
-
- if (flags & MP_MAP5) {
- _m[tile].m5 = va_arg(va, int);
- }
-
- va_end(va);
-
- if (!(flags & MP_NODIRTY))
- MarkTileDirtyByTile(tile);
-}
-
-
#define TILELOOP_BITS 4
#define TILELOOP_SIZE (1 << TILELOOP_BITS)
#define TILELOOP_ASSERTMASK ((TILELOOP_SIZE-1) + ((TILELOOP_SIZE-1) << MapLogX()))
diff --git a/openttd.h b/openttd.h
index f8fdfb2f9..2ca959c4d 100644
--- a/openttd.h
+++ b/openttd.h
@@ -353,26 +353,6 @@ typedef struct {
} TileTypeProcs;
-
-#define MP_SETTYPE(x) ((x+1) << 8)
-
-enum {
- MP_MAP2 = 1<<0,
- MP_MAP3LO = 1<<1,
- MP_MAP3HI = 1<<2,
- MP_MAP5 = 1<<3,
- MP_MAPOWNER_CURRENT = 1<<4,
- MP_MAPOWNER = 1<<5,
-
- MP_TYPE_MASK = 0xF << 8,
-
- MP_MAP2_CLEAR = 1 << 12,
- MP_MAP3LO_CLEAR = 1 << 13,
- MP_MAP3HI_CLEAR = 1 << 14,
-
- MP_NODIRTY = 1<<15,
-};
-
enum {
WC_MAIN_WINDOW = 0x0,
WC_MAIN_TOOLBAR = 0x1,