forked from OpenWF/SpaceNinjaServer
		
	fix: set ModQuestTeshinAccess when using cheats to complete mod quest (#2935)
This is required to go to Teshin's relay room after U40. Reviewed-on: OpenWF/SpaceNinjaServer#2935 Co-authored-by: Sainan <63328889+Sainan@users.noreply.github.com> Co-committed-by: Sainan <63328889+Sainan@users.noreply.github.com>
This commit is contained in:
		
							parent
							
								
									482101ccd0
								
							
						
					
					
						commit
						0d21c73ab7
					
				@ -11,6 +11,7 @@ import { addFixedLevelRewards } from "./missionInventoryUpdateService.ts";
 | 
				
			|||||||
import type { IInventoryChanges } from "../types/purchaseTypes.ts";
 | 
					import type { IInventoryChanges } from "../types/purchaseTypes.ts";
 | 
				
			||||||
import questCompletionItems from "../../static/fixed_responses/questCompletionRewards.json" with { type: "json" };
 | 
					import questCompletionItems from "../../static/fixed_responses/questCompletionRewards.json" with { type: "json" };
 | 
				
			||||||
import type { ITypeCount } from "../types/commonTypes.ts";
 | 
					import type { ITypeCount } from "../types/commonTypes.ts";
 | 
				
			||||||
 | 
					import { addString } from "../helpers/stringHelpers.ts";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
export interface IUpdateQuestRequest {
 | 
					export interface IUpdateQuestRequest {
 | 
				
			||||||
    QuestKeys: IQuestKeyClient[];
 | 
					    QuestKeys: IQuestKeyClient[];
 | 
				
			||||||
@ -175,6 +176,11 @@ export const completeQuest = async (
 | 
				
			|||||||
        existingQuestKey.Completed = true;
 | 
					        existingQuestKey.Completed = true;
 | 
				
			||||||
        existingQuestKey.CompletionDate = new Date();
 | 
					        existingQuestKey.CompletionDate = new Date();
 | 
				
			||||||
        await handleQuestCompletion(inventory, questKey, undefined, run > 0);
 | 
					        await handleQuestCompletion(inventory, questKey, undefined, run > 0);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        if (questKey == "/Lotus/Types/Keys/ModQuest/ModQuestKeyChain") {
 | 
				
			||||||
 | 
					            // This would be set by the client during the equilogue, but since we're cheating through, we have to do it ourselves.
 | 
				
			||||||
 | 
					            addString(inventory.NodeIntrosCompleted, "ModQuestTeshinAccess");
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    return existingQuestKey.toJSON<IQuestKeyClient>();
 | 
					    return existingQuestKey.toJSON<IQuestKeyClient>();
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user