default.h

00001 /* $Id: default.h 11818 2008-01-12 14:10:35Z rubidium $ */
00002 
00003 #ifndef DEFAULT_H
00004 #define DEFAULT_H
00005 
00006 #include "../../direction_type.h"
00007 #include "../../vehicle_type.h"
00008 #include "../../rail_type.h"
00009 
00010 void AiDoGameLoop(Player*);
00011 void SaveLoad_AI(PlayerID id);
00012 
00013 struct AiBuildRec {
00014   TileIndex spec_tile;
00015   TileIndex use_tile;
00016   byte rand_rng;
00017   byte cur_building_rule;
00018   byte unk6;
00019   byte unk7;
00020   byte buildcmd_a;
00021   byte buildcmd_b;
00022   byte direction;
00023   CargoID cargo;
00024 };
00025 
00026 struct PlayerAI {
00027   byte state;
00028   byte tick;            
00029   uint32 state_counter; 
00030   uint16 timeout_counter;
00031 
00032   byte state_mode;
00033   byte banned_tile_count;
00034   RailTypeByte railtype_to_use;
00035 
00036   CargoID cargo_type;
00037   byte num_wagons;
00038   byte build_kind;
00039   byte num_build_rec;
00040   byte num_loco_to_build;
00041   byte num_want_fullload;
00042 
00043   byte route_type_mask;
00044 
00045   TileIndex start_tile_a;
00046   TileIndex cur_tile_a;
00047   DiagDirectionByte cur_dir_a;
00048   DiagDirectionByte start_dir_a;
00049 
00050   TileIndex start_tile_b;
00051   TileIndex cur_tile_b;
00052   DiagDirectionByte cur_dir_b;
00053   DiagDirectionByte start_dir_b;
00054 
00055   Vehicle *cur_veh; 
00056 
00057   AiBuildRec src, dst, mid1, mid2;
00058 
00059   VehicleID wagon_list[9];
00060   byte order_list_blocks[20];
00061 
00062   TileIndex banned_tiles[16];
00063   byte banned_val[16];
00064 };
00065 
00066 extern PlayerAI _players_ai[MAX_PLAYERS];
00067 
00068 #endif

Generated on Mon Sep 22 20:34:14 2008 for openttd by  doxygen 1.5.6