mirror of https://github.com/OpenTTD/OpenTTD.git
(svn r3253) -Add: add BuildRoad event for AIs
This commit is contained in:
parent
7460ecd42a
commit
214ed794a1
|
@ -53,6 +53,8 @@ DEF_EVENTS int ottd_Event_VehicleEnterDepot INITIAL_SET; // (vehicle_index,
|
|||
DEF_EVENTS int ottd_Event_RoadVehicleEnterDepot INITIAL_SET; // (vehicle_index, depot_tile)
|
||||
|
||||
DEF_EVENTS int ottd_Event_GiveOrder INITIAL_SET; // (vehicle_index)
|
||||
|
||||
DEF_EVENTS int ottd_Event_BuildRoad INITIAL_SET; // (road_tile, road_pieces)
|
||||
/* ----------------- End of list ------------------ */
|
||||
|
||||
#endif /* AI_EVENT */
|
||||
|
|
|
@ -487,6 +487,8 @@ do_clear:;
|
|||
_m[tile].m5 |= pieces;
|
||||
|
||||
MarkTileDirtyByTile(tile);
|
||||
|
||||
ai_event(_current_player, ottd_Event_BuildRoad, tile, pieces);
|
||||
}
|
||||
return cost;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue