[TASK] Added more duck spawn, performance fixes, instruction in the minigame, option to zoom in on stickers

This commit is contained in:
2019-08-30 00:39:13 +02:00
parent bb4b5afb18
commit c60a130874
51 changed files with 86781 additions and 45090 deletions

View File

@@ -7,12 +7,14 @@ public class CollectedStickersUI : MonoBehaviour
{
public Transform collectedStickerParent;
public StickerDisplay stickerDisplayPrefab;
public StickerZoomDisplay stickerZoomDisplay;
private readonly Dictionary<DuckStickerData, StickerDisplay> _stickerDisplays = new Dictionary<DuckStickerData, StickerDisplay>();
private void Start()
{
RefreshStickerDisplay();
stickerZoomDisplay.Hide();
}
public void OnStickerCollected(DuckStickerData sticker)
@@ -29,9 +31,19 @@ public class CollectedStickersUI : MonoBehaviour
{
var stickerDisplay = Instantiate(stickerDisplayPrefab, collectedStickerParent);
stickerDisplay.Sticker = sticker;
stickerDisplay.StickerClicked += (sender, obj) =>
{
stickerZoomDisplay.Sticker = obj;
stickerZoomDisplay.Show();
};
_stickerDisplays.Add(sticker, stickerDisplay);
}
_stickerDisplays[sticker].CollectedCount = DuckStickerManager.Instance.GetStickerCollectedCount(sticker);
}
}
public void OnCloseClicked()
{
BadeendGoGameManager.Instance.GameState = GameState.Map;
}
}