From 762a939e59349b8208ab2c31f4454646e85219db Mon Sep 17 00:00:00 2001 From: Wanne Date: Tue, 10 Sep 2013 11:24:11 +0000 Subject: [PATCH] - Bugfix: Creature Quest Cutscene was not triggered o There was a wrong condition in LUA script (In the ja2 source code this condition works, but not in LUA!!!) -> WRONG: if ( giLairID ) -> this is always triggered as TRUE and therefore never starts the cutscene -> CORRECT: if ( giLairID ~= 0 ) -> if the quest has not started ( value != 0), start the cutscene git-svn-id: https://ja2svn.mooo.com/source/ja2_v1.13_data@1763 4f8fa57e-7814-0410-bad4-adc449f26b7c --- gamedir/Data-1.13/Scripts/StrategicTownLoyalty.lua | 3 ++- gamedir/Data-UB/Scripts/StrategicTownLoyalty.lua | 3 ++- gamedir/Data/Scripts/StrategicTownLoyalty.lua | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/gamedir/Data-1.13/Scripts/StrategicTownLoyalty.lua b/gamedir/Data-1.13/Scripts/StrategicTownLoyalty.lua index 7daf3908a..988ac11ae 100644 --- a/gamedir/Data-1.13/Scripts/StrategicTownLoyalty.lua +++ b/gamedir/Data-1.13/Scripts/StrategicTownLoyalty.lua @@ -176,7 +176,8 @@ function CheckConditionsForTriggeringCreatureQuest( sSectorX, sSectorY, bSectorZ return -- No scifi, no creatures... end - if ( giLairID ) then + -- if ( giLairID ) -> that does not work in LUA, because that is always TRUE!! + if ( giLairID ~= 0 ) then return -- Creature quest already begun end diff --git a/gamedir/Data-UB/Scripts/StrategicTownLoyalty.lua b/gamedir/Data-UB/Scripts/StrategicTownLoyalty.lua index fa211cb2a..3c7109341 100644 --- a/gamedir/Data-UB/Scripts/StrategicTownLoyalty.lua +++ b/gamedir/Data-UB/Scripts/StrategicTownLoyalty.lua @@ -176,7 +176,8 @@ function CheckConditionsForTriggeringCreatureQuest( sSectorX, sSectorY, bSectorZ return -- No scifi, no creatures... end - if ( giLairID ) then + -- if ( giLairID ) -> that does not work in LUA, because that is always TRUE!! + if ( giLairID ~= 0 ) then return -- Creature quest already begun end diff --git a/gamedir/Data/Scripts/StrategicTownLoyalty.lua b/gamedir/Data/Scripts/StrategicTownLoyalty.lua index 656da151f..fd00029ac 100644 --- a/gamedir/Data/Scripts/StrategicTownLoyalty.lua +++ b/gamedir/Data/Scripts/StrategicTownLoyalty.lua @@ -175,7 +175,8 @@ function CheckConditionsForTriggeringCreatureQuest( sSectorX, sSectorY, bSectorZ return -- No scifi, no creatures... end - if ( giLairID ) then + -- if ( giLairID ) -> that does not work in LUA, because that is always TRUE!! + if ( giLairID ~= 0 ) then return -- Creature quest already begun end