mirror of
https://github.com/Gurge44/EndlessHostRoles.git
synced 2026-10-20 01:46:25 +00:00
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
This commit is contained in:
1 parent
32e44209e0
commit
c609450ec3
21 files changed
+99
-140
No files matched your search
@@ -746,6 +746,8 @@ internal static class MurderPlayerPatch
|
||||
Main.PlayerStates[killer.PlayerId].Role.OnMurder(killer, target);
|
||||
|
||||
Chef.SpitOutFood(killer);
|
||||
|
||||
EvilTracker.OnAnyoneMurder(killer, target);
|
||||
|
||||
if (Options.CurrentGameMode == CustomGameMode.Speedrun)
|
||||
Speedrun.ResetTimer(killer);
|
||||
@@ -2076,21 +2078,13 @@ internal static class FixedUpdatePatch
|
||||
{
|
||||
if (Main.HasJustStarted || !player.IsAlive()) return;
|
||||
|
||||
if (Main.PlayerStates[player.PlayerId].Role is Mechanic sm)
|
||||
{
|
||||
sm.UsedSkillCount -= Mechanic.AbilityChargesWhenFinishedTasks.GetFloat();
|
||||
sm.SendRPC();
|
||||
}
|
||||
else
|
||||
{
|
||||
float add = GetSettingNameAndValueForRole(player.GetCustomRole(), "AbilityChargesWhenFinishedTasks");
|
||||
float add = GetSettingNameAndValueForRole(player.GetCustomRole(), "AbilityChargesWhenFinishedTasks");
|
||||
|
||||
if (Math.Abs(add - float.MaxValue) > 0.5f && add > 0)
|
||||
{
|
||||
if (player.Is(CustomRoles.Bloodlust)) add *= 5;
|
||||
if (Math.Abs(add - float.MaxValue) > 0.5f && add > 0)
|
||||
{
|
||||
if (player.Is(CustomRoles.Bloodlust)) add *= 5;
|
||||
|
||||
player.RpcIncreaseAbilityUseLimitBy(add);
|
||||
}
|
||||
player.RpcIncreaseAbilityUseLimitBy(add);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user