Fix VoteAvatars which are zombies with custom skins
This commit is contained in:
parent
8764546768
commit
f3ba03ff45
1 changed files with 5 additions and 5 deletions
|
@ -1,9 +1,5 @@
|
||||||
using HarmonyLib;
|
using HarmonyLib;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
namespace CustomCosmeticLoader.Patches
|
namespace CustomCosmeticLoader.Patches
|
||||||
|
@ -20,12 +16,16 @@ namespace CustomCosmeticLoader.Patches
|
||||||
if (!Config.enabled)
|
if (!Config.enabled)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
// Don't override zombies
|
||||||
|
if (__instance.widget.cosmeticDisplay.cosmetic.Id == "Zombie")
|
||||||
|
return;
|
||||||
|
|
||||||
Texture2D skin = null;
|
Texture2D skin = null;
|
||||||
if (marble.isMyClientMarble())
|
if (marble.isMyClientMarble())
|
||||||
{
|
{
|
||||||
skin = Config.skins[Config.currentSkin];
|
skin = Config.skins[Config.currentSkin];
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (Config.otherPlayers.ContainsKey(marble.nickname))
|
if (Config.otherPlayers.ContainsKey(marble.nickname))
|
||||||
skin = Config.skins[Config.otherPlayers[marble.nickname]];
|
skin = Config.skins[Config.otherPlayers[marble.nickname]];
|
||||||
|
|
Loading…
Add table
Reference in a new issue