From 8c81a72bb820eb878f3945934fcea6647ea85365 Mon Sep 17 00:00:00 2001 From: AliIbnAbiTalib Date: Mon, 3 Apr 2023 21:20:38 +0200 Subject: [PATCH] =?UTF-8?q?=C3=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- FlufflParty/Assets/Scripts/Players/PlayablePlayer.cs | 2 +- FlufflParty/Assets/Scripts/Players/Player.cs | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/FlufflParty/Assets/Scripts/Players/PlayablePlayer.cs b/FlufflParty/Assets/Scripts/Players/PlayablePlayer.cs index ec76cbb..592d0ad 100644 --- a/FlufflParty/Assets/Scripts/Players/PlayablePlayer.cs +++ b/FlufflParty/Assets/Scripts/Players/PlayablePlayer.cs @@ -357,7 +357,6 @@ public class PlayablePlayer : Player activeItem = items[index].type; imageCurrentItem.sprite = items[index].sprite; imageCurrentItem.color = new Color(1, 1, 1, 1); - items[index] = null; itemInfoImages[index].color = new Color(0, 0, 0, 0); client.SendActiveItem((byte)index); if (items[index].type == Item.Type.Trap) @@ -367,5 +366,6 @@ public class PlayablePlayer : Player temp.transform.position = currentField.transform.position + (Vector3.up / 2); activeItem = Item.Type.None; } + items[index] = null; } } \ No newline at end of file diff --git a/FlufflParty/Assets/Scripts/Players/Player.cs b/FlufflParty/Assets/Scripts/Players/Player.cs index 34d66ca..8705851 100644 --- a/FlufflParty/Assets/Scripts/Players/Player.cs +++ b/FlufflParty/Assets/Scripts/Players/Player.cs @@ -106,7 +106,6 @@ public abstract class Player : MonoBehaviour imageCurrentItem.sprite = items[index].sprite; imageCurrentItem.color = new Color(1, 1, 1, 1); itemInfoImages[index].color = new Color(0, 0, 0, 0); - items[index] = null; if (items[index].type == Item.Type.Trap) { currentField.placedItem = items[index]; @@ -114,7 +113,7 @@ public abstract class Player : MonoBehaviour temp.transform.position = currentField.transform.position + (Vector3.up / 2); activeItem = Item.Type.None; } - + items[index] = null; } public void OnTriggerEnter(Collider c)