(svn r23615) -Add: more API functions exposed to NoGo (part 2)

This commit is contained in:
truebrain
2011-12-19 20:57:34 +00:00
parent 436cf09923
commit 9359c6fc47
49 changed files with 914 additions and 46 deletions

View File

@@ -24,7 +24,7 @@
/* static */ bool ScriptEngine::IsValidEngine(EngineID engine_id)
{
const Engine *e = ::Engine::GetIfValid(engine_id);
return e != NULL && (::IsEngineBuildable(engine_id, e->type, _current_company) || ::Company::Get(_current_company)->group_all[e->type].num_engines[engine_id] > 0);
return e != NULL && (::IsEngineBuildable(engine_id, e->type, _current_company) || (_current_company != OWNER_DEITY && ::Company::Get(_current_company)->group_all[e->type].num_engines[engine_id] > 0));
}
/* static */ bool ScriptEngine::IsBuildable(EngineID engine_id)