2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-09 07:42:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    ExportEnemies , 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    ExportFusionBundles , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    ExportRegions , 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-20 04:42:11 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    ExportRelics , 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    ExportRewards , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    IMissionReward  as  IMissionRewardExternal , 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-31 04:15:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    IRegion , 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    IReward 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								}  from  "warframe-public-export-plus" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-04 17:40:06 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  IMissionInventoryUpdateRequest ,  IRewardInfo  }  from  "@/src/types/requestTypes" ; 
							 
						 
					
						
							
								
									
										
										
										
											2024-01-06 16:26:58 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  logger  }  from  "@/src/utils/logger" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-04 16:49:25 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  IRngResult ,  SRng ,  generateRewardSeed ,  getRandomElement ,  getRandomReward  }  from  "@/src/services/rngService" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								import  {  equipmentKeys ,  IMission ,  TEquipmentKey  }  from  "@/src/types/inventoryTypes/inventoryTypes" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-24 01:38:32 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addBooster , 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 00:41:15 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addCalendarProgress , 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addChallenges , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    addConsumables , 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-05 12:23:35 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addCrewShipAmmo , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    addCrewShipRawSalvage , 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-07 00:41:18 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addEmailItem , 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-27 18:11:05 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addFocusXpIncreases , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-23 11:37:10 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addFusionPoints , 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addFusionTreasures , 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-09 07:42:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addItem , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-07 05:29:32 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addLevelKeys , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 06:16:19 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addLoreFragmentScans , 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addMiscItems , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    addMissionComplete , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    addMods , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    addRecipes , 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-22 01:15:09 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addShipDecorations , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-26 11:54:38 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addSkin , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    addStanding , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-30 13:28:16 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    applyClientEquipmentUpdates , 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    combineInventoryChanges , 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:38:52 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    getDialogue , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-27 12:38:48 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    giveNemesisPetRecipe , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    giveNemesisWeaponRecipe , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-03 06:17:11 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    updateCurrency , 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-22 11:45:39 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    updateEntratiVault , 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    updateSyndicate 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								}  from  "@/src/services/inventoryService" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								import  {  updateQuestKey  }  from  "@/src/services/questService" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-05 06:52:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  Types  }  from  "mongoose" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  IAffiliationMods ,  IInventoryChanges  }  from  "@/src/types/purchaseTypes" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  fromStoreItem ,  getLevelKeyRewards ,  isStoreItem ,  toStoreItem  }  from  "@/src/services/itemDataService" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-05 06:52:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  TInventoryDatabaseDocument  }  from  "@/src/models/inventoryModels/inventoryModel" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 16:17:59 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  getEntriesUnsafe  }  from  "@/src/utils/ts-utils" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-04 17:40:06 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  handleStoreItemAcquisition  }  from  "@/src/services/purchaseService" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								import  {  IMissionCredits ,  IMissionReward  }  from  "@/src/types/missionTypes" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-25 04:38:47 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  crackRelic  }  from  "@/src/helpers/relicHelper" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  createMessage ,  IMessageCreationTemplate  }  from  "@/src/services/inboxService" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-28 18:09:37 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  kuriaMessage50  from  "@/static/fixed_responses/kuriaMessages/fiftyPercent.json" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								import  kuriaMessage75  from  "@/static/fixed_responses/kuriaMessages/seventyFivePercent.json" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								import  kuriaMessage100  from  "@/static/fixed_responses/kuriaMessages/oneHundredPercent.json" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-26 16:08:33 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  conservationAnimals  from  "@/static/fixed_responses/conservationAnimals.json" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:37:30 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:41:49 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    generateNemesisProfile , 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-14 21:14:04 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    getInfestedLichItemRewards , 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:37:30 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    getInfNodes , 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-14 21:14:04 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    getKillTokenRewardCount , 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-17 23:29:23 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    getNemesisManifest , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    getNemesisPasscode 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:37:30 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								}  from  "@/src/helpers/nemesisHelpers" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-04 17:40:06 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  Loadout  }  from  "@/src/models/inventoryModels/loadoutModel" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								import  {  ILoadoutConfigDatabase  }  from  "@/src/types/saveLoadoutTypes" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-23 15:02:30 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    getLiteSortie , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    getSortie , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    getWorldState , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    idToBountyCycle , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    idToDay , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    idToWeek , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    pushClassicBounties 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-04 17:40:06 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								}  from  "@/src/services/worldStateService" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								import  {  config  }  from  "@/src/services/configService" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-22 09:59:41 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  libraryDailyTasks  from  "@/static/fixed_responses/libraryDailyTasks.json" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-11 08:08:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  IGoal ,  ISyndicateMissionInfo  }  from  "@/src/types/worldStateTypes" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-04 17:40:06 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  fromOid  }  from  "@/src/helpers/inventoryHelpers" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								import  {  TAccountDocument  }  from  "@/src/services/loginService" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								import  {  ITypeCount  }  from  "@/src/types/commonTypes" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								import  {  IEquipmentClient  }  from  "@/src/types/equipmentTypes" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-15 08:14:36 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								import  {  Guild  }  from  "@/src/models/guildModel" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								import  {  handleGuildGoalProgress  }  from  "@/src/services/guildService" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 14:58:15 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								const  getRotations  =  ( rewardInfo : IRewardInfo ,  tierOverride? : number ) :  number [ ]  = >  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-11 08:09:15 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    // Disruption missions just tell us (https://onlyg.it/OpenWF/SpaceNinjaServer/issues/2599)
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( rewardInfo . rewardTierOverrides )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        return  rewardInfo . rewardTierOverrides ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 10:47:38 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    // For Spy missions, e.g. 3 vaults cracked = A, B, C
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( rewardInfo . VaultsCracked )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        const  rotations : number [ ]  =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        for  ( let  i  =  0 ;  i  !=  rewardInfo . VaultsCracked ;  ++ i )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-23 04:54:36 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            rotations . push ( Math . min ( i ,  2 ) ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 10:47:38 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        return  rotations ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:41 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    const  region  =  ExportRegions [ rewardInfo . node ]  as  IRegion  |  undefined ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    const  missionIndex : number  |  undefined  =  region ? . missionIndex ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-26 11:57:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 10:47:38 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    // For Rescue missions
 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-26 14:23:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( missionIndex  ==  3  &&  rewardInfo . rewardTier )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 10:47:38 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        return  [ rewardInfo . rewardTier ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:41 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    // 'rewardQualifications' is unreliable for non-endless railjack missions (https://onlyg.it/OpenWF/SpaceNinjaServer/issues/2586, https://onlyg.it/OpenWF/SpaceNinjaServer/issues/2612)
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    switch  ( region ? . missionName )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        case  "/Lotus/Language/Missions/MissionName_Railjack" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        case  "/Lotus/Language/Missions/MissionName_RailjackVolatile" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        case  "/Lotus/Language/Missions/MissionName_RailjackExterminate" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        case  "/Lotus/Language/Missions/MissionName_RailjackAssassinate" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            return  [ 0 ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-06 04:01:01 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-25 11:52:16 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    const  rotationCount  =  rewardInfo . rewardQualifications ? . length  ||  0 ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-20 07:53:11 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-26 11:57:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    // Empty or absent rewardQualifications should not give rewards when:
 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-25 11:52:16 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    // - Completing only 1 zone of (E)SO (https://onlyg.it/OpenWF/SpaceNinjaServer/issues/1823)
 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-26 11:57:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    // - Aborting a railjack mission (https://onlyg.it/OpenWF/SpaceNinjaServer/issues/1741)
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( rotationCount  ==  0  &&  missionIndex  !=  30  &&  missionIndex  !=  32 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        return  [ 0 ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-10 12:54:29 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    const  rotationPattern  = 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        tierOverride  ===  undefined 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ?  [ 0 ,  0 ,  1 ,  2 ]  // A, A, B, C
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            :  [ tierOverride ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    const  rotatedValues  =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    for  ( let  i  =  0 ;  i  <  rotationCount ;  i ++ )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        rotatedValues . push ( rotationPattern [ i  %  rotationPattern . length ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    return  rotatedValues ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} ; 
							 
						 
					
						
							
								
									
										
										
										
											2023-09-06 14:02:54 +04:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 09:46:08 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								const  getRandomRewardByChance  =  ( pool : IReward [ ] ,  rng? : SRng ) :  IRngResult  |  undefined  = >  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( rng )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        const  res  =  rng . randomReward ( pool  as  IRngResult [ ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        rng . randomFloat ( ) ;  // something related to rewards multiplier
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        return  res ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    return  getRandomReward ( pool  as  IRngResult [ ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								//type TMissionInventoryUpdateKeys = keyof IMissionInventoryUpdateRequest;
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								//const ignoredInventoryUpdateKeys = ["FpsAvg", "FpsMax", "FpsMin", "FpsSamples"] satisfies TMissionInventoryUpdateKeys[]; // for keys with no meaning for this server
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								//type TignoredInventoryUpdateKeys = (typeof ignoredInventoryUpdateKeys)[number];
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								//const knownUnhandledKeys: readonly string[] = ["test"] as const; // for unimplemented but important keys
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-03-07 00:41:18 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								export  const  addMissionInventoryUpdates  =  async  ( 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-23 06:12:54 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    account : TAccountDocument , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-05 06:52:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    inventory : TInventoryDatabaseDocument , 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    inventoryUpdates : IMissionInventoryUpdateRequest 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-08 06:29:05 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								) :  Promise < IInventoryChanges >  = >  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    const  inventoryChanges : IInventoryChanges  =  { } ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-07 05:29:32 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( inventoryUpdates . EndOfMatchUpload )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( inventoryUpdates . Missions  &&  inventoryUpdates . Missions . Tag  in  ExportRegions )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  node  =  ExportRegions [ inventoryUpdates . Missions . Tag ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( node . miscItemFee )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                addMiscItems ( inventory ,  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ItemType : node.miscItemFee.ItemType , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ItemCount : node.miscItemFee.ItemCount  *  - 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( inventoryUpdates . KeyToRemove )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( ! inventoryUpdates . KeyOwner  ||  inventory . accountOwnerId . equals ( inventoryUpdates . KeyOwner ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                addLevelKeys ( inventory ,  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ItemType : inventoryUpdates.KeyToRemove , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ItemCount :  - 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-04 06:02:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-04 02:46:32 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( inventoryUpdates . RewardInfo )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( inventoryUpdates . RewardInfo . periodicMissionTag )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  tag  =  inventoryUpdates . RewardInfo . periodicMissionTag ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  existingCompletion  =  inventory . PeriodicMissionCompletions . find ( completion  = >  completion . tag  ===  tag ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-09 09:39:45 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-04 02:46:32 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( existingCompletion )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                existingCompletion . date  =  new  Date ( ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventory . PeriodicMissionCompletions . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    tag : tag , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    date : new  Date ( ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( inventoryUpdates . RewardInfo . NemesisAbandonedRewards )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            inventory . NemesisAbandonedRewards  =  inventoryUpdates . RewardInfo . NemesisAbandonedRewards ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-09 09:39:45 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-26 15:25:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( inventoryUpdates . RewardInfo . NemesisHenchmenKills  &&  inventory . Nemesis )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            inventory . Nemesis . HenchmenKilled  +=  inventoryUpdates . RewardInfo . NemesisHenchmenKills ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( inventoryUpdates . RewardInfo . NemesisHintProgress  &&  inventory . Nemesis )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            inventory . Nemesis . HintProgress  +=  inventoryUpdates . RewardInfo . NemesisHintProgress ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:37:30 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( inventory . Nemesis . Faction  !=  "FC_INFESTATION"  &&  inventory . Nemesis . Hints . length  !=  3 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  progressNeeded  =  [ 35 ,  60 ,  100 ] [ inventory . Nemesis . Hints . length ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( inventory . Nemesis . HintProgress  >=  progressNeeded )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . Nemesis . HintProgress  -=  progressNeeded ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  passcode  =  getNemesisPasscode ( inventory . Nemesis ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . Nemesis . Hints . push ( passcode [ inventory . Nemesis . Hints . length ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-26 15:25:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-10 07:15:54 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( inventoryUpdates . MissionStatus  ==  "GS_SUCCESS"  &&  inventoryUpdates . RewardInfo . jobId )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // e.g. for Profit-Taker Phase 1:
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // JobTier: -6,
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // jobId: '/Lotus/Types/Gameplay/Venus/Jobs/Heists/HeistProfitTakerBountyOne_-6_SolarisUnitedHub1_663a71c80000000000000025_EudicoHeists',
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // This is sent multiple times, with JobStage starting at 0 and incrementing each time, but only the final upload has GS_SUCCESS.
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // eslint-disable-next-line @typescript-eslint/no-unused-vars
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  [ bounty ,  tier ,  hub ,  id ,  tag ]  =  inventoryUpdates . RewardInfo . jobId . split ( "_" ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( tag  ==  "EudicoHeists" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventory . CompletedJobChains  ? ? =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                let  chain  =  inventory . CompletedJobChains . find ( x  = >  x . LocationTag  ==  tag ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( ! chain )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    chain  = 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory . CompletedJobChains [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            inventory . CompletedJobChains . push ( {  LocationTag : tag ,  Jobs :  [ ]  } )  -  1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( ! chain . Jobs . includes ( bounty ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    chain . Jobs . push ( bounty ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-11 06:54:59 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    if  ( bounty  ==  "/Lotus/Types/Gameplay/Venus/Jobs/Heists/HeistProfitTakerBountyThree" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        await  createMessage ( inventory . accountOwnerId ,  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                sub :  "/Lotus/Language/SolarisHeists/HeavyCatalystInboxTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                sndr :  "/Lotus/Language/Bosses/Ordis" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                msg :  "/Lotus/Language/SolarisHeists/HeavyCatalystInboxMessage" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                icon :  "/Lotus/Interface/Icons/Npcs/Ordis.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                att :  [ "/Lotus/Types/Restoratives/HeavyWeaponSummon" ] , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                highPriority : true 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        await  addItem ( inventory ,  "/Lotus/Types/Items/MiscItems/HeavyWeaponCatalyst" ,  1 ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-10 07:15:54 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-08 05:36:06 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    for  ( const  [ key ,  value ]  of  getEntriesUnsafe ( inventoryUpdates ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( value  ===  undefined )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 00:41:15 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            logger . error ( ` Inventory update key  ${ key }  has no value ` ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            continue ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        switch  ( key )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "RegularCredits" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventory . RegularCredits  +=  value ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "QuestKeys" : 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-10 16:22:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                await  updateQuestKey ( inventory ,  value ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "AffiliationChanges" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                updateSyndicate ( inventory ,  value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // Incarnon Challenges
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "EvolutionProgress" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( const  evoProgress  of  value )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  entry  =  inventory . EvolutionProgress 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ?  inventory . EvolutionProgress . find ( entry  = >  entry . ItemType  ==  evoProgress . ItemType ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        :  undefined ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( entry )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        entry . Progress  =  evoProgress . Progress ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        entry . Rank  =  evoProgress . Rank ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory . EvolutionProgress  ? ? =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory . EvolutionProgress . push ( evoProgress ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "Missions" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                addMissionComplete ( inventory ,  value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "LastRegionPlayed" : 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-23 21:51:48 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( ! ( config . unfaithfulBugFixes ? . ignore1999LastRegionPlayed  &&  value  ===  "1999MapName" ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . LastRegionPlayed  =  value ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "RawUpgrades" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                addMods ( inventory ,  value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "MiscItems" : 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-05 12:23:35 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "BonusMiscItems" : 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                addMiscItems ( inventory ,  value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "Consumables" : 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-26 11:55:45 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( config . dontSubtractConsumables )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    addConsumables ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        value . filter ( x  = >  x . ItemCount  >  0 ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    addConsumables ( inventory ,  value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "Recipes" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                addRecipes ( inventory ,  value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "ChallengeProgress" : 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-30 01:50:23 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                await  addChallenges ( account ,  inventory ,  value ,  inventoryUpdates . SeasonChallengeCompletions ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "FusionTreasures" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                addFusionTreasures ( inventory ,  value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-05 12:23:35 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "CrewShipRawSalvage" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                addCrewShipRawSalvage ( inventory ,  value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "CrewShipAmmo" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                addCrewShipAmmo ( inventory ,  value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-22 01:15:09 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "ShipDecorations" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                // e.g. when getting a 50+ score in happy zephyr, this is how the poster is given.
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                addShipDecorations ( inventory ,  value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "FusionBundles" :  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-23 11:37:10 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                let  fusionPointsDelta  =  0 ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                for  ( const  fusionBundle  of  value )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-23 11:37:10 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    fusionPointsDelta  +=  addFusionPoints ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ExportFusionBundles [ fusionBundle . ItemType ] . fusionPoints  *  fusionBundle . ItemCount 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-23 11:37:10 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                inventoryChanges . FusionPoints  =  fusionPointsDelta ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-07 00:41:18 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "EmailItems" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( const  tc  of  value )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    await  addEmailItem ( inventory ,  tc . ItemType ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-27 18:11:05 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "FocusXpIncreases" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                addFocusXpIncreases ( inventory ,  value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-31 17:03:14 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "PlayerSkillGains" :  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-01 03:12:14 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                inventory . PlayerSkills . LPP_SPACE  +=  value . LPP_SPACE  ? ?  0 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventory . PlayerSkills . LPP_DRIFTER  +=  value . LPP_DRIFTER  ? ?  0 ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-31 17:03:14 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-01 07:41:34 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "CustomMarkers" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                value . forEach ( markers  = >  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  map  =  inventory . CustomMarkers 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ?  inventory . CustomMarkers . find ( entry  = >  entry . tag  ==  markers . tag ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        :  undefined ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( map )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        map . markerInfos  =  markers . markerInfos ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory . CustomMarkers  ? ? =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory . CustomMarkers . push ( markers ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-20 02:57:23 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "LoreFragmentScans" : 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 06:16:19 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                addLoreFragmentScans ( inventory ,  value ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-20 02:57:23 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-25 17:31:52 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "LibraryScans" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                value . forEach ( scan  = >  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-07 00:40:22 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    let  synthesisIgnored  =  true ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-22 09:59:41 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    if  ( inventory . LibraryPersonalTarget )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  taskAvatar  =  libraryPersonalTargetToAvatar [ inventory . LibraryPersonalTarget ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  taskAvatars  =  libraryDailyTasks . find ( x  = >  x . indexOf ( taskAvatar )  !=  - 1 ) ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( taskAvatars . indexOf ( scan . EnemyType )  !=  - 1 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            let  progress  =  inventory . LibraryPersonalProgress . find ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                x  = >  x . TargetType  ==  inventory . LibraryPersonalTarget 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            if  ( ! progress )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                progress  = 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    inventory . LibraryPersonalProgress [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        inventory . LibraryPersonalProgress . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            TargetType : inventory.LibraryPersonalTarget , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            Scans : 0 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            Completed : false 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        } )  -  1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            progress . Scans  +=  scan . Count ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                progress . Scans  >= 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                ( inventory . LibraryPersonalTarget  == 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                "/Lotus/Types/Game/Library/Targets/DragonframeQuestTarget" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    ?  3 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    :  10 ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                progress . Completed  =  true ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-29 12:27:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                inventory . LibraryPersonalTarget  =  undefined ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-22 09:59:41 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            logger . debug ( ` synthesis of  ${ scan . EnemyType }  added to personal target progress ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            synthesisIgnored  =  false ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-07 00:40:22 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory . LibraryActiveDailyTaskInfo  && 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-17 09:17:03 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        inventory . LibraryActiveDailyTaskInfo . EnemyTypes . indexOf ( scan . EnemyType )  !=  - 1 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-07 00:40:22 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory . LibraryActiveDailyTaskInfo . Scans  ? ? =  0 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory . LibraryActiveDailyTaskInfo . Scans  +=  scan . Count ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        logger . debug ( ` synthesis of  ${ scan . EnemyType }  added to daily task progress ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        synthesisIgnored  =  false ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( synthesisIgnored )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        logger . warn ( ` ignoring synthesis of  ${ scan . EnemyType }  due to not knowing why you did that ` ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-25 17:31:52 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-28 18:09:37 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "CollectibleScans" : 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-07 00:41:18 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                for  ( const  scan  of  value )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-28 18:09:37 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    const  entry  =  inventory . CollectibleSeries ? . find ( x  = >  x . CollectibleType  ==  scan . CollectibleType ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( entry )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        entry . Count  =  scan . Count ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        entry . Tracking  =  scan . Tracking ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( entry . CollectibleType  ==  "/Lotus/Objects/Orokin/Props/CollectibleSeriesOne" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            const  progress  =  entry . Count  /  entry . ReqScans ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-07 00:41:18 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            for  ( const  gate  of  entry . IncentiveStates )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-28 18:09:37 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                gate . complete  =  progress  >=  gate . threshold ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                if  ( gate . complete  &&  ! gate . sent )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    gate . sent  =  true ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    if  ( gate . threshold  ==  0.5 )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-31 09:18:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                        await  createMessage ( inventory . accountOwnerId ,  [ kuriaMessage50 ] ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-28 18:09:37 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                    }  else  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-31 09:18:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                        await  createMessage ( inventory . accountOwnerId ,  [ kuriaMessage75 ] ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-28 18:09:37 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-07 00:41:18 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-28 18:09:37 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            if  ( progress  >=  1.0 )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-31 09:18:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                await  createMessage ( inventory . accountOwnerId ,  [ kuriaMessage100 ] ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-28 18:09:37 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        logger . warn ( ` ${ scan . CollectibleType }  was not found in inventory, ignoring scans ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-07 00:41:18 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-28 18:09:37 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-27 18:01:06 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "Upgrades" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                value . forEach ( clientUpgrade  = >  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-09 21:38:42 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    const  id  =  fromOid ( clientUpgrade . ItemId ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( id  ==  "" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        // U19 does not provide RawUpgrades and instead interleaves them with riven progress here
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        addMods ( inventory ,  [ clientUpgrade ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  upgrade  =  inventory . Upgrades . id ( id ) ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        upgrade . UpgradeFingerprint  =  clientUpgrade . UpgradeFingerprint ;  // primitive way to copy over the riven challenge progress
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-27 18:01:06 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-26 11:54:38 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "WeaponSkins" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( const  item  of  value )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    addSkin ( inventory ,  item . ItemType ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-24 01:38:32 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "Boosters" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                value . forEach ( booster  = >  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    addBooster ( booster . ItemType ,  booster . ExpiryDate ,  inventory ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-09 09:39:45 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "SyndicateId" :  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-20 02:48:45 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( ! config . syndicateMissionsRepeatable )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . CompletedSyndicates . push ( value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-09 09:39:45 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "SortieId" :  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-18 11:23:52 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( inventory . CompletedSorties . indexOf ( value )  ==  - 1 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . CompletedSorties . push ( value ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-09 09:39:45 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 20:56:27 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "SeasonChallengeCompletions" :  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-09 09:39:45 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                const  processedCompletions  =  value . map ( ( {  challenge ,  id  } )  = >  ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    challenge : challenge.substring ( challenge . lastIndexOf ( "/" )  +  1 ) , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    id 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } ) ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventory . SeasonChallengeHistory . push ( . . . processedCompletions ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 20:56:27 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-16 04:33:21 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "DeathMarks" :  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-17 08:01:59 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( ! config . noDeathMarks )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    for  ( const  bossName  of  value )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( inventory . DeathMarks . indexOf ( bossName )  ==  - 1 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            // It's a new death mark; we have to say the line.
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            await  createMessage ( inventory . accountOwnerId ,  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    sub : bossName , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    sndr :  "/Lotus/Language/G1Quests/DeathMarkSender" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    msg :  "/Lotus/Language/G1Quests/DeathMarkMessage" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    icon :  "/Lotus/Interface/Icons/Npcs/Stalker_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    highPriority : true , 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-24 11:19:32 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                    endDate : new  Date ( Date . now ( )  +  86400 _000 )  // TOVERIFY: This type of inbox message seems to automatically delete itself. We'll just delete it after 24 hours, but it's not clear if this is correct.
 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-17 08:01:59 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-16 04:33:21 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-17 08:01:59 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    inventory . DeathMarks  =  value ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-16 04:33:21 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-26 16:08:33 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "CapturedAnimals" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( const  capturedAnimal  of  value )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  meta  =  conservationAnimals [ capturedAnimal . AnimalType  as  keyof  typeof  conservationAnimals ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( meta )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( capturedAnimal . NumTags )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            addMiscItems ( inventory ,  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    ItemType : meta.tag , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    ItemCount : capturedAnimal.NumTags 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( capturedAnimal . NumExtraRewards )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            if  ( "extraReward"  in  meta )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                addMiscItems ( inventory ,  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        ItemType : meta.extraReward , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        ItemCount : capturedAnimal.NumExtraRewards 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                logger . warn ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    ` client attempted to claim unknown extra rewards for conservation of  ${ capturedAnimal . AnimalType } ` 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        logger . warn ( ` ignoring conservation of unknown AnimalType:  ${ capturedAnimal . AnimalType } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-27 12:36:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "KubrowPetEggs" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( const  egg  of  value )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . KubrowPetEggs . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ItemType : egg.ItemType , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        _id : new  Types . ObjectId ( ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-27 03:32:50 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "DiscoveredMarkers" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( const  clientMarker  of  value )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  dbMarker  =  inventory . DiscoveredMarkers . find ( x  = >  x . tag  ==  clientMarker . tag ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( dbMarker )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        dbMarker . discoveryState  =  clientMarker . discoveryState ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory . DiscoveredMarkers . push ( clientMarker ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-30 13:27:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "BrandedSuits" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventory . BrandedSuits  ? ? =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( ! inventory . BrandedSuits . find ( x  = >  x . equals ( value . $oid ) ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . BrandedSuits . push ( new  Types . ObjectId ( value . $oid ) ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    await  createMessage ( inventory . accountOwnerId ,  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            sndr :  "/Lotus/Language/Menu/Mailbox_WarframeSender" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            msg :  "/Lotus/Language/G1Quests/BrandedMessage" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            sub :  "/Lotus/Language/G1Quests/BrandedTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            att :  [ "/Lotus/Types/Recipes/Components/BrandRemovalBlueprint" ] , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            highPriority : true  // TOVERIFY: I cannot find any content of this within the last 10 years so I can only assume that highPriority is set (it certainly would make sense), but I just don't know for sure that it is so on live.
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-09 19:58:01 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                inventory . DeathSquadable  =  false ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-30 13:27:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-01 02:29:29 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "LockedWeaponGroup" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventory . LockedWeaponGroup  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    s : new  Types . ObjectId ( value . s . $oid ) , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    l : value.l  ?  new  Types . ObjectId ( value . l . $oid )  :  undefined , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    p : value.p  ?  new  Types . ObjectId ( value . p . $oid )  :  undefined , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    m : value.m  ?  new  Types . ObjectId ( value . m . $oid )  :  undefined , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    sn : value.sn  ?  new  Types . ObjectId ( value . sn . $oid )  :  undefined 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-30 13:27:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                inventory . Harvestable  =  false ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-01 02:29:29 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            case  "UnlockWeapons" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventory . LockedWeaponGroup  =  undefined ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-30 13:27:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "IncHarvester" :  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-09 19:58:01 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                // Unsure what to do with this
 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-30 13:27:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-01 02:29:29 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "CurrentLoadOutIds" :  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-01 15:48:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( value . LoadOuts )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  loadout  =  await  Loadout . findOne ( {  loadoutOwnerId : inventory.accountOwnerId  } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( loadout )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        for  ( const  [ loadoutId ,  loadoutConfig ]  of  Object . entries ( value . LoadOuts . NORMAL ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            const  {  ItemId ,  . . . loadoutConfigItemIdRemoved  }  =  loadoutConfig ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            const  loadoutConfigDatabase : ILoadoutConfigDatabase  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                _id : new  Types . ObjectId ( ItemId . $oid ) , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                . . . loadoutConfigItemIdRemoved 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-06 10:18:01 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            const  dbConfig  =  loadout . NORMAL . id ( loadoutId ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            if  ( dbConfig )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                dbConfig . overwrite ( loadoutConfigDatabase ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                logger . warn ( ` couldn't update loadout because there's no config with id  ${ loadoutId } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-01 15:48:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        await  loadout . save ( ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-01 02:29:29 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-03 06:17:11 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "creditsFee" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                updateCurrency ( inventory ,  value ,  false ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventoryChanges . RegularCredits  ? ? =  0 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventoryChanges . RegularCredits  -=  value ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "GoalProgress" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( const  uploadProgress  of  value )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  goal  =  getWorldState ( ) . Goals . find ( x  = >  x . _id . $oid  ==  uploadProgress . _id . $oid ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( goal  &&  goal . Personal )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory . PersonalGoalProgress  ? ? =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  goalProgress  =  inventory . PersonalGoalProgress . find ( x  = >  x . goalId . equals ( goal . _id . $oid ) ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        if  ( ! goalProgress )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            inventory . PersonalGoalProgress . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                Best : uploadProgress.Best , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                Count : uploadProgress.Count , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                Tag : goal.Tag , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                goalId : new  Types . ObjectId ( goal . _id . $oid ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        const  currentNode  =  inventoryUpdates . RewardInfo ! . node ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        let  currentMissionKey : string  |  undefined ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        if  ( currentNode  ==  goal . Node )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            currentMissionKey  =  goal . MissionKeyName ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        }  else  if  ( goal . ConcurrentNodes  &&  goal . ConcurrentMissionKeyNames )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            for  ( let  i  =  0 ;  i  <  goal . ConcurrentNodes . length ;  i ++ )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                if  ( currentNode  ==  goal . ConcurrentNodes [ i ] )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    currentMissionKey  =  goal . ConcurrentMissionKeyNames [ i ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        const  rewards  =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        let  countBeforeUpload  =  goalProgress ? . Count  ? ?  0 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        let  totalCount  =  countBeforeUpload  +  uploadProgress . Count ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( goal . Best )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            countBeforeUpload  =  goalProgress ? . Best  ? ?  0 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            totalCount  =  uploadProgress . Best ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        { 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            if  ( goal . InterimGoals  &&  goal . InterimRewards )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                for  ( let  i  =  0 ;  i  <  goal . InterimGoals . length ;  i ++ )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        goal . InterimGoals [ i ]  && 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        goal . InterimGoals [ i ]  <=  totalCount  && 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-16 09:52:58 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                        ( ! goalProgress  ||  countBeforeUpload  <  goal . InterimGoals [ i ] )  && 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                        goal . InterimRewards [ i ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                        rewards . push ( goal . InterimRewards [ i ] ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                        break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            if  ( 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                goal . Goal  && 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                goal . Goal  <=  totalCount  && 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-16 09:52:58 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                ( ! goalProgress  ||  countBeforeUpload  <  goal . Goal )  && 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                goal . Reward 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                rewards . push ( goal . Reward ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                goal . BonusGoal  && 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                goal . BonusGoal  <=  totalCount  && 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-16 09:52:58 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                ( ! goalProgress  ||  countBeforeUpload  <  goal . BonusGoal )  && 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                goal . BonusReward 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                rewards . push ( goal . BonusReward ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        const  messages : IMessageCreationTemplate [ ]  =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  infos :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            sndr : string ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            msg : string ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            sub : string ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            icon : string ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            arg? : string [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } [ ]  =  [ ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-17 13:11:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            if  ( currentMissionKey  &&  currentMissionKey  in  goalMessagesByKey )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                infos . push ( goalMessagesByKey [ currentMissionKey ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            }  else  if  ( goal . Tag  in  goalMessagesByTag )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                const  combinedGoals  =  [ . . . ( goal . InterimGoals  ||  [ ] ) ,  goal . Goal ,  goal . BonusGoal ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                combinedGoals . forEach ( ( n ,  i )  = >  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    if  ( n  !==  undefined  &&  n  >  countBeforeUpload  &&  n  <=  totalCount )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        infos . push ( goalMessagesByTag [ goal . Tag ] [ i ] ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-17 13:11:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        for  ( let  i  =  0 ;  i  <  rewards . length ;  i ++ )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            if  ( infos [ i ] )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                const  info  =  infos [ i ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                const  reward  =  rewards [ i ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                const  message : IMessageCreationTemplate  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    sndr : info.sndr , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    msg : info.msg , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    sub : info.sub , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    icon : info.icon , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    highPriority : true 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                if  ( reward . items )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    message . att  =  reward . items . map ( x  = >  ( isStoreItem ( x )  ?  fromStoreItem ( x )  :  x ) ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                if  ( reward . countedItems )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    message . countedAtt  =  reward . countedItems ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                if  ( reward . credits )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    message . RegularCredits  =  reward . credits ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                if  ( info . arg )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    const  args : Record < string ,  string  |  number >  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        PLAYER_NAME : account.DisplayName , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        CREDIT_REWARD : reward.credits  ? ?  0 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    } ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    for  ( let  j  =  0 ;  j  <  info . arg . length ;  j ++ )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        const  key  =  info . arg [ j ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        const  value  =  args [ key ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        if  ( value )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            message . arg  ? ? =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            message . arg . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                                Key : key , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                                Tag : value 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                messages . push ( message ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        if  ( messages . length  >  0 )  await  createMessage ( inventory . accountOwnerId ,  messages ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        if  ( goalProgress )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-15 08:14:36 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            goalProgress . Best  =  Math . max ( goalProgress . Best ! ,  uploadProgress . Best ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            goalProgress . Count  +=  uploadProgress . Count ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-15 08:14:36 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    if  ( goal  &&  goal . ClanGoal  &&  inventory . GuildId )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  guild  =  await  Guild . findById ( inventory . GuildId ,  "GoalProgress Tier VaultDecoRecipes" ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( guild )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            await  handleGuildGoalProgress ( guild ,  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                Count : uploadProgress.Count , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                Tag : goal.Tag , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                goalId : new  Types . ObjectId ( goal . _id . $oid ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-18 11:27:29 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "InvasionProgress" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( const  clientProgress  of  value )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  dbProgress  =  inventory . QualifyingInvasions . find ( x  = > 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        x . invasionId . equals ( clientProgress . _id . $oid ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( dbProgress )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        dbProgress . Delta  +=  clientProgress . Delta ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        dbProgress . AttackerScore  +=  clientProgress . AttackerScore ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        dbProgress . DefenderScore  +=  clientProgress . DefenderScore ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory . QualifyingInvasions . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            invasionId : new  Types . ObjectId ( clientProgress . _id . $oid ) , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            Delta : clientProgress.Delta , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            AttackerScore : clientProgress.AttackerScore , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            DefenderScore : clientProgress.DefenderScore 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-25 11:53:34 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "CalendarProgress" :  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 00:41:15 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                addCalendarProgress ( inventory ,  value ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-25 11:53:34 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-25 11:56:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "duviriCaveOffers" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                // Duviri cave offers (generated with the duviri seed) change after completing one of its game modes (not when aborting).
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( inventoryUpdates . MissionStatus  !=  "GS_QUIT" )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-30 13:28:01 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    inventory . DuviriInfo ! . Seed  =  generateRewardSeed ( ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-25 11:56:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-27 12:38:48 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            case  "NemesisKillConvert" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( inventory . Nemesis )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . NemesisHistory  ? ? =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . NemesisHistory . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        // Copy over all 'base' values
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        fp : inventory.Nemesis.fp , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        d : inventory.Nemesis.d , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        manifest : inventory.Nemesis.manifest , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        KillingSuit : inventory.Nemesis.KillingSuit , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        killingDamageType : inventory.Nemesis.killingDamageType , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ShoulderHelmet : inventory.Nemesis.ShoulderHelmet , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        WeaponIdx : inventory.Nemesis.WeaponIdx , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        AgentIdx : inventory.Nemesis.AgentIdx , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        BirthNode : inventory.Nemesis.BirthNode , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        Faction : inventory.Nemesis.Faction , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        Rank : inventory.Nemesis.Rank , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        Traded : inventory.Nemesis.Traded , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        PrevOwners : inventory.Nemesis.PrevOwners , 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 08:25:09 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        SecondInCommand : false , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-27 12:38:48 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        Weakened : inventory.Nemesis.Weakened , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        // And set killed flag
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        k : value.killed 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-05-17 23:29:23 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    const  manifest  =  getNemesisManifest ( inventory . Nemesis . manifest ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:41:49 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    const  profile  =  generateNemesisProfile ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory . Nemesis . fp , 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-17 23:29:23 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        manifest , 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:41:49 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        inventory . Nemesis . KillingSuit 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-14 21:14:04 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    const  att : string [ ]  =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    let  countedAtt : ITypeCount [ ]  |  undefined ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:41:49 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-27 12:38:48 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    if  ( value . killed )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-28 14:00:38 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            value . weaponLoc  && 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            inventory . Nemesis . Faction  !=  "FC_INFESTATION"  // weaponLoc is "/Lotus/Language/Weapons/DerelictCernosName" for these for some reason
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-17 23:29:23 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            const  weaponType  =  manifest . weapons [ inventory . Nemesis . WeaponIdx ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:41:49 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            giveNemesisWeaponRecipe ( inventory ,  weaponType ,  value . nemesisName ,  value . weaponLoc ,  profile ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-14 21:14:04 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            att . push ( weaponType ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-27 12:38:48 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-14 21:14:04 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        //if (value.petLoc) {
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( profile . petHead )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:41:49 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            giveNemesisPetRecipe ( inventory ,  value . nemesisName ,  profile ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-14 21:14:04 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            att . push ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    "/Lotus/Types/Friendly/Pets/ZanukaPets/ZanukaPetParts/ZanukaPetPartHeadA" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        "/Lotus/Types/Recipes/ZanukaPet/ZanukaPetCompleteHeadABlueprint" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    "/Lotus/Types/Friendly/Pets/ZanukaPets/ZanukaPetParts/ZanukaPetPartHeadB" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        "/Lotus/Types/Recipes/ZanukaPet/ZanukaPetCompleteHeadBBlueprint" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    "/Lotus/Types/Friendly/Pets/ZanukaPets/ZanukaPetParts/ZanukaPetPartHeadC" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        "/Lotus/Types/Recipes/ZanukaPet/ZanukaPetCompleteHeadCBlueprint" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } [ profile . petHead ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-27 12:38:48 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:41:49 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    // "Players will receive a Lich's Ephemera regardless of whether they Vanquish or Convert them."
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( profile . ephemera )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        addSkin ( inventory ,  profile . ephemera ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-14 21:14:04 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        att . push ( profile . ephemera ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:41:49 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-05-17 23:29:23 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    const  skinRewardStoreItem  =  value . killed  ?  manifest.firstKillReward  : manifest.firstConvertReward ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-14 21:14:04 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    if  ( Object . keys ( addSkin ( inventory ,  fromStoreItem ( skinRewardStoreItem ) ) ) . length  !=  0 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        att . push ( skinRewardStoreItem ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 22:28:59 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-05-14 21:14:04 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    if  ( inventory . Nemesis . Faction  ==  "FC_INFESTATION" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  [ rotARewardStoreItem ,  rotBRewardStoreItem ]  =  getInfestedLichItemRewards ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            inventory . Nemesis . fp 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  rotAReward  =  fromStoreItem ( rotARewardStoreItem ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  rotBReward  =  fromStoreItem ( rotBRewardStoreItem ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        await  addItem ( inventory ,  rotAReward ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        await  addItem ( inventory ,  rotBReward ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        att . push ( rotAReward ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        att . push ( rotBReward ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 22:28:59 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-05-14 21:14:04 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        if  ( value . killed )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            countedAtt  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    ItemType :  "/Lotus/Types/Items/MiscItems/CodaWeaponBucks" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    ItemCount : getKillTokenRewardCount ( inventory . Nemesis . fp ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            addMiscItems ( inventory ,  countedAtt ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-14 07:56:29 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    await  createMessage ( inventory . accountOwnerId ,  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            sndr : value.killed  ?  "/Lotus/Language/Bosses/Ordis"  :  value . nemesisName , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            msg : value.killed  ?  manifest.killMessageBody  : manifest.convertMessageBody , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            arg :  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    Key :  "LICH_NAME" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    Tag : value.nemesisName 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            ] , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            att : att , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            countedAtt : countedAtt , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            attVisualOnly : true , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            sub : value.killed  ?  manifest.killMessageSubject  : manifest.convertMessageSubject , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            icon : value.killed  ?  "/Lotus/Interface/Icons/Npcs/Ordis.png"  :  manifest . convertMessageIcon , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            highPriority : true 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ] ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-28 14:00:38 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-27 12:38:48 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    inventory . Nemesis  =  undefined ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            default : 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-27 13:18:16 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( equipmentKeys . includes ( key  as  TEquipmentKey ) )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-30 13:28:16 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    applyClientEquipmentUpdates ( inventory ,  value  as  IEquipmentClient [ ] ,  key  as  TEquipmentKey ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-27 13:18:16 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                break ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            // if (
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            //     (ignoredInventoryUpdateKeys as readonly string[]).includes(key) ||
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            //     knownUnhandledKeys.includes(key)
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // ) {
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            //     continue;
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // }
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // logger.error(`Unhandled inventory update key: ${key}`);
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    return  inventoryChanges ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-03-15 03:24:39 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								interface  AddMissionRewardsReturnType  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    MissionRewards : IMissionReward [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    inventoryChanges? : IInventoryChanges ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    credits? : IMissionCredits ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    AffiliationMods? : IAffiliationMods [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    SyndicateXPItemReward? : number ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-23 11:35:57 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    ConquestCompletedMissionsCount? : number ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-15 03:24:39 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								} 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-23 11:35:57 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								interface  IConquestReward  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    at : number ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    pool : IRngResult [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								const  labConquestRewards : IConquestReward [ ]  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 5 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool : ExportRewards [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            "/Lotus/Types/Game/MissionDecks/EntratiLabConquestRewards/EntratiLabConquestSilverRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] [ 0 ]  as  IRngResult [ ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 10 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool : ExportRewards [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            "/Lotus/Types/Game/MissionDecks/EntratiLabConquestRewards/EntratiLabConquestSilverRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] [ 0 ]  as  IRngResult [ ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 15 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool :  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                type :  "/Lotus/StoreItems/Types/Gameplay/EntratiLab/Resources/EntratiLanthornBundle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                itemCount : 3 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                probability : 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 20 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool : ExportRewards [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            "/Lotus/Types/Game/MissionDecks/EntratiLabConquestRewards/EntratiLabConquestGoldRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] [ 0 ]  as  IRngResult [ ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 28 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool :  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                type :  "/Lotus/StoreItems/Types/Items/MiscItems/DistillPoints" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                itemCount : 20 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                probability : 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 31 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool : ExportRewards [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            "/Lotus/Types/Game/MissionDecks/EntratiLabConquestRewards/EntratiLabConquestGoldRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] [ 0 ]  as  IRngResult [ ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 34 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool : ExportRewards [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            "/Lotus/Types/Game/MissionDecks/EntratiLabConquestRewards/EntratiLabConquestArcaneRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] [ 0 ]  as  IRngResult [ ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 37 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool :  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                type :  "/Lotus/StoreItems/Types/Items/MiscItems/DistillPoints" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                itemCount : 50 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                probability : 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								const  hexConquestRewards : IConquestReward [ ]  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 5 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool : ExportRewards [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            "/Lotus/Types/Game/MissionDecks/1999ConquestRewards/1999ConquestSilverRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] [ 0 ]  as  IRngResult [ ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 10 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool : ExportRewards [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            "/Lotus/Types/Game/MissionDecks/1999ConquestRewards/1999ConquestSilverRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] [ 0 ]  as  IRngResult [ ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 15 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool :  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                type :  "/Lotus/StoreItems/Types/BoosterPacks/1999StickersPackEchoesArchimedea" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                itemCount : 1 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                probability : 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 20 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool : ExportRewards [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            "/Lotus/Types/Game/MissionDecks/1999ConquestRewards/1999ConquestGoldRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] [ 0 ]  as  IRngResult [ ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 28 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool :  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                type :  "/Lotus/StoreItems/Types/Items/MiscItems/1999ConquestBucks" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                itemCount : 6 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                probability : 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 31 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool : ExportRewards [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            "/Lotus/Types/Game/MissionDecks/1999ConquestRewards/1999ConquestGoldRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] [ 0 ]  as  IRngResult [ ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 34 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool : ExportRewards [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            "/Lotus/Types/Game/MissionDecks/1999ConquestRewards/1999ConquestArcaneRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] [ 0 ]  as  IRngResult [ ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        at : 37 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        pool :  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                type :  "/Lotus/StoreItems/Types/Items/MiscItems/1999ConquestBucks" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                itemCount : 9 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                probability : 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-05-11 21:53:16 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								const  droptableAliases : Record < string ,  string >  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/DropTables/ManInTheWall/MITWGruzzlingArcanesDropTable" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/DropTables/EntratiLabDropTables/DoppelgangerDropTable" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/DropTables/WF1999DropTables/LasrianTankSteelPathDropTable" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/DropTables/WF1999DropTables/LasrianTankHardModeDropTable" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-22 11:45:39 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								const  isEligibleForCreditReward  =  ( rewardInfo : IRewardInfo ,  missions : IMission ,  node : IRegion ) :  boolean  = >  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    // (E)SO should not give credits for only completing zone 1, in which case it has no rewardQualifications (https://onlyg.it/OpenWF/SpaceNinjaServer/issues/1823)
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( getRotations ( rewardInfo ) . length  ==  0 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        return  missions . Tag  ==  "SolNode720" ;  // Netracells don't use rewardQualifications but probably should give credits anyway
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    // The rest here might not be needed anymore, but just to be sure we don't give undue credits...
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    return  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        node . missionIndex  !=  23  &&  // junction
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        node . missionIndex  !=  28  &&  // open world
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        missions . Tag  !=  "SolNode761"  &&  // the index
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        missions . Tag  !=  "SolNode762"  &&  // the index
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        missions . Tag  !=  "SolNode763"  &&  // the index
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        missions . Tag  !=  "CrewBattleNode556"  // free flight
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								//TODO: return type of partial missioninventoryupdate response
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								export  const  addMissionRewards  =  async  ( 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:20:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    account : TAccountDocument , 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    inventory : TInventoryDatabaseDocument , 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-06 07:11:31 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-10 12:54:29 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        wagerTier : wagerTier , 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-22 06:08:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        Nemesis : nemesis , 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-06 07:11:31 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        RewardInfo : rewardInfo , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        LevelKeyName : levelKeyName , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        Missions : missions , 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-25 04:38:47 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        RegularCredits : creditDrops , 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-09 07:42:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        VoidTearParticipantsCurrWave : voidTearWave , 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-29 00:31:48 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        StrippedItems : strippedItems , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        AffiliationChanges : AffiliationMods 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-18 11:23:52 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } :  IMissionInventoryUpdateRequest , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    firstCompletion : boolean 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-15 03:24:39 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								) :  Promise < AddMissionRewardsReturnType >  = >  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( ! rewardInfo )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-06 07:11:31 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        //TODO: if there is a case where you can have credits collected during a mission but no rewardInfo, add credits needs to be handled earlier
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        logger . debug ( ` Mission  ${ missions ! . Tag }  did not have Reward Info  ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        return  {  MissionRewards :  [ ]  } ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    //TODO: check double reward merging
 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-09 21:38:13 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    const  MissionRewards : IMissionReward [ ]  =  getRandomMissionDrops ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        inventory , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        rewardInfo , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        missions , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        wagerTier , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        firstCompletion 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-07 04:53:26 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    logger . debug ( "random mission drops:" ,  MissionRewards ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    const  inventoryChanges : IInventoryChanges  =  { } ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    let  SyndicateXPItemReward ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-23 11:35:57 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    let  ConquestCompletedMissionsCount ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    let  missionCompletionCredits  =  0 ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-06 07:11:31 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    //inventory change is what the client has not rewarded itself, also the client needs to know the credit changes for display
 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( rewardInfo . goalId )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        const  goal  =  getWorldState ( ) . Goals . find ( x  = >  x . _id . $oid  ==  rewardInfo . goalId ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( goal )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( rewardInfo . node  ==  goal . Node  &&  goal . MissionKeyName )  levelKeyName  =  goal . MissionKeyName ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( goal . ConcurrentNodes  &&  goal . ConcurrentMissionKeyNames )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( let  i  =  0 ;  i  <  goal . ConcurrentNodes . length  &&  i  <  goal . ConcurrentMissionKeyNames . length ;  i ++ )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( rewardInfo . node  ==  goal . ConcurrentNodes [ i ] )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        levelKeyName  =  goal . ConcurrentMissionKeyNames [ i ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-16 09:52:58 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( rewardInfo . GoalProgressAmount  &&  goal . Tag . startsWith ( "MechSurvival" ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                MissionRewards . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    StoreItem :  "/Lotus/StoreItems/Types/Items/MiscItems/MechSurvivalEventCreds" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ItemCount : Math.trunc ( rewardInfo . GoalProgressAmount  /  10 ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( levelKeyName )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        const  fixedLevelRewards  =  getLevelKeyRewards ( levelKeyName ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        //logger.debug(`fixedLevelRewards ${fixedLevelRewards}`);
 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( fixedLevelRewards . levelKeyRewards )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:20:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            missionCompletionCredits  +=  addFixedLevelRewards ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                fixedLevelRewards . levelKeyRewards , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                MissionRewards , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                rewardInfo 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( fixedLevelRewards . levelKeyRewards2 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            for  ( const  reward  of  fixedLevelRewards . levelKeyRewards2 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                //quest stage completion credit rewards
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( reward . rewardType  ==  "RT_CREDITS" )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:20:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    missionCompletionCredits  +=  reward . amount ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    continue ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                MissionRewards . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    StoreItem : reward.itemType , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ItemCount : reward.rewardType  ===  "RT_RESOURCE"  ?  reward.amount  : 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-03-31 04:15:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    // ignoring tags not in ExportRegions, because it can just be garbage:
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    // - https://onlyg.it/OpenWF/SpaceNinjaServer/issues/1013
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    // - https://onlyg.it/OpenWF/SpaceNinjaServer/issues/1365
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( missions  &&  missions . Tag  in  ExportRegions )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        const  node  =  ExportRegions [ missions . Tag ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        //node based credit rewards for mission completion
 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-22 11:45:39 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( isEligibleForCreditReward ( rewardInfo ,  missions ,  node ) )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-31 04:15:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            const  levelCreditReward  =  getLevelCreditRewards ( node ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            missionCompletionCredits  +=  levelCreditReward ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            logger . debug ( ` levelCreditReward  ${ levelCreditReward } ` ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-21 06:32:05 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( node . missionReward )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:20:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            missionCompletionCredits  +=  addFixedLevelRewards ( node . missionReward ,  MissionRewards ,  rewardInfo ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-21 06:32:05 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-16 06:30:06 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-25 11:52:42 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( rewardInfo . sortieTag  ==  "Mission1" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            missionCompletionCredits  +=  20 _000 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        }  else  if  ( rewardInfo . sortieTag  ==  "Mission2" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            missionCompletionCredits  +=  30 _000 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        }  else  if  ( rewardInfo . sortieTag  ==  "Final" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            missionCompletionCredits  +=  50 _000 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-16 06:30:06 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( missions . Tag  ==  "PlutoToErisJunction" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            await  createMessage ( inventory . accountOwnerId ,  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    sndr :  "/Lotus/Language/G1Quests/GolemQuestJordasName" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    msg :  "/Lotus/Language/G1Quests/GolemQuestIntroBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    att :  [ "/Lotus/Types/Keys/GolemQuest/GolemQuestKeyChainItem" ] , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    sub :  "/Lotus/Language/G1Quests/GolemQuestIntroTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    icon :  "/Lotus/Interface/Icons/Npcs/JordasPortrait.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    highPriority : true 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-22 11:45:39 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        // Consume netracells search pulse. Moved here to only cover successful completions. Discussed in https://onlyg.it/OpenWF/SpaceNinjaServer/issues/2673
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( missions . Tag  ==  "SolNode720" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            updateEntratiVault ( inventory ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            inventory . EntratiVaultCountLastPeriod !  +=  1 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-21 06:32:05 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-02-28 12:36:01 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( rewardInfo . useVaultManifest )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        MissionRewards . push ( { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-29 12:27:25 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            StoreItem : getRandomElement ( corruptedMods ) ! , 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-28 12:36:01 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            ItemCount : 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-05-08 08:21:19 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( rewardInfo . periodicMissionTag  ==  "EliteAlert"  ||  rewardInfo . periodicMissionTag  ==  "EliteAlertB" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        missionCompletionCredits  +=  50 _000 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        MissionRewards . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            StoreItem :  "/Lotus/StoreItems/Types/Items/MiscItems/Elitium" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ItemCount : 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-23 11:35:57 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( rewardInfo . ConquestCompleted  !==  undefined )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        let  score  =  1 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( rewardInfo . ConquestHardModeActive  ===  1 )  score  +=  3 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( rewardInfo . ConquestPersonalModifiersActive  !==  undefined ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            score  +=  rewardInfo . ConquestPersonalModifiersActive ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( rewardInfo . ConquestEquipmentSuggestionsFulfilled  !==  undefined ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            score  +=  rewardInfo . ConquestEquipmentSuggestionsFulfilled ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        score  *=  rewardInfo . ConquestCompleted  +  1 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( rewardInfo . ConquestCompleted  ==  2  &&  rewardInfo . ConquestHardModeActive  ===  1 )  score  +=  1 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        logger . debug ( ` completed conquest mission  ${ rewardInfo . ConquestCompleted  +  1 }  for a score of  ${ score } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        const  conquestType  =  rewardInfo . ConquestType ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        const  conquestNode  = 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            conquestType  ==  "HexConquest"  ?  "EchoesHexConquestHardModeUnlocked"  :  "EntratiLabConquestHardModeUnlocked" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( score  >=  25  &&  inventory . NodeIntrosCompleted . indexOf ( conquestNode )  ==  - 1 ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            inventory . NodeIntrosCompleted . push ( conquestNode ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( conquestType  ==  "HexConquest" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            inventory . EchoesHexConquestCacheScoreMission  ? ? =  0 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( score  >  inventory . EchoesHexConquestCacheScoreMission )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( const  reward  of  hexConquestRewards )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( score  >=  reward . at  &&  inventory . EchoesHexConquestCacheScoreMission  <  reward . at )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  rolled  =  getRandomReward ( reward . pool ) ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        logger . debug ( ` rolled hex conquest reward for reaching  ${ reward . at }  points ` ,  rolled ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        MissionRewards . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            StoreItem : rolled.type , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            ItemCount : rolled.itemCount 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventory . EchoesHexConquestCacheScoreMission  =  score ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            inventory . EntratiLabConquestCacheScoreMission  ? ? =  0 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( score  >  inventory . EntratiLabConquestCacheScoreMission )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( const  reward  of  labConquestRewards )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( score  >=  reward . at  &&  inventory . EntratiLabConquestCacheScoreMission  <  reward . at )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  rolled  =  getRandomReward ( reward . pool ) ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        logger . debug ( ` rolled lab conquest reward for reaching  ${ reward . at }  points ` ,  rolled ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        MissionRewards . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            StoreItem : rolled.type , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            ItemCount : rolled.itemCount 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventory . EntratiLabConquestCacheScoreMission  =  score ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ConquestCompletedMissionsCount  =  rewardInfo . ConquestCompleted  ==  2  ?  0  : rewardInfo.ConquestCompleted  +  1 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-02-06 07:11:31 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    for  ( const  reward  of  MissionRewards )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-03 10:37:52 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        const  inventoryChange  =  await  handleStoreItemAcquisition ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            reward . StoreItem , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            inventory , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            reward . ItemCount , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            undefined , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            true 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-06 07:11:31 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        //TODO: combineInventoryChanges improve type safety, merging 2 of the same item?
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        //TODO: check for the case when two of the same item are added, combineInventoryChanges should merge them, but the client also merges them
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        //TODO: some conditional types to rule out binchanges?
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        combineInventoryChanges ( inventoryChanges ,  inventoryChange . InventoryChanges ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:20:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    inventory . RegularCredits  +=  missionCompletionCredits ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    const  credits  =  await  addCredits ( account ,  inventory ,  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-06 07:11:31 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        missionCompletionCredits , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        missionDropCredits : creditDrops  ? ?  0 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        rngRewardCredits : inventoryChanges.RegularCredits  ? ?  0 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-02-25 04:38:47 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        voidTearWave  && 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        voidTearWave . Participants [ 0 ] . QualifiesForReward  && 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ! voidTearWave . Participants [ 0 ] . HaveRewardResponse 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-09 07:43:30 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        const  reward  =  await  crackRelic ( inventory ,  voidTearWave . Participants [ 0 ] ,  inventoryChanges ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-26 15:42:13 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        MissionRewards . push ( {  StoreItem : reward.type ,  ItemCount : reward.itemCount  } ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-25 04:38:47 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-03-09 07:42:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( strippedItems )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        for  ( const  si  of  strippedItems )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-11 21:53:16 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( si . DropTable  in  droptableAliases )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                logger . debug ( ` rewriting  ${ si . DropTable }  to  ${ droptableAliases [ si . DropTable ] } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                si . DropTable  =  droptableAliases [ si . DropTable ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-18 11:16:58 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-10 12:40:57 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            const  droptables  =  ExportEnemies . droptables [ si . DropTable ]  ? ?  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( si . DROP_MOD )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  modDroptable  =  droptables . find ( x  = >  x . type  ==  "mod" ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( modDroptable )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-08 03:06:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    for  ( let  i  =  0 ;  i  !=  si . DROP_MOD . length ;  ++ i )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-10 12:40:57 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        const  reward  =  getRandomReward ( modDroptable . items ) ! ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-08 03:06:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        logger . debug ( ` stripped droptable (mods pool) rolled ` ,  reward ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        await  addItem ( inventory ,  reward . type ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        MissionRewards . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            StoreItem : toStoreItem ( reward . type ) , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            ItemCount : 1 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            FromEnemyCache : true  // to show "identified"
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-10 12:40:57 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    logger . error ( ` unknown droptable  ${ si . DropTable }  for DROP_MOD ` ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-08 03:06:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-10 12:40:57 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( si . DROP_BLUEPRINT )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  blueprintDroptable  =  droptables . find ( x  = >  x . type  ==  "blueprint" ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( blueprintDroptable )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-08 03:06:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    for  ( let  i  =  0 ;  i  !=  si . DROP_BLUEPRINT . length ;  ++ i )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-10 12:40:57 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        const  reward  =  getRandomReward ( blueprintDroptable . items ) ! ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-08 03:06:47 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        logger . debug ( ` stripped droptable (blueprints pool) rolled ` ,  reward ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-09 07:42:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        await  addItem ( inventory ,  reward . type ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        MissionRewards . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            StoreItem : toStoreItem ( reward . type ) , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            ItemCount : 1 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            FromEnemyCache : true  // to show "identified"
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-10 12:40:57 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    logger . error ( ` unknown droptable  ${ si . DropTable }  for DROP_BLUEPRINT ` ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-09 07:42:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-16 05:38:48 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            // e.g. H-09 Apex Turret Sumdali
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( si . DROP_MISC_ITEM )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  resourceDroptable  =  droptables . find ( x  = >  x . type  ==  "resource" ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( resourceDroptable )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    for  ( let  i  =  0 ;  i  !=  si . DROP_MISC_ITEM . length ;  ++ i )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  reward  =  getRandomReward ( resourceDroptable . items ) ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        logger . debug ( ` stripped droptable (resources pool) rolled ` ,  reward ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( Object . keys ( await  addItem ( inventory ,  reward . type ) ) . length  ==  0 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            logger . debug ( ` item already owned, skipping ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            MissionRewards . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                StoreItem : toStoreItem ( reward . type ) , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                ItemCount : 1 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                FromEnemyCache : true  // to show "identified"
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                }  else  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 20:58:57 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    logger . error ( ` unknown droptable  ${ si . DropTable }  for DROP_MISC_ITEM ` ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-16 05:38:48 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-09 07:42:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-03-22 06:08:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( inventory . Nemesis )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            nemesis  || 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ( inventory . Nemesis . Faction  ==  "FC_INFESTATION"  && 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventory . Nemesis . InfNodes . find ( obj  = >  obj . Node  ==  rewardInfo . node ) ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            inventoryChanges . Nemesis  ? ? =  { } ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  nodeIndex  =  inventory . Nemesis . InfNodes . findIndex ( obj  = >  obj . Node  ===  rewardInfo . node ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( nodeIndex  !==  - 1 )  inventory . Nemesis . InfNodes . splice ( nodeIndex ,  1 ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( inventory . Nemesis . InfNodes . length  <=  0 )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-07 16:46:18 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                const  manifest  =  getNemesisManifest ( inventory . Nemesis . manifest ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-22 06:08:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( inventory . Nemesis . Faction  !=  "FC_INFESTATION" )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-07 16:46:18 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    inventory . Nemesis . Rank  =  Math . min ( inventory . Nemesis . Rank  +  1 ,  manifest . systemIndexes . length  -  1 ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-22 06:08:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    inventoryChanges . Nemesis . Rank  =  inventory . Nemesis . Rank ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-07 16:46:18 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                inventory . Nemesis . InfNodes  =  getInfNodes ( manifest ,  inventory . Nemesis . Rank ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-22 06:08:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( inventory . Nemesis . Faction  ==  "FC_INFESTATION" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                inventory . Nemesis . MissionCount  +=  1 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:50:51 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                inventoryChanges . Nemesis . MissionCount  ? ? =  0 ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-22 06:08:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                inventoryChanges . Nemesis . MissionCount  +=  1 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            inventoryChanges . Nemesis . InfNodes  =  inventory . Nemesis . InfNodes ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-11 08:08:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    AffiliationMods  ? ? =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( rewardInfo . JobStage  !=  undefined  &&  rewardInfo . jobId )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        // eslint-disable-next-line @typescript-eslint/no-unused-vars
 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-24 19:05:19 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        const  [ jobType ,  unkIndex ,  hubNode ,  syndicateMissionId ]  =  rewardInfo . jobId . split ( "_" ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-06 19:05:23 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        const  syndicateMissions : ISyndicateMissionInfo [ ]  =  [ ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-03 10:40:28 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( syndicateMissionId )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            pushClassicBounties ( syndicateMissions ,  idToBountyCycle ( syndicateMissionId ) ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-11 08:08:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        let  syndicateEntry : ISyndicateMissionInfo  |  IGoal  |  undefined  =  syndicateMissions . find ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            m  = >  m . _id . $oid  ===  syndicateMissionId 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                "/Lotus/Types/Gameplay/Eidolon/Jobs/Events/InfestedPlainsBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                "/Lotus/Types/Gameplay/Eidolon/Jobs/Events/GhoulAlertBounty" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ] . some ( prefix  = >  jobType . startsWith ( prefix ) ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  {  Goals  }  =  getWorldState ( undefined ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            syndicateEntry  =  Goals . find ( m  = >  m . _id . $oid  ===  syndicateMissionId ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( syndicateEntry )  syndicateEntry . Tag  =  syndicateEntry . JobAffiliationTag ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( syndicateEntry  &&  syndicateEntry . Jobs )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-16 06:28:34 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            let  currentJob  =  syndicateEntry . Jobs [ rewardInfo . JobTier ! ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-11 08:08:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Gameplay/Eidolon/Jobs/Events/InfestedPlainsBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Gameplay/Eidolon/Jobs/Events/GhoulAlertBounty" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ] . some ( prefix  = >  jobType . startsWith ( prefix ) ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                currentJob  =  syndicateEntry . Jobs . find ( j  = >  j . jobType  ===  jobType ) ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( syndicateEntry . Tag  ===  "EntratiSyndicate" )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-24 19:05:19 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        "DeimosRuinsExterminateBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        "DeimosRuinsEscortBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        "DeimosRuinsMistBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        "DeimosRuinsPurifyBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        "DeimosRuinsSacBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        "VaultBounty" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ] . some ( ending  = >  jobType . endsWith ( ending ) ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  vault  =  syndicateEntry . Jobs . find ( j  = >  j . locationTag  ==  rewardInfo . jobId ! . split ( "_" ) . at ( - 1 ) ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( vault )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        currentJob  =  vault ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( jobType . endsWith ( "VaultBounty" ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            currentJob . xpAmounts  =  [ currentJob . xpAmounts . reduce ( ( partialSum ,  a )  = >  partialSum  +  a ,  0 ) ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-20 04:40:27 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-21 03:23:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                let  medallionAmount  =  Math . floor ( currentJob . xpAmounts [ rewardInfo . JobStage ]  /  ( rewardInfo . Q  ?  0.8  : 1 ) ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    [ "DeimosEndlessAreaDefenseBounty" ,  "DeimosEndlessExcavateBounty" ,  "DeimosEndlessPurifyBounty" ] . some ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ending  = >  jobType . endsWith ( ending ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  endlessJob  =  syndicateEntry . Jobs . find ( j  = >  j . endless ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( endlessJob )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  index  =  rewardInfo . JobStage  %  endlessJob . xpAmounts . length ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:51:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        const  excess  =  Math . floor ( rewardInfo . JobStage  /  ( endlessJob . xpAmounts . length  -  1 ) ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        medallionAmount  =  Math . floor ( endlessJob . xpAmounts [ index ]  *  ( 1  +  0.15000001  *  excess ) ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                await  addItem ( inventory ,  "/Lotus/Types/Items/Deimos/EntratiFragmentUncommonB" ,  medallionAmount ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                MissionRewards . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    StoreItem :  "/Lotus/StoreItems/Types/Items/Deimos/EntratiFragmentUncommonB" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ItemCount : medallionAmount 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                SyndicateXPItemReward  =  medallionAmount ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-29 00:31:19 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                logger . debug ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ` Giving  ${ medallionAmount }  medallions for the  ${ rewardInfo . JobStage }  stage of the  ${ rewardInfo . JobTier }  tier bounty ` 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            }  else  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-11 08:08:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                const  specialCase  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    {  endings :  [ "Heists/HeistProfitTakerBountyOne" ] ,  stage : 2 ,  amount : 1000  } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    {  endings :  [ "Hunts/AllTeralystsHunt" ] ,  stage : 2 ,  amount : 5000  } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        endings :  [ 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            "Hunts/TeralystHunt" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            "Heists/HeistProfitTakerBountyTwo" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            "Heists/HeistProfitTakerBountyThree" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            "Heists/HeistProfitTakerBountyFour" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            "Heists/HeistExploiterBountyOne" 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-11 08:08:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        ] , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        amount : 1000 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-11 08:08:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  specialCaseReward  =  specialCase . find ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    rule  = > 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        rule . endings . some ( e  = >  jobType . endsWith ( e ) )  && 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ( rule . stage  ===  undefined  ||  rewardInfo . JobStage  ===  rule . stage ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( specialCaseReward )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    addStanding ( inventory ,  syndicateEntry . Tag ,  specialCaseReward . amount ,  AffiliationMods ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    addStanding ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        inventory , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        syndicateEntry . Tag , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        Math . floor ( currentJob . xpAmounts [ rewardInfo . JobStage ]  /  ( rewardInfo . Q  ?  0.8  : 1 ) ) , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        AffiliationMods 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-29 00:31:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( jobType  ==  "/Lotus/Types/Gameplay/Eidolon/Jobs/NewbieJob" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            addStanding ( inventory ,  "CetusSyndicate" ,  Math . floor ( 200  /  ( rewardInfo . Q  ?  0.8  : 1 ) ) ,  AffiliationMods ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( rewardInfo . challengeMissionId )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-15 05:05:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        const  [ syndicateTag ,  tierStr ,  chemistryBuddyStr ]  =  rewardInfo . challengeMissionId . split ( "_" ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        const  tier  =  Number ( tierStr ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-15 05:05:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        const  chemistryBuddy  =  Number ( chemistryBuddyStr ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        const  isSteelPath  =  missions ? . Tier ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( syndicateTag  ===  "ZarimanSyndicate" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            let  medallionAmount  =  tier  +  1 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( isSteelPath )  medallionAmount  =  Math . round ( medallionAmount  *  1.5 ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            await  addItem ( inventory ,  "/Lotus/Types/Gameplay/Zariman/Resources/ZarimanDogTagBounty" ,  medallionAmount ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            MissionRewards . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                StoreItem :  "/Lotus/StoreItems/Types/Gameplay/Zariman/Resources/ZarimanDogTagBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ItemCount : medallionAmount 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            SyndicateXPItemReward  =  medallionAmount ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-29 00:31:19 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            logger . debug ( ` Giving  ${ medallionAmount }  medallions for the  ${ tier }  tier bounty ` ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            let  standingAmount  =  ( tier  +  1 )  *  1000 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( tier  >  5 )  standingAmount  =  7500 ;  // InfestedLichBounty
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( isSteelPath )  standingAmount  *=  1.5 ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-14 12:57:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            addStanding ( inventory ,  syndicateTag ,  standingAmount ,  AffiliationMods ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-15 05:05:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( syndicateTag  ==  "HexSyndicate"  &&  tier  <  6 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  buddy  =  chemistryBuddies [ chemistryBuddy ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:38:52 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            const  dialogue  =  getDialogue ( inventory ,  buddy ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-15 05:05:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( Date . now ( )  >=  dialogue . BountyChemExpiry . getTime ( ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                logger . debug ( ` Giving 20 chemistry for  ${ buddy } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  tomorrowAt0Utc  =  config . noKimCooldowns 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ?  Date . now ( ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    :  ( Math . trunc ( Date . now ( )  /  86400 _000 )  +  1 )  *  86400 _000 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                dialogue . Chemistry  +=  20 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                dialogue . BountyChemExpiry  =  new  Date ( tomorrowAt0Utc ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                logger . debug ( ` Already got today's chemistry for  ${ buddy } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:38:52 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-12 06:13:44 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( isSteelPath )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            await  addItem ( inventory ,  "/Lotus/Types/Items/MiscItems/SteelEssence" ,  1 ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            MissionRewards . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                StoreItem :  "/Lotus/StoreItems/Types/Items/MiscItems/SteelEssence" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ItemCount : 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-23 11:35:57 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    return  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        inventoryChanges , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        MissionRewards , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        credits , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        AffiliationMods , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        SyndicateXPItemReward , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ConquestCompletedMissionsCount 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								} ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:20:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								export  const  addCredits  =  async  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    account : TAccountDocument , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-05 06:52:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    inventory : TInventoryDatabaseDocument , 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        missionDropCredits , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        missionCompletionCredits , 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-06 07:11:31 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        rngRewardCredits 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } :  {  missionDropCredits : number ;  missionCompletionCredits : number ;  rngRewardCredits : number  } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:20:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								) :  Promise < IMissionCredits >  = >  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-15 03:24:39 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    const  finalCredits : IMissionCredits  =  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        MissionCredits :  [ missionDropCredits ,  missionDropCredits ] , 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:20:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        CreditsBonus :  [ missionCompletionCredits ,  missionCompletionCredits ] , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        TotalCredits :  [ 0 ,  0 ] 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } ; 
							 
						 
					
						
							
								
									
										
										
										
											2023-09-06 14:02:54 +04:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:20:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    const  today  =  Math . trunc ( Date . now ( )  /  86400000 )  *  86400 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( account . DailyFirstWinDate  !=  today )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        account . DailyFirstWinDate  =  today ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        await  account . save ( ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        logger . debug ( ` daily first win, doubling missionCompletionCredits ( ${ missionCompletionCredits } ) ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        finalCredits . DailyMissionBonus  =  true ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-06 07:11:31 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        inventory . RegularCredits  +=  missionCompletionCredits ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:20:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        finalCredits . CreditsBonus [ 1 ]  *=  2 ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:20:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    const  totalCredits  =  finalCredits . MissionCredits [ 1 ]  +  finalCredits . CreditsBonus [ 1 ]  +  rngRewardCredits ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    finalCredits . TotalCredits  =  [ totalCredits ,  totalCredits ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( config . worldState ? . creditBoost )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        inventory . RegularCredits  +=  finalCredits . TotalCredits [ 1 ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        finalCredits . TotalCredits [ 1 ]  +=  finalCredits . TotalCredits [ 1 ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    const  now  =  Math . trunc ( Date . now ( )  /  1000 ) ;  // TOVERIFY: Should we maybe subtract mission time as to apply credit boosters that expired during mission?
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( ( inventory . Boosters . find ( x  = >  x . ItemType  ==  "/Lotus/Types/Boosters/CreditBooster" ) ? . ExpiryDate  ? ?  0 )  >  now )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        inventory . RegularCredits  +=  finalCredits . TotalCredits [ 1 ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        finalCredits . TotalCredits [ 1 ]  +=  finalCredits . TotalCredits [ 1 ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( ( inventory . Boosters . find ( x  = >  x . ItemType  ==  "/Lotus/Types/Boosters/CreditBlessing" ) ? . ExpiryDate  ? ?  0 )  >  now )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        inventory . RegularCredits  +=  finalCredits . TotalCredits [ 1 ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        finalCredits . TotalCredits [ 1 ]  +=  finalCredits . TotalCredits [ 1 ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:20:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    return  finalCredits ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								} ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								export  const  addFixedLevelRewards  =  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    rewards : IMissionRewardExternal , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 14:58:15 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    MissionRewards : IMissionReward [ ] , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    rewardInfo? : IRewardInfo 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-15 03:24:39 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								) :  number  = >  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    let  missionBonusCredits  =  0 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( rewards . credits )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        missionBonusCredits  +=  rewards . credits ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( rewards . items )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        for  ( const  item  of  rewards . items )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            MissionRewards . push ( { 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-25 16:58:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                StoreItem : item , 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                ItemCount : 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( rewards . countedItems )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        for  ( const  item  of  rewards . countedItems )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            MissionRewards . push ( { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-22 06:37:17 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                StoreItem : toStoreItem ( item . ItemType ) , 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                ItemCount : item.ItemCount 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( rewards . countedStoreItems )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        for  ( const  item  of  rewards . countedStoreItems )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            MissionRewards . push ( item ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-06 10:19:15 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( rewards . droptable )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( rewards . droptable  in  ExportRewards )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 14:58:15 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            const  rotations : number [ ]  =  rewardInfo  ?  getRotations ( rewardInfo )  :  [ 0 ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            logger . debug ( ` rolling  ${ rewards . droptable }  for level key rewards ` ,  {  rotations  } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            for  ( const  tier  of  rotations )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  reward  =  getRandomRewardByChance ( ExportRewards [ rewards . droptable ] [ tier ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( reward )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    MissionRewards . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        StoreItem : reward.type , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ItemCount : reward.itemCount 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-06 10:19:15 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            logger . error ( ` unknown droptable  ${ rewards . droptable } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-24 08:50:07 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    return  missionBonusCredits ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-03-31 04:15:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								function  getLevelCreditRewards ( node : IRegion ) :  number  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    const  minEnemyLevel  =  node . minEnemyLevel ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    return  1000  +  ( minEnemyLevel  -  1 )  *  100 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    //TODO: get dark sektor fixed credit rewards and railjack bonus
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-18 11:23:52 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								function  getRandomMissionDrops ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    inventory : TInventoryDatabaseDocument , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    RewardInfo : IRewardInfo , 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-09 21:38:13 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    mission : IMission  |  undefined , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-18 11:23:52 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    tierOverride : number  |  undefined , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    firstCompletion : boolean 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								) :  IMissionReward [ ]  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-25 04:42:49 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    const  drops : IMissionReward [ ]  =  [ ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-18 11:23:52 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( RewardInfo . sortieTag  ==  "Final"  &&  firstCompletion )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        const  arr  =  RewardInfo . sortieId ! . split ( "_" ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        let  sortieId  =  arr [ 1 ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( sortieId  ==  "Lite" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            sortieId  =  arr [ 2 ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-04-19 09:06:38 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            const  boss  =  getLiteSortie ( idToWeek ( sortieId ) ) . Boss ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-18 11:23:52 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            let  crystalType  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                SORTIE_BOSS_AMAR :  "/Lotus/StoreItems/Types/Gameplay/NarmerSorties/ArchonCrystalAmar" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                SORTIE_BOSS_NIRA :  "/Lotus/StoreItems/Types/Gameplay/NarmerSorties/ArchonCrystalNira" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                SORTIE_BOSS_BOREAL :  "/Lotus/StoreItems/Types/Gameplay/NarmerSorties/ArchonCrystalBoreal" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } [ boss ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  attenTag  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                SORTIE_BOSS_AMAR :  "NarmerSortieAmarCrystalRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                SORTIE_BOSS_NIRA :  "NarmerSortieNiraCrystalRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                SORTIE_BOSS_BOREAL :  "NarmerSortieBorealCrystalRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } [ boss ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  attenIndex  =  inventory . SortieRewardAttenuation ? . findIndex ( x  = >  x . Tag  ==  attenTag )  ? ?  - 1 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  mythicProbability  = 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                0.2  +  ( inventory . SortieRewardAttenuation ? . find ( x  = >  x . Tag  ==  attenTag ) ? . Atten  ? ?  0 ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( Math . random ( )  <  mythicProbability )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                crystalType  +=  "Mythic" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( attenIndex  !=  - 1 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . SortieRewardAttenuation ! . splice ( attenIndex ,  1 ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( attenIndex  ==  - 1 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . SortieRewardAttenuation  ? ? =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . SortieRewardAttenuation . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        Tag : attenTag , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        Atten : 0.2 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    inventory . SortieRewardAttenuation ! [ attenIndex ] . Atten  +=  0.2 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            drops . push ( {  StoreItem : crystalType ,  ItemCount : 1  } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  drop  =  getRandomRewardByChance ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ExportRewards [ "/Lotus/Types/Game/MissionDecks/ArchonSortieRewards" ] [ 0 ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ) ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            drops . push ( {  StoreItem : drop.type ,  ItemCount : drop.itemCount  } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            inventory . LastLiteSortieReward  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    SortieId : new  Types . ObjectId ( sortieId ) , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    StoreItem : drop.type , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    Manifest :  "/Lotus/Types/Game/MissionDecks/ArchonSortieRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  drop  =  getRandomRewardByChance ( ExportRewards [ "/Lotus/Types/Game/MissionDecks/SortieRewards" ] [ 0 ] ) ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            drops . push ( {  StoreItem : drop.type ,  ItemCount : drop.itemCount  } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            inventory . LastSortieReward  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    SortieId : new  Types . ObjectId ( sortieId ) , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    StoreItem : drop.type , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    Manifest :  "/Lotus/Types/Game/MissionDecks/SortieRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-17 08:02:13 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 06:16:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( RewardInfo . periodicMissionTag ? . startsWith ( "HardDaily" ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        drops . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            StoreItem :  "/Lotus/StoreItems/Types/Items/MiscItems/SteelEssence" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ItemCount : 5 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-06 07:11:31 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    if  ( RewardInfo . node  in  ExportRegions )  { 
							 
						 
					
						
							
								
									
										
										
										
											2024-06-23 15:12:32 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        const  region  =  ExportRegions [ RewardInfo . node ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-18 11:18:26 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        let  rewardManifests : string [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( RewardInfo . periodicMissionTag  ==  "EliteAlert"  ||  RewardInfo . periodicMissionTag  ==  "EliteAlertB" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            rewardManifests  =  [ "/Lotus/Types/Game/MissionDecks/EliteAlertMissionRewards/EliteAlertMissionRewards" ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        }  else  if  ( RewardInfo . invasionId  &&  region . missionIndex  ==  0 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // Invasion assassination has Phorid has the boss who should drop Nyx parts
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // TODO: Check that the invasion faction is indeed FC_INFESTATION once the Invasions in worldState are more dynamic
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            rewardManifests  =  [ "/Lotus/Types/Game/MissionDecks/BossMissionRewards/NyxRewards" ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-06 02:29:11 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        }  else  if  ( RewardInfo . sortieId )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-09 21:36:49 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            // Sortie mission types differ from the underlying node and hence also don't give rewards from the underlying nodes.
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // Assassinations in non-lite sorties are an exception to this.
 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-06 02:29:11 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( region . missionIndex  ==  0 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  arr  =  RewardInfo . sortieId . split ( "_" ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-09 21:36:49 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                let  giveNodeReward  =  false ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( arr [ 1 ]  !=  "Lite" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  sortie  =  getSortie ( idToDay ( arr [ 1 ] ) ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    giveNodeReward  =  sortie . Variants . find ( x  = >  x . node  ==  arr [ 0 ] ) ! . missionType  ==  "MT_ASSASSINATION" ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-06 02:29:11 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-09 21:36:49 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                rewardManifests  =  giveNodeReward  ?  region . rewardManifests  :  [ ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-06 02:29:11 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                rewardManifests  =  [ ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:38:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        }  else  if  ( RewardInfo . T  ==  13 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // Undercroft extra/side portal (normal mode), gives 1 Pathos Clamp + Duviri Arcane.
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            drops . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                StoreItem :  "/Lotus/StoreItems/Types/Gameplay/Duviri/Resource/DuviriDragonDropItem" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ItemCount : 1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            rewardManifests  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                "/Lotus/Types/Game/MissionDecks/DuviriEncounterRewards/DuviriStaticUndercroftResourceRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        }  else  if  ( RewardInfo . T  ==  14 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            // Undercroft extra/side portal (steel path), gives 3 Pathos Clamps + Eidolon Arcane.
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            drops . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                StoreItem :  "/Lotus/StoreItems/Types/Gameplay/Duviri/Resource/DuviriDragonDropItem" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ItemCount : 3 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            rewardManifests  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                "/Lotus/Types/Game/MissionDecks/DuviriEncounterRewards/DuviriSteelPathStaticUndercroftResourceRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        }  else  if  ( RewardInfo . T  ==  15 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            rewardManifests  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                mission ? . Tier  ==  1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ?  "/Lotus/Types/Game/MissionDecks/DuviriEncounterRewards/DuviriKullervoSteelPathRNGRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    :  "/Lotus/Types/Game/MissionDecks/DuviriEncounterRewards/DuviriKullervoNormalRNGRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:22:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        }  else  if  ( RewardInfo . T  ==  17 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( mission ? . Tier  ==  1 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                logger . warn ( ` non-steel path duviri murmur tier used on steel path?! ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-18 09:34:24 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( config . worldState ? . eightClaw )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:22:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                drops . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    StoreItem :  "/Lotus/StoreItems/Types/Gameplay/DuviriMITW/Resources/DuviriMurmurItemEvent" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ItemCount : 10 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-18 09:34:24 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:22:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            rewardManifests  =  [ "/Lotus/Types/Game/MissionDecks/DuviriEncounterRewards/DuviriMurmurFinalChestRewards" ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        }  else  if  ( RewardInfo . T  ==  19 )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-18 09:34:24 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( config . worldState ? . eightClaw )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:22:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                drops . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    StoreItem :  "/Lotus/StoreItems/Types/Gameplay/DuviriMITW/Resources/DuviriMurmurItemEvent" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ItemCount : 15 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-18 09:34:24 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-27 08:22:00 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            rewardManifests  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                "/Lotus/Types/Game/MissionDecks/DuviriEncounterRewards/DuviriMurmurFinalSteelChestRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-22 07:34:22 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        }  else  if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            RewardInfo . T  ==  70  || 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            RewardInfo . T  ==  6  // https://onlyg.it/OpenWF/SpaceNinjaServer/issues/2526
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:38:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            // Orowyrm chest, gives 10 Pathos Clamps, or 15 on Steel Path.
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            drops . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                StoreItem :  "/Lotus/StoreItems/Types/Gameplay/Duviri/Resource/DuviriDragonDropItem" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ItemCount : mission?.Tier  ==  1  ?  15  : 10 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            rewardManifests  =  [ ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-18 11:18:26 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            rewardManifests  =  region . rewardManifests ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2023-09-06 14:02:54 +04:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2024-06-23 15:12:32 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        let  rotations : number [ ]  =  [ ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-11 06:54:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( RewardInfo . jobId )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:51:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( RewardInfo . JobStage !  >=  0 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                // eslint-disable-next-line @typescript-eslint/no-unused-vars
 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-24 19:05:19 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                const  [ jobType ,  unkIndex ,  hubNode ,  syndicateMissionId ]  =  RewardInfo . jobId . split ( "_" ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:51:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                let  isEndlessJob  =  false ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-06 19:05:23 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( syndicateMissionId )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  syndicateMissions : ISyndicateMissionInfo [ ]  =  [ ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-03 10:40:28 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    if  ( syndicateMissionId )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        pushClassicBounties ( syndicateMissions ,  idToBountyCycle ( syndicateMissionId ) ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-11 08:08:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    let  syndicateEntry : ISyndicateMissionInfo  |  IGoal  |  undefined  =  syndicateMissions . find ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        m  = >  m . _id . $oid  ===  syndicateMissionId 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            "/Lotus/Types/Gameplay/Eidolon/Jobs/Events/InfestedPlainsBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            "/Lotus/Types/Gameplay/Eidolon/Jobs/Events/GhoulAlertBounty" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ] . some ( prefix  = >  jobType . startsWith ( prefix ) ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        const  {  Goals  }  =  getWorldState ( undefined ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        syndicateEntry  =  Goals . find ( m  = >  m . _id . $oid  ===  syndicateMissionId ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( syndicateEntry )  syndicateEntry . Tag  =  syndicateEntry . JobAffiliationTag ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:51:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    if  ( syndicateEntry  &&  syndicateEntry . Jobs )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-16 06:28:34 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        let  job  =  syndicateEntry . Jobs [ RewardInfo . JobTier ! ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:51:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( syndicateEntry . Tag  ===  "EntratiSyndicate" )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-24 19:05:19 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    "DeimosRuinsExterminateBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    "DeimosRuinsEscortBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    "DeimosRuinsMistBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    "DeimosRuinsPurifyBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    "DeimosRuinsSacBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    "VaultBounty" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                ] . some ( ending  = >  jobType . endsWith ( ending ) ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                const  vault  =  syndicateEntry . Jobs . find ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    j  = >  j . locationTag  ===  RewardInfo . jobId ! . split ( "_" ) . at ( - 1 ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                if  ( vault )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    job  =  vault ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    if  ( jobType . endsWith ( "VaultBounty" ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        job . rewards  =  job . rewards . replace ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            "/Lotus/Types/Game/MissionDecks/" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            "/Supplementals/" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        job . xpAmounts  =  [ job . xpAmounts . reduce ( ( partialSum ,  a )  = >  partialSum  +  a ,  0 ) ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-20 04:40:27 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:51:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    "DeimosEndlessAreaDefenseBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    "DeimosEndlessExcavateBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    "DeimosEndlessPurifyBounty" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                ] . some ( ending  = >  jobType . endsWith ( ending ) ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                const  endlessJob  =  syndicateEntry . Jobs . find ( j  = >  j . endless ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                if  ( endlessJob )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    isEndlessJob  =  true ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    job  =  endlessJob ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    const  excess  =  Math . floor ( RewardInfo . JobStage !  /   ( j o b . x p A m o u n t s . l e n g t h   -   1 ) ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    const  rotationIndexes  =  [ 0 ,  0 ,  1 ,  2 ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    const  rotationIndex  =  rotationIndexes [ excess  %  rotationIndexes . length ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    const  dropTable  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        "/Lotus/Types/Game/MissionDecks/DeimosMissionRewards/TierBTableARewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        "/Lotus/Types/Game/MissionDecks/DeimosMissionRewards/TierBTableBRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        "/Lotus/Types/Game/MissionDecks/DeimosMissionRewards/TierBTableCRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    job . rewards  =  dropTable [ rotationIndex ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        }  else  if  ( syndicateEntry . Tag  ===  "SolarisSyndicate" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            if  ( jobType . endsWith ( "Heists/HeistProfitTakerBountyOne" )  &&  RewardInfo . JobStage  ==  2 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                job  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    rewards : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        "/Lotus/Types/Game/MissionDecks/HeistJobMissionRewards/HeistTierATableARewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    masteryReq : 0 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    minEnemyLevel : 40 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    maxEnemyLevel : 60 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    xpAmounts :  [ 1000 ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                RewardInfo . Q  =  false ;  // Just in case
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                const  tierMap  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    Two :  "B" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    Three :  "C" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    Four :  "D" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                for  ( const  [ key ,  tier ]  of  Object . entries ( tierMap ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    if  ( jobType . endsWith ( ` Heists/HeistProfitTakerBounty ${ key } ` ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        job  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            rewards :  ` /Lotus/Types/Game/MissionDecks/HeistJobMissionRewards/HeistTier ${ tier } TableARewards ` , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            masteryReq : 0 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            minEnemyLevel : 40 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            maxEnemyLevel : 60 , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                            xpAmounts :  [ 1000 ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        } ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        RewardInfo . Q  =  false ;  // Just in case
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                        break ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-11 08:08:40 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                "/Lotus/Types/Gameplay/Eidolon/Jobs/Events/InfestedPlainsBounty" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                "/Lotus/Types/Gameplay/Eidolon/Jobs/Events/GhoulAlertBounty" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            ] . some ( prefix  = >  jobType . startsWith ( prefix ) ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            job  =  syndicateEntry . Jobs . find ( j  = >  j . jobType  ===  jobType ) ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:51:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        rewardManifests  =  [ job . rewards ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-03 17:24:08 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        if  ( job . xpAmounts . length  >  1 )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-23 14:56:18 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            const  curentStage  =  RewardInfo . JobStage !  +  1 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            const  totalStage  =  job . xpAmounts . length ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            let  tableIndex  =  1 ;  // Stage 2, Stage 3 of 4, and Stage 3 of 5
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            if  ( curentStage  ==  1 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                tableIndex  =  0 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            }  else  if  ( curentStage  ==  totalStage )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                tableIndex  =  3 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            }  else  if  ( totalStage  ==  5  &&  curentStage  ==  4 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                                tableIndex  =  2 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            rotations  =  [ tableIndex ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-03 17:24:08 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        }  else  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-05 18:03:53 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            rotations  =  [ 0 ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-03 17:24:08 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:51:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        if  ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            RewardInfo . Q  && 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-24 19:05:19 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            ( RewardInfo . JobStage  ===  job . xpAmounts . length  -  1  ||  jobType . endsWith ( "VaultBounty" ) )  && 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:51:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            ! isEndlessJob 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-24 19:05:19 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            rotations . push ( ExportRewards [ job . rewards ] . length  -  1 ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:51:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-11 06:54:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-07-29 00:31:37 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( jobType  ==  "/Lotus/Types/Gameplay/Eidolon/Jobs/NewbieJob" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    rewardManifests  =  [ "/Lotus/Types/Game/MissionDecks/EidolonJobMissionRewards/TierATableARewards" ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    rotations  =  [ 3 ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( RewardInfo . Q )  rotations . push ( 3 ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-11 06:54:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:51:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        }  else  if  ( RewardInfo . challengeMissionId )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  rewardTables : Record < string ,  string [ ] >  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                EntratiLabSyndicate :  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/EntratiLabJobMissionReward/TierATableRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/EntratiLabJobMissionReward/TierBTableRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/EntratiLabJobMissionReward/TierCTableRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/EntratiLabJobMissionReward/TierDTableRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/EntratiLabJobMissionReward/TierETableRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ] , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ZarimanSyndicate :  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/ZarimanJobMissionRewards/TierATableRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/ZarimanJobMissionRewards/TierBTableRewards" , 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-12 19:49:30 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/ZarimanJobMissionRewards/TierCTableARewards" ,  // [sic]
 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-13 05:51:02 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/ZarimanJobMissionRewards/TierDTableRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/ZarimanJobMissionRewards/TierETableRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ] , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                HexSyndicate :  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/1999MissionRewards/TierABountyRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/1999MissionRewards/TierBBountyRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/1999MissionRewards/TierCBountyRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/1999MissionRewards/TierDBountyRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/1999MissionRewards/TierEBountyRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/1999MissionRewards/TierFBountyRewards" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    "/Lotus/Types/Game/MissionDecks/1999MissionRewards/InfestedLichBountyRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  [ syndicateTag ,  tierStr ]  =  RewardInfo . challengeMissionId . split ( "_" ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  tier  =  Number ( tierStr ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  rewardTable  =  rewardTables [ syndicateTag ] [ tier ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( rewardTable )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                rewardManifests  =  [ rewardTable ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                rotations  =  [ 0 ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                logger . error ( ` Unknown syndicate or tier:  ${ RewardInfo . challengeMissionId } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2024-06-23 15:12:32 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        }  else  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-09 21:38:13 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( RewardInfo . node  ==  "SolNode238" )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                // The Circuit
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  category  =  mission ? . Tier  ==  1  ?  "EXC_HARD"  :  "EXC_NORMAL" ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  progress  =  inventory . EndlessXP ? . find ( x  = >  x . Category  ==  category ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( progress )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    // https://wiki.warframe.com/w/The%20Circuit#Tiers_and_Weekly_Rewards
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  roundsCompleted  =  RewardInfo . rewardQualifications ? . length  ||  0 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( roundsCompleted  >=  1 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        progress . Earn  +=  100 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( roundsCompleted  >=  2 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        progress . Earn  +=  110 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( roundsCompleted  >=  3 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        progress . Earn  +=  125 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( roundsCompleted  >=  4 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        progress . Earn  +=  145 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        if  ( progress . BonusAvailable  &&  progress . BonusAvailable . getTime ( )  <=  Date . now ( ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            progress . Earn  +=  50 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            progress . BonusAvailable  =  new  Date ( Date . now ( )  +  24  *  3600 _000 ) ;  // TOVERIFY
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( roundsCompleted  >=  5 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        progress . Earn  +=  ( roundsCompleted  -  4 )  *  170 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                tierOverride  =  0 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 10:47:38 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            rotations  =  getRotations ( RewardInfo ,  tierOverride ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2024-06-22 23:19:42 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-11 06:54:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( rewardManifests . length  !=  0 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            logger . debug ( ` generating random mission rewards ` ,  {  rewardManifests ,  rotations  } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-25 11:54:11 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( RewardInfo . rewardSeed )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( RewardInfo . rewardSeed  !=  inventory . RewardSeed )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                logger . warn ( ` RewardSeed mismatch: ` ,  {  client : RewardInfo.rewardSeed ,  database : inventory.RewardSeed  } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 09:46:08 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        const  rng  =  new  SRng ( BigInt ( RewardInfo . rewardSeed  ? ?  generateRewardSeed ( ) )  ^  0xffffffffffffffff n ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 06:10:25 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        rewardManifests . forEach ( name  = >  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  table  =  ExportRewards [ name ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 18:48:17 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 06:10:25 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            if  ( ! table )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                logger . error ( ` unknown droptable:  ${ name } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                return ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            for  ( const  rotation  of  rotations )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  rotationRewards  =  table [ rotation ] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 09:46:08 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                const  drop  =  getRandomRewardByChance ( rotationRewards ,  rng ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 06:10:25 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( drop )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    drops . push ( {  StoreItem : drop.type ,  ItemCount : drop.itemCount  } ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2024-06-23 15:12:32 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-15 06:10:25 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2024-06-23 15:12:32 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:26 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        // Railjack Abandoned Cache Rewards, Rotation A (Mandatory Objectives)
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( RewardInfo . POICompletions )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( region . cacheRewardManifest )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  deck  =  ExportRewards [ region . cacheRewardManifest ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( let  cache  =  0 ;  cache  !=  RewardInfo . POICompletions ;  ++ cache )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  drop  =  getRandomRewardByChance ( deck [ 0 ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( drop )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        drops . push ( {  StoreItem : drop.type ,  ItemCount : drop.itemCount ,  FromEnemyCache : true  } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                logger . error ( ` POI completed, but there was no cache reward manifest at  ${ RewardInfo . node } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        // Railjack Abandoned Cache Rewards, Rotation B (Optional Objectives)
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( RewardInfo . LootDungeonCompletions )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( region . cacheRewardManifest )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  deck  =  ExportRewards [ region . cacheRewardManifest ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                for  ( let  cache  =  0 ;  cache  !=  RewardInfo . LootDungeonCompletions ;  ++ cache )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  drop  =  getRandomRewardByChance ( deck [ 1 ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( drop )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        drops . push ( {  StoreItem : drop.type ,  ItemCount : drop.itemCount ,  FromEnemyCache : true  } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                logger . error ( ` Loot dungeon completed, but there was no cache reward manifest at  ${ RewardInfo . node } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2024-06-23 15:12:32 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        if  ( region . cacheRewardManifest  &&  RewardInfo . EnemyCachesFound )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  deck  =  ExportRewards [ region . cacheRewardManifest ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            for  ( let  rotation  =  0 ;  rotation  !=  RewardInfo . EnemyCachesFound ;  ++ rotation )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  drop  =  getRandomRewardByChance ( deck [ rotation ] ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2024-06-22 02:39:29 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                if  ( drop )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-25 04:42:49 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                    drops . push ( {  StoreItem : drop.type ,  ItemCount : drop.itemCount ,  FromEnemyCache : true  } ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2024-06-22 02:39:29 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
									
										
										
										
											2023-09-06 14:02:54 +04:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2024-06-23 15:12:32 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-08 17:41:21 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( RewardInfo . nightmareMode )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  deck  =  ExportRewards [ "/Lotus/Types/Game/MissionDecks/NightmareModeRewards" ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            let  rotation  =  0 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( region . missionIndex  ===  3  &&  RewardInfo . rewardTier )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                rotation  =  RewardInfo . rewardTier ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            }  else  if  ( [ 6 ,  7 ,  8 ,  10 ,  11 ] . includes ( region . systemIndex ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                rotation  =  2 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            }  else  if  ( [ 4 ,  9 ,  12 ,  14 ,  15 ,  16 ,  17 ,  18 ] . includes ( region . systemIndex ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                rotation  =  1 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  drop  =  getRandomRewardByChance ( deck [ rotation ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( drop )  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-25 04:42:49 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                drops . push ( {  StoreItem : drop.type ,  ItemCount : drop.itemCount  } ) ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-08 17:41:21 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-16 06:30:36 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( RewardInfo . PurgatoryRewardQualifications )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            for  ( const  encodedQualification  of  RewardInfo . PurgatoryRewardQualifications )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  qualification  =  parseInt ( encodedQualification )  -  1 ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                if  ( qualification  <  0  ||  qualification  >  8 )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    logger . error ( ` unexpected purgatory reward qualification:  ${ qualification } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                }  else  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    const  drop  =  getRandomRewardByChance ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ExportRewards [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            [ 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-08 04:32:32 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                "/Lotus/Types/Game/MissionDecks/PurgatoryMissionRewards/PurgatoryBlueTokenRewards" , 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-16 06:30:36 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                "/Lotus/Types/Game/MissionDecks/PurgatoryMissionRewards/PurgatoryGoldTokenRewards" , 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-08 04:32:32 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                                "/Lotus/Types/Game/MissionDecks/PurgatoryMissionRewards/PurgatoryBlackTokenRewards" 
							 
						 
					
						
							
								
									
										
										
										
											2025-04-16 06:30:36 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								                            ] [ Math . trunc ( qualification  /  3 ) ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ] [ qualification  %  3 ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    if  ( drop )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        drops . push ( { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            StoreItem : drop.type , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            ItemCount : drop.itemCount , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                            FromEnemyCache : true  // to show "identified"
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-08 17:41:21 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-08 08:22:27 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( RewardInfo . periodicMissionTag ? . startsWith ( "KuvaMission" ) )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  drop  =  getRandomRewardByChance ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ExportRewards [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    RewardInfo . periodicMissionTag  ==  "KuvaMission6"  ||  RewardInfo . periodicMissionTag  ==  "KuvaMission12" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        ?  "/Lotus/Types/Game/MissionDecks/KuvaMissionRewards/KuvaSiphonFloodRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        :  "/Lotus/Types/Game/MissionDecks/KuvaMissionRewards/KuvaSiphonRewards" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ] [ 0 ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            ) ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            drops . push ( {  StoreItem : drop.type ,  ItemCount : drop.itemCount  } ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
									
										
										
										
											2024-06-23 15:12:32 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-20 04:42:11 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    if  ( config . missionsCanGiveAllRelics )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        for  ( const  drop  of  drops )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  itemType  =  fromStoreItem ( drop . StoreItem ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            if  ( itemType  in  ExportRelics )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  relic  =  ExportRelics [ itemType ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                const  replacement  =  getRandomElement ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    Object . entries ( ExportRelics ) . filter ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                        arr  = >  arr [ 1 ] . era  ==  relic . era  &&  arr [ 1 ] . quality  ==  relic . quality 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                    ) 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                ) ! ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                logger . debug ( ` replacing  ${ relic . era }   ${ relic . category }  with  ${ replacement [ 1 ] . category } ` ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								                drop . StoreItem  =  toStoreItem ( replacement [ 0 ] ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-01-24 14:13:21 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    return  drops ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} 
							 
						 
					
						
							
								
									
										
										
										
											2025-02-28 12:36:01 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								const  corruptedMods  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Melee/DualStat/CorruptedHeavyDamageChargeSpeedMod" ,  // Corrupt Charge
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Pistol/DualStat/CorruptedCritDamagePistol" ,  // Hollow Point
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Melee/DualStat/CorruptedDamageSpeedMod" ,  // Spoiled Strike
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Pistol/DualStat/CorruptedDamageRecoilPistol" ,  // Magnum Force
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Pistol/DualStat/CorruptedMaxClipReloadSpeedPistol" ,  // Tainted Clip
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Rifle/DualStat/CorruptedCritRateFireRateRifle" ,  // Critical Delay
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Rifle/DualStat/CorruptedDamageRecoilRifle" ,  // Heavy Caliber
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Rifle/DualStat/CorruptedMaxClipReloadSpeedRifle" ,  // Tainted Mag
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Rifle/DualStat/CorruptedRecoilFireRateRifle" ,  // Vile Precision
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Warframe/DualStat/CorruptedDurationRangeWarframe" ,  // Narrow Minded
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Warframe/DualStat/CorruptedEfficiencyDurationWarframe" ,  // Fleeting Expertise
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Warframe/DualStat/CorruptedPowerEfficiencyWarframe" ,  // Blind Rage
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Warframe/DualStat/CorruptedRangePowerWarframe" ,  // Overextended
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Shotgun/DualStat/CorruptedAccuracyFireRateShotgun" ,  // Tainted Shell
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Shotgun/DualStat/CorruptedDamageAccuracyShotgun" ,  // Vicious Spread
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Shotgun/DualStat/CorruptedMaxClipReloadSpeedShotgun" ,  // Burdened Magazine
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Pistol/DualStat/CorruptedFireRateDamagePistol" ,  // Anemic Agility
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Rifle/DualStat/CorruptedFireRateDamageRifle" ,  // Vile Acceleration
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Shotgun/DualStat/CorruptedFireRateDamageShotgun" ,  // Frail Momentum
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Shotgun/DualStat/CorruptedCritChanceFireRateShotgun" ,  // Critical Deceleration
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Pistol/DualStat/CorruptedCritChanceFireRatePistol" ,  // Creeping Bullseye
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Warframe/DualStat/CorruptedPowerStrengthPowerDurationWarframe" ,  // Transient Fortitude
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Rifle/DualStat/CorruptedReloadSpeedMaxClipRifle" ,  // Depleted Reload
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/StoreItems/Upgrades/Mods/Warframe/DualStat/FixedShieldAndShieldGatingDuration"  // Catalyzing Shields
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								] ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-03-07 00:40:22 -08:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								const  libraryPersonalTargetToAvatar : Record < string ,  string >  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Game/Library/Targets/DragonframeQuestTarget" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Enemies/Grineer/Desert/Avatars/RifleLancerAvatar" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Game/Library/Targets/Research1Target" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Enemies/Grineer/Desert/Avatars/RifleLancerAvatar" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Game/Library/Targets/Research2Target" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Enemies/Corpus/BipedRobot/AIWeek/LaserDiscBipedAvatar" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Game/Library/Targets/Research3Target" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Enemies/Grineer/Desert/Avatars/EvisceratorLancerAvatar" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Game/Library/Targets/Research4Target" :  "/Lotus/Types/Enemies/Orokin/OrokinHealingAncientAvatar" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Game/Library/Targets/Research5Target" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Enemies/Corpus/Spaceman/AIWeek/ShotgunSpacemanAvatar" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Game/Library/Targets/Research6Target" :  "/Lotus/Types/Enemies/Infested/AiWeek/Runners/RunnerAvatar" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Game/Library/Targets/Research7Target" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Enemies/Grineer/AIWeek/Avatars/GrineerMeleeStaffAvatar" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Game/Library/Targets/Research8Target" :  "/Lotus/Types/Enemies/Orokin/OrokinHeavyFemaleAvatar" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Game/Library/Targets/Research9Target" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Enemies/Infested/AiWeek/Quadrupeds/QuadrupedAvatar" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Game/Library/Targets/Research10Target" : 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Enemies/Corpus/Spaceman/AIWeek/NullifySpacemanAvatar" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:38:52 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-06-15 05:05:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								const  chemistryBuddies : readonly  string [ ]  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Gameplay/1999Wf/Dialogue/JabirDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Gameplay/1999Wf/Dialogue/AoiDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Gameplay/1999Wf/Dialogue/ArthurDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Gameplay/1999Wf/Dialogue/EleanorDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Gameplay/1999Wf/Dialogue/LettieDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Gameplay/1999Wf/Dialogue/QuincyDialogue_rom.dialogue" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								/ * c o n s t   n o d e _ e x c l u d e d _ b u d d i e s :   R e c o r d < s t r i n g ,   s t r i n g >   =   { 
							 
						 
					
						
							
								
									
										
										
										
											2025-05-13 20:38:52 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    SolNode856 :  "/Lotus/Types/Gameplay/1999Wf/Dialogue/ArthurDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    SolNode852 :  "/Lotus/Types/Gameplay/1999Wf/Dialogue/LettieDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    SolNode851 :  "/Lotus/Types/Gameplay/1999Wf/Dialogue/JabirDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    SolNode850 :  "/Lotus/Types/Gameplay/1999Wf/Dialogue/EleanorDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    SolNode853 :  "/Lotus/Types/Gameplay/1999Wf/Dialogue/AoiDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    SolNode854 :  "/Lotus/Types/Gameplay/1999Wf/Dialogue/QuincyDialogue_rom.dialogue" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								const  getHexBounties  =  ( seed : number ) :  {  nodes : string [ ] ;  buddies : string [ ]  }  = >  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    // We're gonna shuffle these arrays, so they're not truly 'const'.
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    const  nodes : string [ ]  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "SolNode850" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "SolNode851" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "SolNode852" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "SolNode853" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "SolNode854" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "SolNode856" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "SolNode858" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    const  excludable_nodes : string [ ]  =  [ "SolNode851" ,  "SolNode852" ,  "SolNode853" ,  "SolNode854" ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    const  buddies : string [ ]  =  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Gameplay/1999Wf/Dialogue/JabirDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Gameplay/1999Wf/Dialogue/AoiDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Gameplay/1999Wf/Dialogue/ArthurDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Gameplay/1999Wf/Dialogue/EleanorDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Gameplay/1999Wf/Dialogue/LettieDialogue_rom.dialogue" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        "/Lotus/Types/Gameplay/1999Wf/Dialogue/QuincyDialogue_rom.dialogue" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    const  rng  =  new  SRng ( seed ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    rng . shuffleArray ( nodes ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    rng . shuffleArray ( excludable_nodes ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    while  ( nodes . length  >  buddies . length )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        nodes . splice ( 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            nodes . findIndex ( x  = >  x  ==  excludable_nodes [ 0 ] ) , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            1 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        excludable_nodes . splice ( 0 ,  1 ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    rng . shuffleArray ( buddies ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    for  ( let  i  =  0 ;  i  !=  6 ;  ++ i )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        if  ( buddies [ i ]  ==  node_excluded_buddies [ nodes [ i ] ] )  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  swapIdx  =  ( i  +  1 )  %  buddies . length ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            const  tmp  =  buddies [ swapIdx ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            buddies [ swapIdx ]  =  buddies [ i ] ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            buddies [ i ]  =  tmp ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    return  {  nodes ,  buddies  } ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-15 05:05:35 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								} ; * / 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2025-08-17 13:11:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								const  goalMessagesByKey : Record < string ,  {  sndr :  string ;  msg :  string ;  sub :  string ;  icon :  string ;  arg ? :  string [ ]  } >  =  { 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/GalleonRobberyAlert" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/BossCouncilorVayHek" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/GalleonRobbery2025RewardMsgA" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/GalleonRobbery2025MissionTitleA" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/VayHekPortrait.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/GalleonRobberyAlertB" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/BossCouncilorVayHek" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/GalleonRobbery2025RewardMsgB" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/GalleonRobbery2025MissionTitleB" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/VayHekPortrait.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/GalleonRobberyAlertC" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/BossCouncilorVayHek" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/GalleonRobbery2025RewardMsgC" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/GalleonRobbery2025MissionTitleC" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/VayHekPortrait.png" 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyWaterFightA" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/BossKelaDeThaym" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/WaterFightRewardMsgA" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/WaterFightRewardSubjectA" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Grineer/KelaDeThaym.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyWaterFightB" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/BossKelaDeThaym" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/WaterFightRewardMsgB" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/WaterFightRewardSubjectB" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Grineer/KelaDeThaym.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyWaterFightC" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/BossKelaDeThaym" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/WaterFightRewardMsgC" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/WaterFightRewardSubjectC" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Grineer/KelaDeThaym.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyWaterFightD" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/BossKelaDeThaym" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/WaterFightRewardMsgD" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/WaterFightRewardSubjectD" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Grineer/KelaDeThaym.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/WolfTacAlertReduxA" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/NoraNight" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/WolfTacAlertBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/WolfTacAlertTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Seasonal/NoraNight.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/WolfTacAlertReduxB" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/NoraNight" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/WolfTacAlertBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/WolfTacAlertTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Seasonal/NoraNight.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/WolfTacAlertReduxD" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/NoraNight" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/WolfTacAlertBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/WolfTacAlertTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Seasonal/NoraNight.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/WolfTacAlertReduxC" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/NoraNight" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/WolfTacAlertBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/WolfTacAlertTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Seasonal/NoraNight.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/LanternEndlessEventKeyA" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/GenericEventRewardMsgDesc" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/GenericTacAlertRewardMsgTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/LotusVamp_d.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/LanternEndlessEventKeyB" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/GenericEventRewardMsgDesc" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/GenericTacAlertRewardMsgTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/LotusVamp_d.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/LanternEndlessEventKeyD" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/GenericEventRewardMsgDesc" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/GenericTacAlertRewardMsgTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/LotusVamp_d.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/LanternEndlessEventKeyC" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/GenericEventRewardMsgDesc" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/GenericTacAlertRewardMsgTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/LotusVamp_d.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyHalloween" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/TacAlertHalloweenRewardsBonusBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/TacAlertHalloweenRewardsBonusTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/LotusVamp_d.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyHalloweenBonus" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/TacAlertHalloweenRewardsBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/TacAlertHalloweenRewardsTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/LotusVamp_d.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyHalloweenTimeAttack" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/TacAlertHalloweenRewardsBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/TacAlertHalloweenRewardsTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/LotusVamp_d.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyProxyRebellionOne" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/RazorbackArmadaRewardBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/GenericTacAlertSmallRewardMsgTitle" , 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-17 13:11:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "CREDIT_REWARD" ] 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyProxyRebellionTwo" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/RazorbackArmadaRewardBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/GenericTacAlertSmallRewardMsgTitle" , 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-17 13:11:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "CREDIT_REWARD" ] 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyProxyRebellionThree" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/RazorbackArmadaRewardBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/GenericTacAlertSmallRewardMsgTitle" , 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-17 13:11:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "CREDIT_REWARD" ] 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyProxyRebellionFour" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/GenericTacAlertBadgeRewardMsgDesc" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/GenericTacAlertBadgeRewardMsgTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyProjectNightwatchEasy" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/ProjectNightwatchRewardMsgA" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/ProjectNightwatchTacAlertMissionOneTitle" , 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-17 13:11:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "CREDIT_REWARD" ] 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-13 07:13:05 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyProjectNightwatch" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/ProjectNightwatchTacAlertMissionRewardBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/ProjectNightwatchTacAlertMissionTwoTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyProjectNightwatchHard" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/ProjectNightwatchTacAlertMissionRewardBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/ProjectNightwatchTacAlertMissionThreeTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyProjectNightwatchBonus" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/G1Quests/ProjectNightwatchTacAlertMissionRewardBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/G1Quests/ProjectNightwatchTacAlertMissionFourTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-16 09:52:58 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/MechSurvivalCorpusShip" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/DeimosFather" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/MechEvent2020Tier1CompleteDesc" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/MechEvent2020Tier1CompleteTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Entrati/Father.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/MechSurvivalGrineerGalleon" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/DeimosFather" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/MechEvent2020Tier2CompleteDesc" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/MechEvent2020Tier2CompleteTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Entrati/Father.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/MechSurvivalGasCity" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/DeimosFather" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/MechEvent2020Tier3CompleteDesc" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/MechEvent2020Tier3CompleteTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Entrati/Father.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/MechSurvivalCorpusShipEndurance" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/DeimosFather" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/MechEvent2020Tier3CompleteDesc" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/MechEvent2020Tier3CompleteTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Entrati/Father.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/MechSurvivalGrineerGalleonEndurance" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/DeimosFather" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Inbox/MechEvent2020Tier3CompleteDesc" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Inbox/MechEvent2020Tier3CompleteTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Entrati/Father.png" 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-17 13:11:55 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2019E" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2024RewardMsgB" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2024MissionTitleB" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2020F" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2024RewardMsgC" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2024MissionTitleB" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2024ChallengeModeA" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2024RewardMsgD" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2024MissionTitleD" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2017C" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2019RewardMsgC" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2019MissionTitleC" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2020H" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2020RewardMsgH" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2020MissionTitleH" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2022J" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2022RewardMsgJ" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2022MissionTitleJ" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2025D" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2025RewardMsgB" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2025MissionTitleB" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2025ChallengeModeA" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2025RewardMsgC" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2025MissionTitleC" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2020G" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2020RewardMsgG" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2020MissionTitleG" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2017B" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2019RewardMsgB" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2019MissionTitleB" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2017A" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2019RewardMsgA" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2019MissionTitleA" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2023K" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2025RewardMsgG" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2025MissionTitleG" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2025ChallengeModeB" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2025RewardMsgD" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2025MissionTitleD" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2025A" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2025RewardMsgA" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2025MissionTitleA" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2018D" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2024RewardMsgG" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2024MissionTitleG" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2025C" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2024RewardMsgF" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2024MissionTitleF" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2024L" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2024RewardMsgA" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2024MissionTitleA" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2024ChallengeModeB" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2024RewardMsgE" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2024MissionTitleE" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2021I" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2024RewardMsgH" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2024MissionTitleH" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    "/Lotus/Types/Keys/TacAlertKeyAnniversary2025B" :  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sndr :  "/Lotus/Language/Bosses/Lotus" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        msg :  "/Lotus/Language/Messages/Anniversary2025RewardMsgE" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        sub :  "/Lotus/Language/Messages/Anniversary2025MissionTitleE" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        icon :  "/Lotus/Interface/Icons/Npcs/Lotus_d.png" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        arg :  [ "PLAYER_NAME" ] 
							 
						 
					
						
							
								
									
										
										
										
											2025-06-25 08:04:03 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} ; 
							 
						 
					
						
							
								
									
										
										
										
											2025-08-21 11:07:31 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								const  goalMessagesByTag : Record < string ,  {  sndr :  string ;  msg :  string ;  sub :  string ;  icon :  string ;  arg ? :  string [ ]  } [ ] >  =  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    HeatFissure :  [ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            sndr :  "/Lotus/Language/Npcs/Eudico" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            msg :  "/Lotus/Language/Messages/OrbHeistEventRewardAInboxMessageBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            sub :  "/Lotus/Language/Messages/OrbHeistEventRewardAInboxMessageTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            icon :  "/Lotus/Interface/Icons/Npcs/Eudico.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            sndr :  "/Lotus/Language/Npcs/Eudico" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            msg :  "/Lotus/Language/Messages/OrbHeistEventRewardBInboxMessageBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            sub :  "/Lotus/Language/Messages/OrbHeistEventRewardBInboxMessageTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            icon :  "/Lotus/Interface/Icons/Npcs/Eudico.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            sndr :  "/Lotus/Language/Npcs/Eudico" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            msg :  "/Lotus/Language/Messages/OrbHeistEventRewardCInboxMessageBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            sub :  "/Lotus/Language/Messages/OrbHeistEventRewardCInboxMessageTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            icon :  "/Lotus/Interface/Icons/Npcs/Eudico.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            sndr :  "/Lotus/Language/Npcs/Eudico" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            msg :  "/Lotus/Language/Messages/OrbHeistEventRewardDInboxMessageBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            sub :  "/Lotus/Language/Messages/OrbHeistEventRewardDInboxMessageTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            icon :  "/Lotus/Interface/Icons/Npcs/Eudico.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            sndr :  "/Lotus/Language/Npcs/Eudico" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            msg :  "/Lotus/Language/Messages/OrbHeistEventRewardEInboxMessageBody" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            sub :  "/Lotus/Language/Messages/OrbHeistEventRewardEInboxMessageTitle" , 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								            icon :  "/Lotus/Interface/Icons/Npcs/Eudico.png" 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								        } 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    ] 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} ;