Skip to content

Commit

Permalink
Merge pull request #1306 from Tommy-XL/BugFix/RolesBasedEngineerCanBe…
Browse files Browse the repository at this point in the history
…StuckInVent

Bug Fix /  Engineer based role can be stuck in vent during comms sabotage
  • Loading branch information
Hyz-sui authored Jan 24, 2024
2 parents 54f6e43 + 6a6cd3f commit 05fde69
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Patches/UsablesPatch.cs
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public static bool Prefix(Vent __instance, [HarmonyArgument(0)] GameData.PlayerI

// カスタムロールを元にベントを使えるか判定
// エンジニアベースの役職は常にtrue
couldUse = playerControl.CanUseImpostorVentButton() || pc.Role.Role == RoleTypes.Engineer;
couldUse = playerControl.CanUseImpostorVentButton() || (pc.Role.Role == RoleTypes.Engineer && pc.Role.CanUse(__instance.Cast<IUsable>()));

canUse = couldUse;
// カスタムロールが使えなかったら使用不可
Expand Down

0 comments on commit 05fde69

Please sign in to comment.