From 54aa43c81b4adbaaf1eaab03062fa871d85fbeab Mon Sep 17 00:00:00 2001 From: yexo Date: Mon, 13 Aug 2012 19:22:26 +0000 Subject: (svn r24468) -Add [FS#5219]: API compatibility scripts for Goal Scripts (Hirundo) --- src/game/game_instance.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/game') diff --git a/src/game/game_instance.cpp b/src/game/game_instance.cpp index 120491715..df52ca91a 100644 --- a/src/game/game_instance.cpp +++ b/src/game/game_instance.cpp @@ -89,6 +89,8 @@ GameInstance::GameInstance() : void GameInstance::Initialize(GameInfo *info) { + this->versionAPI = info->GetAPIVersion(); + /* Register the GameController */ SQGSController_Register(this->engine); @@ -192,6 +194,8 @@ void GameInstance::RegisterAPI() SQGSWindow_Register(this->engine); RegisterGameTranslation(this->engine); + + if (!this->LoadCompatibilityScripts(this->versionAPI, GAME_DIR)) this->Died(); } int GameInstance::GetSetting(const char *name) -- cgit v1.2.3-70-g09d2