equal
deleted
inserted
replaced
13 #include "gfx.h" |
13 #include "gfx.h" |
14 #include "command.h" |
14 #include "command.h" |
15 #include "sound.h" |
15 #include "sound.h" |
16 #include "variables.h" |
16 #include "variables.h" |
17 #include "bridge.h" |
17 #include "bridge.h" |
|
18 #include "economy_new.h" |
18 |
19 |
19 static struct BridgeData { |
20 static struct BridgeData { |
20 uint count; |
21 uint count; |
21 TileIndex start_tile; |
22 TileIndex start_tile; |
22 TileIndex end_tile; |
23 TileIndex end_tile; |
143 for (bridge_type = 0; bridge_type != MAX_BRIDGES; bridge_type++) { // loop for all bridgetypes |
144 for (bridge_type = 0; bridge_type != MAX_BRIDGES; bridge_type++) { // loop for all bridgetypes |
144 if (CheckBridge_Stuff(bridge_type, bridge_len)) { |
145 if (CheckBridge_Stuff(bridge_type, bridge_len)) { |
145 const Bridge *b = &_bridge[bridge_type]; |
146 const Bridge *b = &_bridge[bridge_type]; |
146 // bridge is accepted, add to list |
147 // bridge is accepted, add to list |
147 // add to terraforming & bulldozing costs the cost of the bridge itself (not computed with DC_QUERY_COST) |
148 // add to terraforming & bulldozing costs the cost of the bridge itself (not computed with DC_QUERY_COST) |
148 _bridgedata.costs[j] = ret + (((int64)tot_bridgedata_len * _price.build_bridge * b->price) >> 8); |
149 _bridgedata.costs[j] = ret + (((int64)tot_bridgedata_len * _eco->GetPrice(CEconomy::BUILD_BRIDGE) * b->price) >> 8); |
149 _bridgedata.indexes[j] = bridge_type; |
150 _bridgedata.indexes[j] = bridge_type; |
150 j++; |
151 j++; |
151 } |
152 } |
152 } |
153 } |
153 } |
154 } |