Skip to content

Commit

Permalink
Added set and get influence
Browse files Browse the repository at this point in the history
  • Loading branch information
Bonjemus committed Dec 24, 2024
1 parent 1a32168 commit 4f0dfe6
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions EXILED/Exiled.API/Features/Respawn.cs
Original file line number Diff line number Diff line change
Expand Up @@ -346,6 +346,26 @@ public static void RemoveInfluence(Faction faction, int amount)
FactionInfluenceManager.Remove(faction, amount);
}

/// <summary>
/// Get influence to a given <see cref="Faction"/>.
/// </summary>
/// <param name="faction">The <see cref="Faction"/> to get influence.</param>
/// <returns>Get the faction influence..</returns>
public static float GetInfluence(Faction faction)
{
return FactionInfluenceManager.Get(faction);
}

/// <summary>
/// Set influence to a given <see cref="Faction"/>.
/// </summary>
/// <param name="faction">The <see cref="Faction"/> to set influence.</param>
/// <param name="influence">The amount of influence to set.</param>
public static void SetInfluence(Faction faction, float influence)
{
FactionInfluenceManager.Set(faction, influence);
}

/// <summary>
/// Starts the spawn sequence of the given <see cref="Faction"/>.
/// </summary>
Expand Down

0 comments on commit 4f0dfe6

Please sign in to comment.