Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix RTD color rewards #325

Merged
merged 4 commits into from
Dec 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions mod/Jailbreak.RTD/RTDRewarder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,6 @@ public HookResult OnSpawn(EventPlayerSpawn @event, GameEventInfo info) {
if (reward == null) return HookResult.Continue;
if (!reward.CanGrantReward(player)) return HookResult.Continue;

player.SetColor(Color.White);

Server.RunOnTick(Server.TickCount + 2, () => {
if (!player.IsValid) return;
if (reward.Name != "Nothing")
Expand Down
1 change: 0 additions & 1 deletion mod/Jailbreak.RTD/Rewards/ColorReward.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ public bool CanGrantReward(CCSPlayerController player) {

public bool GrantReward(CCSPlayerController player) {
player.SetColor(color);
Server.RunOnTick(Server.TickCount + 2, () => GrantReward(player));
return true;
}
}
2 changes: 1 addition & 1 deletion mod/Jailbreak.RTD/Rewards/TransparentReward.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@ public class TransparentReward()
public override string Description
=> "You will spawn transparent next round.";

public override bool Enabled => false;
public override bool Enabled => true;
}
Loading