Skip to content

Commit

Permalink
Merge pull request #23 from Synthesis-Collective/remove-targeted-effects
Browse files Browse the repository at this point in the history
Remove targeted effects
  • Loading branch information
EzioTheDeadPoet authored Jul 10, 2021
2 parents 9e4b4ae + 68fd451 commit 4e9f34b
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions SlotsSlotsSlots/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public static void RunPatch(IPatcherState<ISkyrimMod, ISkyrimModGetter> state)
e.Data.Magnitude *= effectMultiplier;
carryWeightSpells.Add((spell.AsLink(), (int)e.Data.Magnitude));
if (!(spell.Description.ToString().IsNullOrWhitespace())) deepCopySpell.Description += $"\n Alters your inventory space by {e.Data.Magnitude} Slots.";
state.PatchMod.Spells.Set(deepCopySpell);
state.PatchMod.Spells.Set(deepCopySpell);
}
}
};
Expand All @@ -87,11 +87,7 @@ public static void RunPatch(IPatcherState<ISkyrimMod, ISkyrimModGetter> state)

if (perk.Effects.Count > 1 && !perk.Description.ToString().IsNullOrWhitespace())
{
deepcopyPerk.Description += $"\n This will result in a Slots change by {carryWeightSpell.SlotAmount}.";
}
else if (!perk.Description.ToString().IsNullOrWhitespace())
{
deepcopyPerk.Description += $"\n Takes up {carryWeightSpell.SlotAmount} Slots.";
deepcopyPerk.Description += $"\n This will result in a Inventory change of {carryWeightSpell.SlotAmount} Slots.";
}
}
}
Expand Down Expand Up @@ -283,7 +279,9 @@ private static (HashSet<IFormLinkGetter<IMagicEffectGetter>>, HashSet<IFormLinkG
var foundHealth = new HashSet<IFormLinkGetter<IMagicEffectGetter>>();
foreach (var e in state.LoadOrder.PriorityOrder.MagicEffect().WinningOverrides())
{
if (e.Archetype.ActorValue.Equals(ActorValue.CarryWeight))
if (e.Archetype.ActorValue.Equals(ActorValue.CarryWeight)
&& e.TargetType != TargetType.Aimed
&& e.TargetType != TargetType.Touch)
{
foundCarryWeight.Add(e.AsLink());
}
Expand Down

0 comments on commit 4e9f34b

Please sign in to comment.