diff --git a/gamedir/Data/Scripts/GameInit.lua b/gamedir/Data/Scripts/GameInit.lua index e2d8d955a..ddeefa9ba 100644 --- a/gamedir/Data/Scripts/GameInit.lua +++ b/gamedir/Data/Scripts/GameInit.lua @@ -515,7 +515,7 @@ function InitNewGame() AddEmail (MERC_INTRO, MERC_INTRO_LENGTH, Sender.SPECK_FROM_MERC, -1, -1) end end - + -- Get starting cash from DifficultySettings.xml SetStartingCashDifLevel(newDIFFICULTY_LEVEL) diff --git a/gamedir/Data/Scripts/Overhead.lua b/gamedir/Data/Scripts/Overhead.lua index ef4380e06..23ac2f50d 100644 --- a/gamedir/Data/Scripts/Overhead.lua +++ b/gamedir/Data/Scripts/Overhead.lua @@ -164,6 +164,54 @@ SectorY = MAP_ROW_P = 16, } +-- text colours +FontColour = +{ + FONT_MCOLOR_DKWHITE = 134, + FONT_MCOLOR_LTYELLOW = 144, + FONT_MCOLOR_RED = 163, + FONT_MCOLOR_DKRED = 164, + FONT_MCOLOR_LTGREEN = 184, +} + +-- these numbers aren't used in the code - we only use them in LUA +Languages = +{ + LANGUAGE_ENGLISH = 0, + LANGUAGE_GERMAN = 1, + LANGUAGE_RUSSIAN = 2, + LANGUAGE_DUTCH = 3, + LANGUAGE_POLISH = 4, + LANGUAGE_FRENCH = 5, + LANGUAGE_ITALIAN = 6, + LANGUAGE_CHINESE = 7, +} + +-- numbers for addressing which stat should get more experience +StatTypes = +{ + HEALTHAMT = 1, + AGILAMT = 2, + DEXTAMT = 3, + WISDOMAMT = 4, + MEDICALAMT = 5, + EXPLODEAMT = 6, + MECHANAMT = 7, + MARKAMT = 8, + EXPERAMT = 9, + STRAMT = 10, + LDRAMT = 11, +} + +-- different teams +Teams = +{ + ENEMY_TEAM = 1, + CREATURE_TEAM = 2, + MILITIA_TEAM = 3, + CIV_TEAM = 4, +} + local iLoop local aimLoop @@ -337,4 +385,12 @@ function HandleAtNewGridNo( ProfileId ) end -- End what EPC end -- End team -end \ No newline at end of file +end + + +-- handle the result of an interactive action that has a special id set for lua +-- for more info, see InteractiveActions.xml +function HandleInteractiveActionResult(sSectorX, sSectorY, bSectorZ, sGridNo, bLevel, ubID, usActionType, sLuaactionid, difficulty, skill ) + +end + diff --git a/gamedir/Data/Scripts/Quests.lua b/gamedir/Data/Scripts/Quests.lua index eed1a57b5..1a06bb6d8 100644 --- a/gamedir/Data/Scripts/Quests.lua +++ b/gamedir/Data/Scripts/Quests.lua @@ -47,6 +47,9 @@ Profiles = { DYNAMO = 66, CARMEN = 78, + KINGPIN = 86, + MARIA = 88, + ANGEL = 89, MADAME = 107, } @@ -55,7 +58,7 @@ nHistory = { HISTORY_QUEST_FINISHED = 16, } -nFacts = { +Facts = { FACT_ESTONI_REFUELLING_POSSIBLE = 277, @@ -65,13 +68,15 @@ local NO_PROFILE = 200 function InternalStartQuest( ubQuest, sSectorX, sSectorY, fUpdateHistory ) -if ( CheckQuest(ubQuest) == qStatus.QUESTNOTSTARTED ) then + if ( CheckQuest(ubQuest) == qStatus.QUESTNOTSTARTED ) then + SetQuest( ubQuest, qStatus.QUESTINPROGRESS ) - if ( fUpdateHistory == true) then - if ( is_networked == 0 ) then - SetHistoryFact( nHistory.HISTORY_QUEST_STARTED, ubQuest, GetWorldTotalMin(), sSectorX, sSectorY ) - end - end + + if ( fUpdateHistory == true) then + if ( is_networked == 0 ) then + SetHistoryFact( nHistory.HISTORY_QUEST_STARTED, ubQuest, GetWorldTotalMin(), sSectorX, sSectorY ) + end + end else SetQuest( ubQuest, qStatus.QUESTINPROGRESS ) end diff --git a/gamedir/Data/Scripts/strategicmap.lua b/gamedir/Data/Scripts/strategicmap.lua index ee5029ac0..93da30c0d 100644 --- a/gamedir/Data/Scripts/strategicmap.lua +++ b/gamedir/Data/Scripts/strategicmap.lua @@ -266,6 +266,13 @@ function HandleQuestCodeOnSectorEntry( sNewSectorX, sNewSectorY, bNewSectorZ ) SetCharacterSectorY(Profil.ANGEL, 0) end + if ( sNewSectorX == 6 and sNewSectorY == SectorY.MAP_ROW_C and gubQuest( Quests.QUEST_LEATHER_SHOP_DREAM ) == qStatus.QUESTDONE ) then + -- move Kyle to his shop + SetCharacterSectorX(Profil.KYLE, 6) + SetCharacterSectorY(Profil.KYLE, SectorY.MAP_ROW_C) + SetProfileStrategicInsertionData(Profil.KYLE, 12380) + end + if ( sNewSectorX == 5 and sNewSectorY == SectorY.MAP_ROW_D ) then ResetBoxers() end @@ -316,3 +323,41 @@ function HandleQuestCodeOnSectorExit( sOldSectorX, sOldSectorY, bOldSectorZ ) SetFactFalse( Facts.FACT_MUSEUM_ALARM_WENT_OFF ) end + +-- text colours +FontColour = +{ + FONT_MCOLOR_DKWHITE = 134, + FONT_MCOLOR_LTYELLOW = 144, + FONT_MCOLOR_RED = 163, + FONT_MCOLOR_DKRED = 164, + FONT_MCOLOR_LTGREEN = 184, +} + +-- these numbers aren't used in the code - we only use them in LUA +Languages = +{ + LANGUAGE_ENGLISH = 0, + LANGUAGE_GERMAN = 1, + LANGUAGE_RUSSIAN = 2, + LANGUAGE_DUTCH = 3, + LANGUAGE_POLISH = 4, + LANGUAGE_FRENCH = 5, + LANGUAGE_ITALIAN = 6, + LANGUAGE_CHINESE = 7, +} + +-- this function is called whenever we liberate a sector. If fFirstTime is true, this is the first time we liberate this sector +function HandleSectorLiberation( sNewSectorX, sNewSectorY, bNewSectorZ, fFirstTime ) + +end + +-- this function is called whenever we recruit a RPC +function RecruitRPCAdditionalHandling( usProfile ) + +end + +-- this function is called whenever we enter a sector in tactical +function HandleSectorTacticalEntry( sSectorX, sSectorY, bSectorZ, fHasEverBeenPlayerControlled ) + +end