Skip to content

Commit

Permalink
fix: craft state
Browse files Browse the repository at this point in the history
  • Loading branch information
nattb8 committed Sep 23, 2024
1 parent 603fc5f commit b7434c9
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 7 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -80,4 +80,6 @@ crashlytics-build.properties
**/.DS_Store
**/._.DS_Store

.env
.env

mono_crash.*
8 changes: 4 additions & 4 deletions Assets/Shared/Scripts/UI/UnlockedSkinScreen.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public CraftSkinState? CraftState
get => m_CraftState;
set
{
m_CraftState = value;
CraftState = value;
switch (m_CraftState)
{
case CraftSkinState.Crafting:
Expand Down Expand Up @@ -113,12 +113,12 @@ public async void OnEnable()

private async void Craft()
{
m_CraftState = CraftSkinState.Crafting;
CraftState = CraftSkinState.Crafting;

// Burn tokens and mint a new skin i.e. crafting a skin
await Task.Delay(TimeSpan.FromSeconds(5));

m_CraftState = CraftSkinState.Crafted;
CraftState = CraftSkinState.Crafted;

// If successfully crafted skin and this screen is visible, go to collect skin screen
// otherwise it will be picked in the OnEnable function above when this screen reappears
Expand All @@ -131,7 +131,7 @@ private async void Craft()
private void CollectSkin()
{
m_CollectSkinEvent.Raise();
m_CraftState = null;
CraftState = null;
}

private void OnCraftButtonClicked()
Expand Down
2 changes: 1 addition & 1 deletion ProjectSettings/PackageManagerSettings.asset
Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,5 @@ MonoBehaviour:
m_Modified: 0
m_ErrorMessage:
m_UserModificationsInstanceId: -828
m_OriginalInstanceId: -830
m_OriginalInstanceId: -832
m_LoadAssets: 0
4 changes: 3 additions & 1 deletion mint-backend/.gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
/node_modules
/node_modules
/dist
/.parcel-cache

0 comments on commit b7434c9

Please sign in to comment.