Retrofit Minister moving space stations |

| Project: | Space Empires V |
| Version: | 1.13 |
| Component: | Miscellaneous |
| Category: | bug |
| Priority: | minor |
| Assigned: | Unassigned |
| Status: | closed |
Description
The retrofit minister issues a "Move to" to all ships so that they know where to go to retrofit. This minister also issues a "Move to" to any space stations needing retrofit. The destination is always the planet the space station is orbiting and besides the station can't move.
Workaround: Monitor orders to space stations and remove the "Move to" order. The station then retrofits normally on the next turn.
Updates
Possible fix. THIS HAS NOT BEEN TESTED YET!!
//------------------------------------------------------------------------
// Order_Retrofit
//------------------------------------------------------------------------
function Order_Retrofit returns boolean
params
ship_id: long
vars
orders_given: boolean
ai_design_type: string
this_design_id: long
best_design_id: long
begin
set orders_given := FALSE
set ai_design_type := Sys_Get_Space_Object_Ai_Design_Type(ship_id)
set this_design_id := Sys_Get_Space_Object_Vehicle_Design_ID(ship_id)
set best_design_id := Sys_Get_Latest_Vehicle_Design_Of_AI_Type(sys_long_Player_ID, ai_design_type)
if (this_design_id <> best_design_id) then
if (Sys_Get_Vehicle_Design_Space_Movement(design_id) = 0) then
set orders_given := Sys_Give_Space_Object_Order_Retrofit(ship_id, best_design_id)
else
set orders_given := Ship_Order_Go_To_SY(ship_id)
if (orders_given) then
set orders_given := Sys_Give_Space_Object_Order_Retrofit(ship_id, best_design_id)
endif
endif
endif
return orders_given
end
| Status: | active | » closed |
Submitted code corrected error and is included in current and previous patches.



