Skip to content
This repository was archived by the owner on Jul 2, 2024. It is now read-only.

Commit f2f567a

Browse files
author
sumghai
committed
Fix NullRef when feeding wounded animals from Terminals
1 parent acc57f1 commit f2f567a

File tree

2 files changed

+1
-1
lines changed

2 files changed

+1
-1
lines changed

1.3/Assemblies/Replimat.dll

0 Bytes
Binary file not shown.

Source/ReplimatUtility.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ public static void GenerateIngredients(Thing meal, Pawn eater)
218218
Ideo ideo = eater.Ideo;
219219

220220
// 2.1 Human cannibalism for meals containing meat
221-
if (ideo?.HasHumanMeatEatingRequiredPrecept() == true || eater.story.traits.HasTrait(TraitDefOf.Cannibal))
221+
if (ideo?.HasHumanMeatEatingRequiredPrecept() == true || (eater.story?.traits.HasTrait(TraitDefOf.Cannibal) ?? false))
222222
{
223223
List<ThingDef> existingMeats = ingredientThingDefs.FindAll((ThingDef d) => d.thingCategories.Contains(ThingCategoryDefOf.MeatRaw));
224224

0 commit comments

Comments
 (0)