mirror of
				https://gitgud.io/amevarashi/rjw-sexperience-ideology.git
				synced 2024-08-15 00:43:19 +00:00 
			
		
		
		
	Debug action to test marriage event
This commit is contained in:
		
							parent
							
								
									2f9bd5bbf9
								
							
						
					
					
						commit
						94088dca61
					
				
					 1 changed files with 20 additions and 0 deletions
				
			
		
							
								
								
									
										20
									
								
								Source/IdeologyAddon/DebugAction.cs
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								Source/IdeologyAddon/DebugAction.cs
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,20 @@
 | 
				
			||||||
 | 
					using rjw;
 | 
				
			||||||
 | 
					using RJWSexperience.Ideology.HistoryEvents;
 | 
				
			||||||
 | 
					using System.Linq;
 | 
				
			||||||
 | 
					using Verse;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					namespace RJWSexperience.Ideology
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
						internal class DebugAction
 | 
				
			||||||
 | 
						{
 | 
				
			||||||
 | 
							[DebugAction("RJW Sexperience Ideology", "Test marriage event", false, false, actionType = DebugActionType.ToolMapForPawns, allowedGameStates = AllowedGameStates.PlayingOnMap)]
 | 
				
			||||||
 | 
							private static void GenerateMarriageEvent(Pawn p)
 | 
				
			||||||
 | 
							{
 | 
				
			||||||
 | 
								Pawn hero = p.Map.PlayerPawnsForStoryteller.First(x => x.IsDesignatedHero());
 | 
				
			||||||
 | 
								if (hero == null)
 | 
				
			||||||
 | 
									return;
 | 
				
			||||||
 | 
								RsiHistoryEventDefOf.RSI_NonIncestuosMarriage.RecordEventWithPartner(hero, p);
 | 
				
			||||||
 | 
								RsiHistoryEventDefOf.RSI_NonIncestuosMarriage.RecordEventWithPartner(p, hero);
 | 
				
			||||||
 | 
							}
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue