Skip to content

Commit

Permalink
Change model r, g, b values to 255
Browse files Browse the repository at this point in the history
  • Loading branch information
razpbrry committed Mar 18, 2024
1 parent fe6ae33 commit 54a95b4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/ImperfectModels.cs
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ private void OnPlayerConnect(CCSPlayerController? player, bool isForBot = false)

try
{
player.PlayerPawn.Value.Render = Color.FromArgb(Config.DefaultAlpha, 254, 254, 254);
player.PlayerPawn.Value.Render = Color.FromArgb(Config.DefaultAlpha, 255, 255, 255);
Utilities.SetStateChanged(player.PlayerPawn.Value, "CBaseModelEntity", "m_clrRender");
}
catch (Exception ex)
Expand Down Expand Up @@ -152,7 +152,7 @@ public void ChangeSelfModelAlphaCommand(CCSPlayerController? player, CommandInfo
{
try
{
player.PlayerPawn.Value.Render = Color.FromArgb(alphaPercentageInt, 254, 254, 254);
player.PlayerPawn.Value.Render = Color.FromArgb(alphaPercentageInt, 255, 255, 255);

Check warning on line 155 in src/ImperfectModels.cs

View workflow job for this annotation

GitHub Actions / build

Dereference of a possibly null reference.

Check warning on line 155 in src/ImperfectModels.cs

View workflow job for this annotation

GitHub Actions / build

Dereference of a possibly null reference.

Check warning on line 155 in src/ImperfectModels.cs

View workflow job for this annotation

GitHub Actions / build

Dereference of a possibly null reference.

Check warning on line 155 in src/ImperfectModels.cs

View workflow job for this annotation

GitHub Actions / publish

Dereference of a possibly null reference.

Check warning on line 155 in src/ImperfectModels.cs

View workflow job for this annotation

GitHub Actions / publish

Dereference of a possibly null reference.
Utilities.SetStateChanged(player.PlayerPawn.Value, "CBaseModelEntity", "m_clrRender");

commandInfo.ReplyToCommand($"Player model alpha set to {alphaPercentage}");
Expand Down Expand Up @@ -192,7 +192,7 @@ public void ChangeModelAlphaCommand(CCSPlayerController? player, CommandInfo com
{
foreach (var connectedPlayer in ConnectedPlayers.Values)
{
connectedPlayer.PlayerPawn.Value.Render = Color.FromArgb(alphaPercentageInt, 254, 254, 254);
connectedPlayer.PlayerPawn.Value.Render = Color.FromArgb(alphaPercentageInt, 255, 255, 255);

Check warning on line 195 in src/ImperfectModels.cs

View workflow job for this annotation

GitHub Actions / build

Dereference of a possibly null reference.

Check warning on line 195 in src/ImperfectModels.cs

View workflow job for this annotation

GitHub Actions / publish

Dereference of a possibly null reference.
Utilities.SetStateChanged(connectedPlayer.PlayerPawn.Value, "CBaseModelEntity", "m_clrRender");
}

Expand Down

0 comments on commit 54a95b4

Please sign in to comment.