author | truebrain |
Mon, 30 Jun 2008 13:51:28 +0000 | |
branch | noai |
changeset 11102 | aacdde10b4ad |
parent 10455 | 22c441f5adf9 |
permissions | -rw-r--r-- |
9732 | 1 |
/* $Id$ */ |
2 |
||
10455
22c441f5adf9
(svn r12997) [NoAI] -Sync: with trunk r12895:12996.
rubidium
parents:
9732
diff
changeset
|
3 |
/** @file newgrf_generic.h Functions related to generic callbacks. */ |
22c441f5adf9
(svn r12997) [NoAI] -Sync: with trunk r12895:12996.
rubidium
parents:
9732
diff
changeset
|
4 |
|
9732 | 5 |
#ifndef NEWGRF_GENERIC_H |
6 |
#define NEWGRF_GENERIC_H |
|
7 |
||
8 |
enum AIConstructionEvent { |
|
9 |
AICE_TRAIN_CHECK_RAIL_ENGINE = 0x00, ///< Check if we should build an engine |
|
10 |
AICE_TRAIN_CHECK_ELRAIL_ENGINE = 0x01, |
|
11 |
AICE_TRAIN_CHECK_MONORAIL_ENGINE = 0x02, |
|
12 |
AICE_TRAIN_CHECK_MAGLEV_ENGINE = 0x03, |
|
13 |
AICE_TRAIN_GET_RAIL_WAGON = 0x08, |
|
14 |
AICE_TRAIN_GET_ELRAIL_WAGON = 0x09, |
|
15 |
AICE_TRAIN_GET_MONORAIL_WAGON = 0x0A, |
|
16 |
AICE_TRAIN_GET_MAGLEV_WAGON = 0x0B, |
|
17 |
AICE_TRAIN_GET_RAILTYPE = 0x0F, |
|
18 |
||
19 |
AICE_ROAD_CHECK_ENGINE = 0x00, ///< Check if we should build an engine |
|
20 |
AICE_ROAD_GET_FIRST_ENGINE = 0x01, ///< Unused, we check all |
|
21 |
AICE_ROAD_GET_NUMBER_ENGINES = 0x02, ///< Unused, we check all |
|
22 |
||
23 |
AICE_SHIP_CHECK_ENGINE = 0x00, ///< Check if we should build an engine |
|
24 |
AICE_SHIP_GET_FIRST_ENGINE = 0x01, ///< Unused, we check all |
|
25 |
AICE_SHIP_GET_NUMBER_ENGINES = 0x02, ///< Unused, we check all |
|
26 |
||
27 |
AICE_AIRCRAFT_CHECK_ENGINE = 0x00, ///< Check if we should build an engine |
|
28 |
||
29 |
AICE_STATION_GET_STATION_ID = 0x00, ///< Get a station ID to build |
|
30 |
}; |
|
31 |
||
32 |
void ResetGenericCallbacks(); |
|
33 |
void AddGenericCallback(uint8 feature, const struct GRFFile *file, const struct SpriteGroup *group); |
|
34 |
||
35 |
uint16 GetAiPurchaseCallbackResult(uint8 feature, CargoID cargo_type, uint8 default_selection, IndustryType src_industry, IndustryType dst_industry, uint8 distance, AIConstructionEvent event, uint8 count, uint8 station_size, const struct GRFFile **file); |
|
36 |
||
37 |
#endif /* NEWGRF_GENERIC_H */ |