@jeremyckahn/farmhand 1.19.21 → 1.19.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/{index-CG_lY1MJ.js → index-BjAIF9CZ.js} +7 -7
- package/dist/assets/{index-CG_lY1MJ.js.map → index-BjAIF9CZ.js.map} +1 -1
- package/dist/index.html +1 -1
- package/dist/service-worker.js +1 -1
- package/dist/service-worker.js.map +1 -1
- package/package.json +2 -3
- package/src/common/services/{randomNumber.ts → randomNumber.js} +0 -1
- package/src/common/{utils.ts → utils.js} +1 -1
- package/src/components/AccountingView/{AccountingView.tsx → AccountingView.js} +0 -1
- package/src/components/AchievementsView/{AchievementsView.tsx → AchievementsView.js} +0 -2
- package/src/components/AnimatedNumber/{AnimatedNumber.tsx → AnimatedNumber.js} +0 -3
- package/src/components/AppBar/{AppBar.tsx → AppBar.js} +0 -3
- package/src/components/BailOutErrorBoundary/{BailOutErrorBoundary.tsx → BailOutErrorBoundary.js} +0 -2
- package/src/components/Cellar/{CellarInventoryTabPanel.tsx → CellarInventoryTabPanel.js} +0 -2
- package/src/components/Cellar/{Keg.tsx → Keg.js} +1 -0
- package/src/components/ContextPane/{ContextPane.tsx → ContextPane.js} +0 -2
- package/src/components/ContextPane/{ContextPane.test.tsx → ContextPane.test.js} +0 -3
- package/src/components/CowCard/Bloodline/{Bloodline.test.tsx → Bloodline.test.js} +3 -6
- package/src/components/CowCard/{CowCard.tsx → CowCard.js} +2 -4
- package/src/components/CowCard/Subheader/{Subheader.tsx → Subheader.js} +0 -1
- package/src/components/CowPen/{Cow.tsx → Cow.js} +1 -15
- package/src/components/CowPen/{CowPen.test.tsx → CowPen.test.js} +1 -15
- package/src/components/CowPen/{Tumbleweeds.tsx → Tumbleweeds.js} +1 -2
- package/src/components/Farmhand/{Farmhand.context.tsx → Farmhand.context.js} +2 -2
- package/src/components/Farmhand/{Farmhand.tsx → Farmhand.js} +16 -83
- package/src/components/FermentationRecipeList/{FermentationRecipe.tsx → FermentationRecipe.js} +3 -4
- package/src/components/FermentationRecipeList/{FermentationRecipeList.tsx → FermentationRecipeList.js} +0 -3
- package/src/components/FermentationRecipeList/{FermentationRecipeList.test.tsx → FermentationRecipeList.test.js} +0 -5
- package/src/components/Field/{Field.tsx → Field.js} +1 -6
- package/src/components/Field/{Field.test.tsx → Field.test.js} +1 -0
- package/src/components/Home/{Home.tsx → Home.js} +0 -1
- package/src/components/Home/{SnowBackground.tsx → SnowBackground.js} +0 -2
- package/src/components/Inventory/{Inventory.tsx → Inventory.js} +2 -9
- package/src/components/Item/{Item.tsx → Item.js} +1 -2
- package/src/components/LogView/{LogView.tsx → LogView.js} +1 -2
- package/src/components/Navigation/{Navigation.tsx → Navigation.js} +1 -0
- package/src/components/NotificationSystem/{NotificationSystem.tsx → NotificationSystem.js} +1 -0
- package/src/components/OnlinePeersView/{OnlinePeersView.tsx → OnlinePeersView.js} +1 -1
- package/src/components/Plot/{Plot.tsx → Plot.js} +0 -5
- package/src/components/Plot/{Plot.test.tsx → Plot.test.js} +8 -8
- package/src/components/PriceEventView/{PriceEventView.test.tsx → PriceEventView.test.js} +0 -1
- package/src/components/ProgressBar/{ProgressBar.tsx → ProgressBar.js} +0 -2
- package/src/components/QuantityInput/{QuantityInput.tsx → QuantityInput.js} +0 -1
- package/src/components/Recipe/{Recipe.tsx → Recipe.js} +2 -1
- package/src/components/SettingsView/{RandomSeedInput.tsx → RandomSeedInput.js} +1 -1
- package/src/components/Shop/{Shop.tsx → Shop.js} +1 -2
- package/src/components/Stage/{Stage.tsx → Stage.js} +3 -6
- package/src/components/Stage/{Stage.test.tsx → Stage.test.js} +0 -1
- package/src/components/Toolbelt/{Toolbelt.tsx → Toolbelt.js} +0 -3
- package/src/components/UpgradePurchase/{UpgradePurchase.tsx → UpgradePurchase.js} +1 -0
- package/src/components/WineRecipeList/{WineRecipe.tsx → WineRecipe.js} +1 -2
- package/src/components/WineRecipeList/{WineRecipe.test.tsx → WineRecipe.test.js} +1 -10
- package/src/components/WineRecipeList/{WineRecipeList.tsx → WineRecipeList.js} +0 -1
- package/src/components/Workshop/{ForgeTabPanel.tsx → ForgeTabPanel.js} +0 -1
- package/src/components/Workshop/{getUpgradesAvailable.ts → getUpgradesAvailable.js} +0 -2
- package/src/components/Workshop/{getUpgradesAvailable.test.ts → getUpgradesAvailable.test.js} +0 -1
- package/src/{constants.ts → constants.js} +2 -2
- package/src/data/{achievements.ts → achievements.js} +0 -9
- package/src/data/{achievements.test.ts → achievements.test.js} +1 -2
- package/src/data/{crop.ts → crop.js} +4 -5
- package/src/data/crops/{asparagus.ts → asparagus.js} +0 -2
- package/src/data/crops/{carrot.ts → carrot.js} +0 -2
- package/src/data/crops/{corn.ts → corn.js} +0 -2
- package/src/data/crops/{garlic.ts → garlic.js} +0 -2
- package/src/data/crops/{grape.ts → grape.js} +7 -11
- package/src/data/crops/{jalapeno.ts → jalapeno.js} +0 -2
- package/src/data/crops/{olive.ts → olive.js} +0 -2
- package/src/data/crops/{onion.ts → onion.js} +0 -2
- package/src/data/crops/{pea.ts → pea.js} +0 -2
- package/src/data/crops/{potato.ts → potato.js} +0 -2
- package/src/data/crops/{pumpkin.ts → pumpkin.js} +0 -2
- package/src/data/crops/{soybean.ts → soybean.js} +0 -2
- package/src/data/crops/{spinach.ts → spinach.js} +0 -2
- package/src/data/crops/{strawberry.ts → strawberry.js} +0 -2
- package/src/data/crops/{sunflower.ts → sunflower.js} +0 -2
- package/src/data/crops/{sweet-potato.ts → sweet-potato.js} +0 -2
- package/src/data/crops/{tomato.ts → tomato.js} +0 -2
- package/src/data/crops/{watermelon.ts → watermelon.js} +0 -2
- package/src/data/crops/{wheat.ts → wheat.js} +0 -2
- package/src/data/{items.ts → items.js} +12 -12
- package/src/data/{levels.ts → levels.js} +0 -28
- package/src/data/{maps.ts → maps.js} +1 -2
- package/src/data/ores/{bronzeOre.ts → bronzeOre.js} +1 -1
- package/src/data/ores/{coal.ts → coal.js} +1 -1
- package/src/data/ores/{goldOre.ts → goldOre.js} +1 -1
- package/src/data/ores/{ironOre.ts → ironOre.js} +1 -1
- package/src/data/ores/{saltRock.ts → saltRock.js} +1 -1
- package/src/data/ores/{silverOre.ts → silverOre.js} +1 -1
- package/src/data/ores/{stone.ts → stone.js} +1 -1
- package/src/data/{recipes.ts → recipes.js} +43 -43
- package/src/{enums.ts → enums.js} +28 -28
- package/src/factories/{CoalFactory.ts → CoalFactory.js} +0 -2
- package/src/factories/{OreFactory.ts → OreFactory.js} +0 -3
- package/src/factories/{ResourceFactory.ts → ResourceFactory.js} +0 -4
- package/src/factories/{ResourceFactory.test.ts → ResourceFactory.test.js} +0 -4
- package/src/factories/{StoneFactory.ts → StoneFactory.js} +0 -1
- package/src/{fetch-utils.ts → fetch-utils.js} +0 -2
- package/src/game-logic/{field-purchase.test.ts → field-purchase.test.js} +2 -4
- package/src/game-logic/reducers/{applyCrows.ts → applyCrows.js} +0 -3
- package/src/game-logic/reducers/{applyLoanInterest.ts → applyLoanInterest.js} +1 -1
- package/src/game-logic/reducers/{applyPrecipitation.ts → applyPrecipitation.js} +6 -6
- package/src/game-logic/reducers/{computeStateForNextDay.ts → computeStateForNextDay.js} +2 -2
- package/src/game-logic/reducers/{makeFermentationRecipe.ts → makeFermentationRecipe.js} +0 -1
- package/src/game-logic/reducers/{makeWine.ts → makeWine.js} +0 -1
- package/src/game-logic/reducers/{makeWine.test.ts → makeWine.test.js} +2 -0
- package/src/game-logic/reducers/{minePlot.ts → minePlot.js} +0 -1
- package/src/game-logic/reducers/{processCellarSpoilage.ts → processCellarSpoilage.js} +1 -0
- package/src/game-logic/reducers/{processCellarSpoilage.test.ts → processCellarSpoilage.test.js} +5 -0
- package/src/game-logic/reducers/{processCowFertilizerProduction.ts → processCowFertilizerProduction.js} +1 -1
- package/src/game-logic/reducers/{processLevelUp.ts → processLevelUp.js} +0 -3
- package/src/game-logic/reducers/{purchaseField.test.ts → purchaseField.test.js} +0 -2
- package/src/game-logic/reducers/{purchaseForest.test.tsx → purchaseForest.test.js} +2 -6
- package/src/game-logic/reducers/{rotateNotificationLogs.ts → rotateNotificationLogs.js} +1 -1
- package/src/game-logic/reducers/{sellItem.test.ts → sellItem.test.js} +3 -0
- package/src/game-logic/reducers/{sellKeg.ts → sellKeg.js} +1 -0
- package/src/game-logic/reducers/{spawnWeeds.ts → spawnWeeds.js} +0 -1
- package/src/game-logic/reducers/{updateAchievements.ts → updateAchievements.js} +0 -1
- package/src/game-logic/reducers/{updatePeer.ts → updatePeer.js} +0 -1
- package/src/game-logic/reducers/{updatePeer.test.ts → updatePeer.test.js} +4 -0
- package/src/game-logic/reducers/{updatePlotShoveledState.test.ts → updatePlotShoveledState.test.js} +1 -0
- package/src/handlers/{peer-events.ts → peer-events.js} +0 -5
- package/src/handlers/{ui-events.tsx → ui-events.js} +6 -88
- package/src/handlers/{ui-events.test.ts → ui-events.test.js} +0 -2
- package/src/{index.tsx → index.js} +0 -2
- package/src/scripts/{generate-crop-table.ts → generate-crop-table.js} +4 -5
- package/src/services/{cellar.test.ts → cellar.test.js} +1 -1
- package/src/services/{wine.ts → wine.js} +0 -1
- package/src/shell/{notifications.test.ts → notifications.test.js} +13 -19
- package/src/{templates.ts → templates.js} +0 -8
- package/src/test-utils/{index.ts → index.js} +3 -3
- package/src/test-utils/stubs/{getKegStub.ts → getKegStub.js} +0 -1
- package/src/utils/{farmProductsSold.tsx → farmProductsSold.js} +0 -2
- package/src/utils/{getCropLifecycleDuration.ts → getCropLifecycleDuration.js} +0 -1
- package/src/utils/{getCropsAvailableToFerment.ts → getCropsAvailableToFerment.js} +0 -1
- package/src/utils/{getInventoryQuantityMap.ts → getInventoryQuantityMap.js} +0 -1
- package/src/utils/{getLevelEntitlements.ts → getLevelEntitlements.js} +0 -4
- package/src/utils/{getMaxYieldOfFermentationRecipe.ts → getMaxYieldOfFermentationRecipe.js} +0 -1
- package/src/utils/{getWineVarietiesAvailableToMake.ts → getWineVarietiesAvailableToMake.js} +0 -2
- package/src/utils/{index.tsx → index.js} +11 -25
- package/src/utils/{index.test.ts → index.test.js} +2 -0
- package/src/utils/{isItemAFarmProduct.ts → isItemAFarmProduct.js} +1 -1
- package/src/utils/{memoize.ts → memoize.js} +0 -2
- package/src/utils/{totalIngredientsInRecipe.ts → totalIngredientsInRecipe.js} +0 -2
- /package/src/common/{constants.ts → constants.js} +0 -0
- /package/src/common/services/{randomNumber.test.ts → randomNumber.test.js} +0 -0
- /package/src/common/{utils.test.ts → utils.test.js} +0 -0
- /package/src/components/AccountingView/{AccountingView.test.tsx → AccountingView.test.js} +0 -0
- /package/src/components/AccountingView/{index.ts → index.js} +0 -0
- /package/src/components/Achievement/{Achievement.tsx → Achievement.js} +0 -0
- /package/src/components/Achievement/{Achievement.test.tsx → Achievement.test.js} +0 -0
- /package/src/components/Achievement/{index.ts → index.js} +0 -0
- /package/src/components/AchievementsView/{AchievementsView.test.tsx → AchievementsView.test.js} +0 -0
- /package/src/components/AchievementsView/{index.ts → index.js} +0 -0
- /package/src/components/AnimatedNumber/{AnimatedNumber.test.tsx → AnimatedNumber.test.js} +0 -0
- /package/src/components/AnimatedNumber/{index.ts → index.js} +0 -0
- /package/src/components/AppBar/{AppBar.test.tsx → AppBar.test.js} +0 -0
- /package/src/components/AppBar/{index.ts → index.js} +0 -0
- /package/src/components/BailOutErrorBoundary/{BailOutErrorBoundary.test.tsx → BailOutErrorBoundary.test.js} +0 -0
- /package/src/components/BailOutErrorBoundary/{index.ts → index.js} +0 -0
- /package/src/components/Cellar/{Cellar.tsx → Cellar.js} +0 -0
- /package/src/components/Cellar/{FermentationTabPanel.tsx → FermentationTabPanel.js} +0 -0
- /package/src/components/Cellar/TabPanel/{index.tsx → index.js} +0 -0
- /package/src/components/Cellar/{WinemakingTabPanel.tsx → WinemakingTabPanel.js} +0 -0
- /package/src/components/Cellar/{index.ts → index.js} +0 -0
- /package/src/components/ChatRoom/{ChatRoom.tsx → ChatRoom.js} +0 -0
- /package/src/components/ChatRoom/{index.ts → index.js} +0 -0
- /package/src/components/ContextPane/{index.ts → index.js} +0 -0
- /package/src/components/CowCard/Bloodline/{Bloodline.tsx → Bloodline.js} +0 -0
- /package/src/components/CowCard/Bloodline/{index.ts → index.js} +0 -0
- /package/src/components/CowCard/{CowCard.test.tsx → CowCard.test.js} +0 -0
- /package/src/components/CowCard/Subheader/{Subheader.test.tsx → Subheader.test.js} +0 -0
- /package/src/components/CowCard/Subheader/{index.ts → index.js} +0 -0
- /package/src/components/CowCard/{index.ts → index.js} +0 -0
- /package/src/components/CowPen/{CowPen.tsx → CowPen.js} +0 -0
- /package/src/components/CowPen/{index.ts → index.js} +0 -0
- /package/src/components/CowPenContextMenu/{CowPenContextMenu.tsx → CowPenContextMenu.js} +0 -0
- /package/src/components/CowPenContextMenu/{CowPenContextMenu.test.tsx → CowPenContextMenu.test.js} +0 -0
- /package/src/components/CowPenContextMenu/TabPanel/{index.tsx → index.js} +0 -0
- /package/src/components/CowPenContextMenu/{index.ts → index.js} +0 -0
- /package/src/components/Elements/{index.ts → index.js} +0 -0
- /package/src/components/Farmhand/{Farmhand.test.ts → Farmhand.test.js} +0 -0
- /package/src/components/Farmhand/{FarmhandReducers.tsx → FarmhandReducers.js} +0 -0
- /package/src/components/Farmhand/helpers/{getInventoryQuantities.ts → getInventoryQuantities.js} +0 -0
- /package/src/components/Farmhand/helpers/{getInventoryQuantities.test.ts → getInventoryQuantities.test.js} +0 -0
- /package/src/components/Farmhand/{index.ts → index.js} +0 -0
- /package/src/components/Field/{index.ts → index.js} +0 -0
- /package/src/components/Forest/{Forest.tsx → Forest.js} +0 -0
- /package/src/components/Forest/{index.ts → index.js} +0 -0
- /package/src/components/Home/{Home.test.tsx → Home.test.js} +0 -0
- /package/src/components/Home/{index.ts → index.js} +0 -0
- /package/src/components/IngredientsList/{IngredientsList.tsx → IngredientsList.js} +0 -0
- /package/src/components/IngredientsList/{IngredientsList.test.tsx → IngredientsList.test.js} +0 -0
- /package/src/components/IngredientsList/{index.ts → index.js} +0 -0
- /package/src/components/Inventory/{Inventory.test.tsx → Inventory.test.js} +0 -0
- /package/src/components/Inventory/{index.ts → index.js} +0 -0
- /package/src/components/Item/{Item.test.tsx → Item.test.js} +0 -0
- /package/src/components/Item/{index.ts → index.js} +0 -0
- /package/src/components/KeybindingsView/{KeybindingsView.tsx → KeybindingsView.js} +0 -0
- /package/src/components/KeybindingsView/{KeybindingsView.test.tsx → KeybindingsView.test.js} +0 -0
- /package/src/components/KeybindingsView/{index.ts → index.js} +0 -0
- /package/src/components/LogView/{LogView.test.tsx → LogView.test.js} +0 -0
- /package/src/components/LogView/{index.ts → index.js} +0 -0
- /package/src/components/Navigation/{DayAndProgressContainer.tsx → DayAndProgressContainer.js} +0 -0
- /package/src/components/Navigation/{Navigation.test.tsx → Navigation.test.js} +0 -0
- /package/src/components/Navigation/{index.ts → index.js} +0 -0
- /package/src/components/NotificationSystem/{NotificationSystem.test.tsx → NotificationSystem.test.js} +0 -0
- /package/src/components/NotificationSystem/{index.ts → index.js} +0 -0
- /package/src/components/OnlinePeersView/OnlinePeer/{OnlinePeer.tsx → OnlinePeer.js} +0 -0
- /package/src/components/OnlinePeersView/OnlinePeer/{OnlinePeer.test.tsx → OnlinePeer.test.js} +0 -0
- /package/src/components/OnlinePeersView/OnlinePeer/{index.ts → index.js} +0 -0
- /package/src/components/OnlinePeersView/{OnlinePeersView.test.tsx → OnlinePeersView.test.js} +0 -0
- /package/src/components/OnlinePeersView/{index.ts → index.js} +0 -0
- /package/src/components/Plot/{index.ts → index.js} +0 -0
- /package/src/components/PriceEventView/{PriceEventView.tsx → PriceEventView.js} +0 -0
- /package/src/components/PriceEventView/{index.ts → index.js} +0 -0
- /package/src/components/ProgressBar/{ProgressBar.test.tsx → ProgressBar.test.js} +0 -0
- /package/src/components/ProgressBar/{index.ts → index.js} +0 -0
- /package/src/components/QuantityInput/{QuantityInput.test.tsx → QuantityInput.test.js} +0 -0
- /package/src/components/QuantityInput/{index.ts → index.js} +0 -0
- /package/src/components/QuickSelect/{QuickSelect.tsx → QuickSelect.js} +0 -0
- /package/src/components/QuickSelect/{QuickSelect.test.tsx → QuickSelect.test.js} +0 -0
- /package/src/components/QuickSelect/{index.ts → index.js} +0 -0
- /package/src/components/Recipe/{Recipe.test.tsx → Recipe.test.js} +0 -0
- /package/src/components/Recipe/{index.ts → index.js} +0 -0
- /package/src/components/RecipeList/{RecipeList.tsx → RecipeList.js} +0 -0
- /package/src/components/SearchBar/{SearchBar.tsx → SearchBar.js} +0 -0
- /package/src/components/SearchBar/{SearchBar.test.tsx → SearchBar.test.js} +0 -0
- /package/src/components/SearchBar/{index.ts → index.js} +0 -0
- /package/src/components/SettingsView/{RandomSeedInput.test.tsx → RandomSeedInput.test.js} +0 -0
- /package/src/components/SettingsView/{SettingsView.tsx → SettingsView.js} +0 -0
- /package/src/components/SettingsView/{SettingsView.test.tsx → SettingsView.test.js} +0 -0
- /package/src/components/SettingsView/{index.ts → index.js} +0 -0
- /package/src/components/Shop/{Shop.test.tsx → Shop.test.js} +0 -0
- /package/src/components/Shop/TabPanel/{index.tsx → index.js} +0 -0
- /package/src/components/Shop/{index.ts → index.js} +0 -0
- /package/src/components/Stage/{index.ts → index.js} +0 -0
- /package/src/components/StatsView/{StatsView.tsx → StatsView.js} +0 -0
- /package/src/components/StatsView/{StatsView.test.tsx → StatsView.test.js} +0 -0
- /package/src/components/StatsView/{index.ts → index.js} +0 -0
- /package/src/components/TierPurchase/{TierPurchase.tsx → TierPurchase.js} +0 -0
- /package/src/components/TierPurchase/{TierPurchase.test.tsx → TierPurchase.test.js} +0 -0
- /package/src/components/TierPurchase/{index.ts → index.js} +0 -0
- /package/src/components/Toolbelt/{Toolbelt.test.tsx → Toolbelt.test.js} +0 -0
- /package/src/components/Toolbelt/{index.ts → index.js} +0 -0
- /package/src/components/UpdateNotifier/{UpdateNotifier.tsx → UpdateNotifier.js} +0 -0
- /package/src/components/UpdateNotifier/{index.ts → index.js} +0 -0
- /package/src/components/UpgradePurchase/{UpgradePurchase.test.tsx → UpgradePurchase.test.js} +0 -0
- /package/src/components/UpgradePurchase/{index.ts → index.js} +0 -0
- /package/src/components/Workshop/{KitchenTabPanel.tsx → KitchenTabPanel.js} +0 -0
- /package/src/components/Workshop/{RecyclingTabPanel.tsx → RecyclingTabPanel.js} +0 -0
- /package/src/components/Workshop/TabPanel/{index.tsx → index.js} +0 -0
- /package/src/components/Workshop/{Workshop.tsx → Workshop.js} +0 -0
- /package/src/components/Workshop/{Workshop.test.tsx → Workshop.test.js} +0 -0
- /package/src/components/Workshop/{index.ts → index.js} +0 -0
- /package/src/{config.ts → config.js} +0 -0
- /package/src/data/__mocks__/{items.ts → items.js} +0 -0
- /package/src/data/__mocks__/{maps.ts → maps.js} +0 -0
- /package/src/data/__mocks__/{recipes.ts → recipes.js} +0 -0
- /package/src/data/__mocks__/{shop-inventory.ts → shop-inventory.js} +0 -0
- /package/src/data/crops/{index.ts → index.js} +0 -0
- /package/src/data/{fruit-names.ts → fruit-names.js} +0 -0
- /package/src/data/{items-map.ts → items-map.js} +0 -0
- /package/src/data/ores/{index.ts → index.js} +0 -0
- /package/src/data/{shop-inventory-cow.ts → shop-inventory-cow.js} +0 -0
- /package/src/data/{shop-inventory.ts → shop-inventory.js} +0 -0
- /package/src/data/{tools.ts → tools.js} +0 -0
- /package/src/data/{upgrades.ts → upgrades.js} +0 -0
- /package/src/factories/{CoalFactory.test.ts → CoalFactory.test.js} +0 -0
- /package/src/factories/{OreFactory.test.ts → OreFactory.test.js} +0 -0
- /package/src/factories/{StoneFactory.test.ts → StoneFactory.test.js} +0 -0
- /package/src/factories/{index.ts → index.js} +0 -0
- /package/src/game-logic/cows/{cow-selection.test.ts → cow-selection.test.js} +0 -0
- /package/src/game-logic/{item-purchase.test.ts → item-purchase.test.js} +0 -0
- /package/src/game-logic/{item-sell.test.ts → item-sell.test.js} +0 -0
- /package/src/game-logic/reducers/{addCowToInventory.ts → addCowToInventory.js} +0 -0
- /package/src/game-logic/reducers/{addExperience.ts → addExperience.js} +0 -0
- /package/src/game-logic/reducers/{addExperience.test.ts → addExperience.test.js} +0 -0
- /package/src/game-logic/reducers/{addItemToInventory.ts → addItemToInventory.js} +0 -0
- /package/src/game-logic/reducers/{addItemToInventory.test.ts → addItemToInventory.test.js} +0 -0
- /package/src/game-logic/reducers/{addKegToCellarInventory.ts → addKegToCellarInventory.js} +0 -0
- /package/src/game-logic/reducers/{addPeer.ts → addPeer.js} +0 -0
- /package/src/game-logic/reducers/{addRevenue.ts → addRevenue.js} +0 -0
- /package/src/game-logic/reducers/{adjustLoan.ts → adjustLoan.js} +0 -0
- /package/src/game-logic/reducers/{adjustLoan.test.ts → adjustLoan.test.js} +0 -0
- /package/src/game-logic/reducers/{applyCrows.test.ts → applyCrows.test.js} +0 -0
- /package/src/game-logic/reducers/{applyLoanInterest.test.ts → applyLoanInterest.test.js} +0 -0
- /package/src/game-logic/reducers/{applyPrecipitation.test.ts → applyPrecipitation.test.js} +0 -0
- /package/src/game-logic/reducers/{changeCowAutomaticHugState.ts → changeCowAutomaticHugState.js} +0 -0
- /package/src/game-logic/reducers/{changeCowAutomaticHugState.test.ts → changeCowAutomaticHugState.test.js} +0 -0
- /package/src/game-logic/reducers/{changeCowBreedingPenResident.ts → changeCowBreedingPenResident.js} +0 -0
- /package/src/game-logic/reducers/{changeCowBreedingPenResident.test.ts → changeCowBreedingPenResident.test.js} +0 -0
- /package/src/game-logic/reducers/{changeCowName.ts → changeCowName.js} +0 -0
- /package/src/game-logic/reducers/{changeCowName.test.ts → changeCowName.test.js} +0 -0
- /package/src/game-logic/reducers/{clearPlot.ts → clearPlot.js} +0 -0
- /package/src/game-logic/reducers/{clearPlot.test.ts → clearPlot.test.js} +0 -0
- /package/src/game-logic/reducers/{computeCowInventoryForNextDay.ts → computeCowInventoryForNextDay.js} +0 -0
- /package/src/game-logic/reducers/{computeCowInventoryForNextDay.test.ts → computeCowInventoryForNextDay.test.js} +0 -0
- /package/src/game-logic/reducers/{computeStateForNextDay.test.ts → computeStateForNextDay.test.js} +0 -0
- /package/src/game-logic/reducers/{consumeIngredients.ts → consumeIngredients.js} +0 -0
- /package/src/game-logic/reducers/{consumeIngredients.test.ts → consumeIngredients.test.js} +0 -0
- /package/src/game-logic/reducers/{createPriceEvent.ts → createPriceEvent.js} +0 -0
- /package/src/game-logic/reducers/{createPriceEvent.test.ts → createPriceEvent.test.js} +0 -0
- /package/src/game-logic/reducers/{decrementItemFromInventory.ts → decrementItemFromInventory.js} +0 -0
- /package/src/game-logic/reducers/{decrementItemFromInventory.test.ts → decrementItemFromInventory.test.js} +0 -0
- /package/src/game-logic/reducers/{fertilizePlot.ts → fertilizePlot.js} +0 -0
- /package/src/game-logic/reducers/{fertilizePlot.test.ts → fertilizePlot.test.js} +0 -0
- /package/src/game-logic/reducers/{forRange.ts → forRange.js} +0 -0
- /package/src/game-logic/reducers/{forRange.test.ts → forRange.test.js} +0 -0
- /package/src/game-logic/reducers/{generatePriceEvents.ts → generatePriceEvents.js} +0 -0
- /package/src/game-logic/reducers/{generatePriceEvents.test.ts → generatePriceEvents.test.js} +0 -0
- /package/src/game-logic/reducers/{harvestPlot.ts → harvestPlot.js} +0 -0
- /package/src/game-logic/reducers/{harvestPlot.test.ts → harvestPlot.test.js} +0 -0
- /package/src/game-logic/reducers/{helpers.tsx → helpers.js} +0 -0
- /package/src/game-logic/reducers/{hugCow.ts → hugCow.js} +0 -0
- /package/src/game-logic/reducers/{hugCow.test.ts → hugCow.test.js} +0 -0
- /package/src/game-logic/reducers/{incrementPlotContentAge.ts → incrementPlotContentAge.js} +0 -0
- /package/src/game-logic/reducers/{incrementPlotContentAge.test.ts → incrementPlotContentAge.test.js} +0 -0
- /package/src/game-logic/reducers/{index.ts → index.js} +0 -0
- /package/src/game-logic/reducers/{makeFermentationRecipe.test.ts → makeFermentationRecipe.test.js} +0 -0
- /package/src/game-logic/reducers/{makeRecipe.ts → makeRecipe.js} +0 -0
- /package/src/game-logic/reducers/{makeRecipe.test.ts → makeRecipe.test.js} +0 -0
- /package/src/game-logic/reducers/{minePlot.test.ts → minePlot.test.js} +0 -0
- /package/src/game-logic/reducers/{modifyCow.ts → modifyCow.js} +0 -0
- /package/src/game-logic/reducers/{modifyFieldPlotAt.ts → modifyFieldPlotAt.js} +0 -0
- /package/src/game-logic/reducers/{offerCow.ts → offerCow.js} +0 -0
- /package/src/game-logic/reducers/{offerCow.test.ts → offerCow.test.js} +0 -0
- /package/src/game-logic/reducers/{plantInPlot.ts → plantInPlot.js} +0 -0
- /package/src/game-logic/reducers/{plantInPlot.test.ts → plantInPlot.test.js} +0 -0
- /package/src/game-logic/reducers/{prependPendingPeerMessage.ts → prependPendingPeerMessage.js} +0 -0
- /package/src/game-logic/reducers/{prependPendingPeerMessage.test.ts → prependPendingPeerMessage.test.js} +0 -0
- /package/src/game-logic/reducers/{processCellar.ts → processCellar.js} +0 -0
- /package/src/game-logic/reducers/{processCellar.test.ts → processCellar.test.js} +0 -0
- /package/src/game-logic/reducers/{processCowAttrition.ts → processCowAttrition.js} +0 -0
- /package/src/game-logic/reducers/{processCowAttrition.test.ts → processCowAttrition.test.js} +0 -0
- /package/src/game-logic/reducers/{processCowBreeding.ts → processCowBreeding.js} +0 -0
- /package/src/game-logic/reducers/{processCowBreeding.test.ts → processCowBreeding.test.js} +0 -0
- /package/src/game-logic/reducers/{processCowFertilizerProduction.test.ts → processCowFertilizerProduction.test.js} +0 -0
- /package/src/game-logic/reducers/{processFeedingCows.ts → processFeedingCows.js} +0 -0
- /package/src/game-logic/reducers/{processFeedingCows.test.ts → processFeedingCows.test.js} +0 -0
- /package/src/game-logic/reducers/{processField.ts → processField.js} +0 -0
- /package/src/game-logic/reducers/{processLevelUp.test.ts → processLevelUp.test.js} +0 -0
- /package/src/game-logic/reducers/{processMilkingCows.ts → processMilkingCows.js} +0 -0
- /package/src/game-logic/reducers/{processMilkingCows.test.ts → processMilkingCows.test.js} +0 -0
- /package/src/game-logic/reducers/{processNerfs.ts → processNerfs.js} +0 -0
- /package/src/game-logic/reducers/{processNerfs.test.ts → processNerfs.test.js} +0 -0
- /package/src/game-logic/reducers/{processSprinklers.ts → processSprinklers.js} +0 -0
- /package/src/game-logic/reducers/{processSprinklers.test.ts → processSprinklers.test.js} +0 -0
- /package/src/game-logic/reducers/{processWeather.ts → processWeather.js} +0 -0
- /package/src/game-logic/reducers/{processWeather.test.ts → processWeather.test.js} +0 -0
- /package/src/game-logic/reducers/{purchaseCellar.ts → purchaseCellar.js} +0 -0
- /package/src/game-logic/reducers/{purchaseCellar.test.ts → purchaseCellar.test.js} +0 -0
- /package/src/game-logic/reducers/{purchaseCombine.ts → purchaseCombine.js} +0 -0
- /package/src/game-logic/reducers/{purchaseCombine.test.ts → purchaseCombine.test.js} +0 -0
- /package/src/game-logic/reducers/{purchaseComposter.ts → purchaseComposter.js} +0 -0
- /package/src/game-logic/reducers/{purchaseComposter.test.ts → purchaseComposter.test.js} +0 -0
- /package/src/game-logic/reducers/{purchaseCow.ts → purchaseCow.js} +0 -0
- /package/src/game-logic/reducers/{purchaseCow.test.ts → purchaseCow.test.js} +0 -0
- /package/src/game-logic/reducers/{purchaseCowPen.ts → purchaseCowPen.js} +0 -0
- /package/src/game-logic/reducers/{purchaseCowPen.test.ts → purchaseCowPen.test.js} +0 -0
- /package/src/game-logic/reducers/{purchaseField.ts → purchaseField.js} +0 -0
- /package/src/game-logic/reducers/{purchaseForest.ts → purchaseForest.js} +0 -0
- /package/src/game-logic/reducers/{purchaseItem.ts → purchaseItem.js} +0 -0
- /package/src/game-logic/reducers/{purchaseItem.test.ts → purchaseItem.test.js} +0 -0
- /package/src/game-logic/reducers/{purchaseSmelter.ts → purchaseSmelter.js} +0 -0
- /package/src/game-logic/reducers/{purchaseSmelter.test.ts → purchaseSmelter.test.js} +0 -0
- /package/src/game-logic/reducers/{purchaseStorageExpansion.ts → purchaseStorageExpansion.js} +0 -0
- /package/src/game-logic/reducers/{purchaseStorageExpansion.test.ts → purchaseStorageExpansion.test.js} +0 -0
- /package/src/game-logic/reducers/{removeCowFromInventory.ts → removeCowFromInventory.js} +0 -0
- /package/src/game-logic/reducers/{removeFieldPlotAt.ts → removeFieldPlotAt.js} +0 -0
- /package/src/game-logic/reducers/{removeKegFromCellar.ts → removeKegFromCellar.js} +0 -0
- /package/src/game-logic/reducers/{removePeer.ts → removePeer.js} +0 -0
- /package/src/game-logic/reducers/{rotateNotificationLogs.test.ts → rotateNotificationLogs.test.js} +0 -0
- /package/src/game-logic/reducers/{selectCow.ts → selectCow.js} +0 -0
- /package/src/game-logic/reducers/{selectCow.test.ts → selectCow.test.js} +0 -0
- /package/src/game-logic/reducers/{sellCow.ts → sellCow.js} +0 -0
- /package/src/game-logic/reducers/{sellCow.test.ts → sellCow.test.js} +0 -0
- /package/src/game-logic/reducers/{sellItem.ts → sellItem.js} +0 -0
- /package/src/game-logic/reducers/{sellKeg.test.ts → sellKeg.test.js} +0 -0
- /package/src/game-logic/reducers/{setScarecrow.ts → setScarecrow.js} +0 -0
- /package/src/game-logic/reducers/{setScarecrow.test.ts → setScarecrow.test.js} +0 -0
- /package/src/game-logic/reducers/{setSprinkler.ts → setSprinkler.js} +0 -0
- /package/src/game-logic/reducers/{setSprinkler.test.ts → setSprinkler.test.js} +0 -0
- /package/src/game-logic/reducers/{showNotification.ts → showNotification.js} +0 -0
- /package/src/game-logic/reducers/{showNotification.test.ts → showNotification.test.js} +0 -0
- /package/src/game-logic/reducers/{spawnWeeds.test.ts → spawnWeeds.test.js} +0 -0
- /package/src/game-logic/reducers/{unlockTool.ts → unlockTool.js} +0 -0
- /package/src/game-logic/reducers/{unlockTool.test.ts → unlockTool.test.js} +0 -0
- /package/src/game-logic/reducers/{updateAchievements.test.ts → updateAchievements.test.js} +0 -0
- /package/src/game-logic/reducers/{updateFinancialRecords.ts → updateFinancialRecords.js} +0 -0
- /package/src/game-logic/reducers/{updateFinancialRecords.test.ts → updateFinancialRecords.test.js} +0 -0
- /package/src/game-logic/reducers/{updateInventoryRecordsForNextDay.ts → updateInventoryRecordsForNextDay.js} +0 -0
- /package/src/game-logic/reducers/{updateInventoryRecordsForNextDay.test.ts → updateInventoryRecordsForNextDay.test.js} +0 -0
- /package/src/game-logic/reducers/{updateLearnedRecipes.ts → updateLearnedRecipes.js} +0 -0
- /package/src/game-logic/reducers/{updateLearnedRecipes.test.ts → updateLearnedRecipes.test.js} +0 -0
- /package/src/game-logic/reducers/{updatePlotShoveledState.ts → updatePlotShoveledState.js} +0 -0
- /package/src/game-logic/reducers/{updatePriceEvents.tsx → updatePriceEvents.js} +0 -0
- /package/src/game-logic/reducers/{updatePriceEvents.test.ts → updatePriceEvents.test.js} +0 -0
- /package/src/game-logic/reducers/{upgradeTool.ts → upgradeTool.js} +0 -0
- /package/src/game-logic/reducers/{upgradeTool.test.ts → upgradeTool.test.js} +0 -0
- /package/src/game-logic/reducers/{waterAllPlots.ts → waterAllPlots.js} +0 -0
- /package/src/game-logic/reducers/{waterAllPlots.test.ts → waterAllPlots.test.js} +0 -0
- /package/src/game-logic/reducers/{waterField.ts → waterField.js} +0 -0
- /package/src/game-logic/reducers/{waterPlot.ts → waterPlot.js} +0 -0
- /package/src/game-logic/reducers/{waterPlot.test.ts → waterPlot.test.js} +0 -0
- /package/src/game-logic/reducers/{withdrawCow.ts → withdrawCow.js} +0 -0
- /package/src/game-logic/reducers/{withdrawCow.test.ts → withdrawCow.test.js} +0 -0
- /package/src/img/__mocks__/{index.ts → index.js} +0 -0
- /package/src/img/{index.ts → index.js} +0 -0
- /package/src/interfaces/{Factory.ts → Factory.js} +0 -0
- /package/src/{mui-theme.ts → mui-theme.js} +0 -0
- /package/src/{polyfills.ts → polyfills.js} +0 -0
- /package/src/services/{cellar.ts → cellar.js} +0 -0
- /package/src/services/{wine.test.ts → wine.test.js} +0 -0
- /package/src/{setupTests.ts → setupTests.js} +0 -0
- /package/src/shell/{bootup.test.ts → bootup.test.js} +0 -0
- /package/src/shell/{field.test.ts → field.test.js} +0 -0
- /package/src/shell/{game-saving.test.ts → game-saving.test.js} +0 -0
- /package/src/shell/{navigation.test.ts → navigation.test.js} +0 -0
- /package/src/shell/{pending-notifications.test.ts → pending-notifications.test.js} +0 -0
- /package/src/{strings.ts → strings.js} +0 -0
- /package/src/test-utils/stubs/{cowStub.ts → cowStub.js} +0 -0
- /package/src/test-utils/stubs/{farmhandStub.tsx → farmhandStub.js} +0 -0
- /package/src/test-utils/stubs/{itemStub.ts → itemStub.js} +0 -0
- /package/src/test-utils/stubs/{peerMetadataStub.ts → peerMetadataStub.js} +0 -0
- /package/src/test-utils/stubs/{saveDataStubFactory.ts → saveDataStubFactory.js} +0 -0
- /package/src/test-utils/{ui.ts → ui.js} +0 -0
- /package/src/utils/__snapshots__/{index.test.ts.snap → index.test.js.snap} +0 -0
- /package/src/utils/{findInField.ts → findInField.js} +0 -0
- /package/src/utils/{findInField.test.ts → findInField.test.js} +0 -0
- /package/src/utils/{getCropLifecycleDuration.test.ts → getCropLifecycleDuration.test.js} +0 -0
- /package/src/utils/{getCropsAvailableToFerment.test.ts → getCropsAvailableToFerment.test.js} +0 -0
- /package/src/utils/{getItemBaseValue.ts → getItemBaseValue.js} +0 -0
- /package/src/utils/{getKegSpoilageRate.ts → getKegSpoilageRate.js} +0 -0
- /package/src/utils/{getKegSpoilageRate.test.ts → getKegSpoilageRate.test.js} +0 -0
- /package/src/utils/{getKegValue.ts → getKegValue.js} +0 -0
- /package/src/utils/{getKegValue.test.ts → getKegValue.test.js} +0 -0
- /package/src/utils/{getLevelEntitlements.test.ts → getLevelEntitlements.test.js} +0 -0
- /package/src/utils/{getMaxYieldOfFermentationRecipe.test.ts → getMaxYieldOfFermentationRecipe.test.js} +0 -0
- /package/src/utils/{getSaltRequirementsForFermentationRecipe.ts → getSaltRequirementsForFermentationRecipe.js} +0 -0
- /package/src/utils/{getWineVarietiesAvailableToMake.test.ts → getWineVarietiesAvailableToMake.test.js} +0 -0
- /package/src/utils/{getYeastRequiredForWine.ts → getYeastRequiredForWine.js} +0 -0
- /package/src/utils/{isItemAGrownCrop.ts → isItemAGrownCrop.js} +0 -0
- /package/src/utils/{levelAchieved.ts → levelAchieved.js} +0 -0
- /package/src/utils/{moneyString.ts → moneyString.js} +0 -0
- /package/src/utils/{moneyString.test.ts → moneyString.test.js} +0 -0
- /package/src/utils/{noop.ts → noop.js} +0 -0
- /package/src/utils/{totalIngredientsInRecipe.test.ts → totalIngredientsInRecipe.test.js} +0 -0
|
@@ -32,9 +32,9 @@ const convertToRecipe = partialRecipe => {
|
|
|
32
32
|
...partialRecipe,
|
|
33
33
|
})
|
|
34
34
|
|
|
35
|
-
itemsMap[partialRecipe.id] = /** @type {farmhand.item} */ recipe
|
|
35
|
+
itemsMap[partialRecipe.id] = /** @type {farmhand.item} */ (recipe)
|
|
36
36
|
|
|
37
|
-
return /** @type {farmhand.recipe} */ recipe
|
|
37
|
+
return /** @type {farmhand.recipe} */ (recipe)
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
/**
|
|
@@ -49,7 +49,7 @@ export const salt = convertToRecipe({
|
|
|
49
49
|
},
|
|
50
50
|
condition: state => (state.itemsSold[items.saltRock.id] || 0) >= 30,
|
|
51
51
|
description: 'Useful for seasoning food and fermentation.',
|
|
52
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
52
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
53
53
|
})
|
|
54
54
|
|
|
55
55
|
/**
|
|
@@ -63,7 +63,7 @@ export const flour = convertToRecipe({
|
|
|
63
63
|
[items.wheat.id]: 10,
|
|
64
64
|
},
|
|
65
65
|
condition: state => (state.itemsSold[items.wheat.id] || 0) >= 20,
|
|
66
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
66
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
67
67
|
})
|
|
68
68
|
|
|
69
69
|
/**
|
|
@@ -77,7 +77,7 @@ export const yeast = convertToRecipe({
|
|
|
77
77
|
[flour.id]: 5,
|
|
78
78
|
},
|
|
79
79
|
condition: state => (state.itemsSold[flour.id] || 0) >= 25,
|
|
80
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
80
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
81
81
|
})
|
|
82
82
|
|
|
83
83
|
/**
|
|
@@ -94,7 +94,7 @@ const getWineRecipeFromGrape = grape => {
|
|
|
94
94
|
[grape.id]: GRAPES_REQUIRED_FOR_WINE,
|
|
95
95
|
[yeast.id]: getYeastRequiredForWine(grape.variety),
|
|
96
96
|
},
|
|
97
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.WINE,
|
|
97
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.WINE),
|
|
98
98
|
// NOTE: This prevents wines from appearing in the Learned Recipes list in the Workshop
|
|
99
99
|
condition: () => false,
|
|
100
100
|
}),
|
|
@@ -116,7 +116,7 @@ export const bread = convertToRecipe({
|
|
|
116
116
|
condition: state =>
|
|
117
117
|
(state.itemsSold[flour.id] || 0) >= 30 &&
|
|
118
118
|
(state.itemsSold[yeast.id] || 0) >= 15,
|
|
119
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
119
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
120
120
|
})
|
|
121
121
|
|
|
122
122
|
/**
|
|
@@ -130,7 +130,7 @@ export const butter = convertToRecipe({
|
|
|
130
130
|
[items.milk3.id]: 5,
|
|
131
131
|
},
|
|
132
132
|
condition: state => (state.itemsSold[items.milk3.id] || 0) >= 30,
|
|
133
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
133
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
134
134
|
})
|
|
135
135
|
|
|
136
136
|
/**
|
|
@@ -144,7 +144,7 @@ export const sunButter = convertToRecipe({
|
|
|
144
144
|
[items.sunflower.id]: 25,
|
|
145
145
|
},
|
|
146
146
|
condition: state => (state.itemsSold[items.sunflower.id] || 0) >= 200,
|
|
147
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
147
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
148
148
|
})
|
|
149
149
|
|
|
150
150
|
/*
|
|
@@ -158,7 +158,7 @@ export const oliveOil = convertToRecipe({
|
|
|
158
158
|
[items.olive.id]: 250,
|
|
159
159
|
},
|
|
160
160
|
condition: state => (state.itemsSold[items.olive.id] || 0) >= 500,
|
|
161
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
161
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
162
162
|
})
|
|
163
163
|
|
|
164
164
|
/**
|
|
@@ -172,7 +172,7 @@ export const cheese = convertToRecipe({
|
|
|
172
172
|
[items.milk3.id]: 8,
|
|
173
173
|
},
|
|
174
174
|
condition: state => (state.itemsSold[items.milk3.id] || 0) >= 20,
|
|
175
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
175
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
176
176
|
})
|
|
177
177
|
|
|
178
178
|
/**
|
|
@@ -186,7 +186,7 @@ export const rainbowCheese = convertToRecipe({
|
|
|
186
186
|
[items.rainbowMilk3.id]: 10,
|
|
187
187
|
},
|
|
188
188
|
condition: state => (state.itemsSold[items.rainbowMilk3.id] || 0) >= 30,
|
|
189
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
189
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
190
190
|
})
|
|
191
191
|
|
|
192
192
|
/**
|
|
@@ -200,7 +200,7 @@ export const chocolate = convertToRecipe({
|
|
|
200
200
|
[items.chocolateMilk.id]: 10,
|
|
201
201
|
},
|
|
202
202
|
condition: state => (state.itemsSold[items.chocolateMilk.id] || 0) >= 25,
|
|
203
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
203
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
204
204
|
})
|
|
205
205
|
|
|
206
206
|
/**
|
|
@@ -214,7 +214,7 @@ export const carrotSoup = convertToRecipe({
|
|
|
214
214
|
[items.carrot.id]: 4,
|
|
215
215
|
},
|
|
216
216
|
condition: state => (state.itemsSold[items.carrot.id] || 0) >= 10,
|
|
217
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
217
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
218
218
|
})
|
|
219
219
|
|
|
220
220
|
/**
|
|
@@ -228,7 +228,7 @@ export const jackolantern = convertToRecipe({
|
|
|
228
228
|
[items.pumpkin.id]: 1,
|
|
229
229
|
},
|
|
230
230
|
condition: state => (state.itemsSold[items.pumpkin.id] || 0) >= 50,
|
|
231
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
231
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
232
232
|
})
|
|
233
233
|
|
|
234
234
|
/**
|
|
@@ -245,7 +245,7 @@ export const spaghetti = convertToRecipe({
|
|
|
245
245
|
condition: state =>
|
|
246
246
|
(state.itemsSold[items.wheat.id] || 0) >= 20 &&
|
|
247
247
|
(state.itemsSold[items.tomato.id] || 0) >= 5,
|
|
248
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
248
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
249
249
|
})
|
|
250
250
|
|
|
251
251
|
/**
|
|
@@ -263,7 +263,7 @@ export const frenchOnionSoup = convertToRecipe({
|
|
|
263
263
|
condition: state =>
|
|
264
264
|
(state.itemsSold[items.onion.id] || 0) >= 15 &&
|
|
265
265
|
(state.itemsSold[cheese.id] || 0) >= 10,
|
|
266
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
266
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
267
267
|
})
|
|
268
268
|
|
|
269
269
|
/**
|
|
@@ -288,7 +288,7 @@ export const burger = convertToRecipe({
|
|
|
288
288
|
(state.itemsSold[items.soybean.id] || 0) >= 25 &&
|
|
289
289
|
(state.itemsSold[items.spinach.id] || 0) >= 5 &&
|
|
290
290
|
(state.itemsSold[items.tomato.id] || 0) >= 5,
|
|
291
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
291
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
292
292
|
})
|
|
293
293
|
|
|
294
294
|
/**
|
|
@@ -307,7 +307,7 @@ export const summerSalad = convertToRecipe({
|
|
|
307
307
|
(state.itemsSold[items.spinach.id] || 0) >= 30 &&
|
|
308
308
|
(state.itemsSold[items.corn.id] || 0) > 5 &&
|
|
309
309
|
(state.itemsSold[items.carrot.id] || 0) > 5,
|
|
310
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
310
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
311
311
|
})
|
|
312
312
|
|
|
313
313
|
/**
|
|
@@ -321,7 +321,7 @@ export const soyMilk = convertToRecipe({
|
|
|
321
321
|
[items.soybean.id]: 20,
|
|
322
322
|
},
|
|
323
323
|
condition: state => (state.itemsSold[items.soybean.id] || 0) >= 100,
|
|
324
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
324
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
325
325
|
})
|
|
326
326
|
|
|
327
327
|
/**
|
|
@@ -338,7 +338,7 @@ export const chocolateSoyMilk = convertToRecipe({
|
|
|
338
338
|
condition: state =>
|
|
339
339
|
(state.itemsSold[soyMilk.id] || 0) >= 5 &&
|
|
340
340
|
(state.itemsSold[chocolate.id] || 0) >= 5,
|
|
341
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
341
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
342
342
|
})
|
|
343
343
|
|
|
344
344
|
/**
|
|
@@ -352,7 +352,7 @@ export const tofu = convertToRecipe({
|
|
|
352
352
|
[soyMilk.id]: 4,
|
|
353
353
|
},
|
|
354
354
|
condition: state => (state.itemsSold[soyMilk.id] || 0) >= 20,
|
|
355
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
355
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
356
356
|
})
|
|
357
357
|
|
|
358
358
|
/**
|
|
@@ -375,7 +375,7 @@ export const chicknPotPie = convertToRecipe({
|
|
|
375
375
|
(state.itemsSold[items.carrot.id] || 0) >= 300 &&
|
|
376
376
|
(state.itemsSold[items.wheat.id] || 0) >= 425 &&
|
|
377
377
|
(state.itemsSold[soyMilk.id] || 0) >= 15,
|
|
378
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
378
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
379
379
|
})
|
|
380
380
|
|
|
381
381
|
/**
|
|
@@ -390,7 +390,7 @@ export const hotSauce = convertToRecipe({
|
|
|
390
390
|
[salt.id]: 1,
|
|
391
391
|
},
|
|
392
392
|
condition: state => (state.itemsSold[items.jalapeno.id] || 0) >= 50,
|
|
393
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
393
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
394
394
|
})
|
|
395
395
|
|
|
396
396
|
/**
|
|
@@ -411,7 +411,7 @@ export const salsa = convertToRecipe({
|
|
|
411
411
|
(state.itemsSold[items.onion.id] || 0) >= 5 &&
|
|
412
412
|
(state.itemsSold[items.tomato.id] || 0) >= 5 &&
|
|
413
413
|
(state.itemsSold[items.corn.id] || 0) >= 5,
|
|
414
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
414
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
415
415
|
})
|
|
416
416
|
|
|
417
417
|
/**
|
|
@@ -428,7 +428,7 @@ export const spicyCheese = convertToRecipe({
|
|
|
428
428
|
condition: state =>
|
|
429
429
|
(state.itemsSold[items.jalapeno.id] || 0) >= 20 &&
|
|
430
430
|
(state.itemsSold[items.milk3.id] || 0) >= 50,
|
|
431
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
431
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
432
432
|
})
|
|
433
433
|
|
|
434
434
|
/**
|
|
@@ -442,7 +442,7 @@ export const vegetableOil = convertToRecipe({
|
|
|
442
442
|
[items.soybean.id]: 350,
|
|
443
443
|
},
|
|
444
444
|
condition: state => (state.itemsSold[items.soybean.id] || 0) >= 900,
|
|
445
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
445
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
446
446
|
})
|
|
447
447
|
|
|
448
448
|
/**
|
|
@@ -459,7 +459,7 @@ export const friedTofu = convertToRecipe({
|
|
|
459
459
|
condition: state =>
|
|
460
460
|
(state.itemsSold[tofu.id] || 0) >= 50 &&
|
|
461
461
|
(state.itemsSold[vegetableOil.id] || 0) >= 50,
|
|
462
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
462
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
463
463
|
})
|
|
464
464
|
|
|
465
465
|
/**
|
|
@@ -476,7 +476,7 @@ export const spicyPickledGarlic = convertToRecipe({
|
|
|
476
476
|
condition: state =>
|
|
477
477
|
(state.itemsSold[items.jalapeno.id] || 0) >= 12 &&
|
|
478
478
|
(state.itemsSold[items.garlic.id] || 0) >= 25,
|
|
479
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
479
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
480
480
|
})
|
|
481
481
|
|
|
482
482
|
/**
|
|
@@ -495,7 +495,7 @@ export const garlicFries = convertToRecipe({
|
|
|
495
495
|
condition: state =>
|
|
496
496
|
(state.itemsSold[items.potato.id] || 0) >= 50 &&
|
|
497
497
|
(state.itemsSold[items.garlic.id] || 0) >= 30,
|
|
498
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
498
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
499
499
|
})
|
|
500
500
|
|
|
501
501
|
/**
|
|
@@ -514,7 +514,7 @@ export const garlicBread = convertToRecipe({
|
|
|
514
514
|
(state.itemsSold[bread.id] || 0) >= 30 &&
|
|
515
515
|
(state.itemsSold[oliveOil.id] || 0) >= 20 &&
|
|
516
516
|
(state.itemsSold[items.garlic.id] || 0) >= 50,
|
|
517
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
517
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
518
518
|
})
|
|
519
519
|
|
|
520
520
|
/**
|
|
@@ -528,7 +528,7 @@ export const strawberryJam = convertToRecipe({
|
|
|
528
528
|
[items.strawberry.id]: 10,
|
|
529
529
|
},
|
|
530
530
|
condition: state => (state.itemsSold[items.strawberry.id] || 0) >= 60,
|
|
531
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
531
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
532
532
|
})
|
|
533
533
|
|
|
534
534
|
/**
|
|
@@ -545,7 +545,7 @@ export const popcorn = convertToRecipe({
|
|
|
545
545
|
condition: state =>
|
|
546
546
|
(state.itemsSold[items.corn.id] || 0) >= 12 &&
|
|
547
547
|
(state.itemsSold[butter.id] || 0) >= 6,
|
|
548
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
548
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
549
549
|
})
|
|
550
550
|
|
|
551
551
|
/**
|
|
@@ -564,7 +564,7 @@ export const pumpkinPie = convertToRecipe({
|
|
|
564
564
|
(state.itemsSold[items.pumpkin.id] || 0) >= 200 &&
|
|
565
565
|
(state.itemsSold[items.wheat.id] || 0) >= 250 &&
|
|
566
566
|
(state.itemsSold[butter.id] || 0) >= 75,
|
|
567
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
567
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
568
568
|
})
|
|
569
569
|
|
|
570
570
|
/**
|
|
@@ -583,7 +583,7 @@ export const sweetPotatoPie = convertToRecipe({
|
|
|
583
583
|
(state.itemsSold[items.sweetPotato.id] || 0) >= 200 &&
|
|
584
584
|
(state.itemsSold[items.wheat.id] || 0) >= 250 &&
|
|
585
585
|
(state.itemsSold[butter.id] || 0) >= 75,
|
|
586
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
586
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
587
587
|
})
|
|
588
588
|
|
|
589
589
|
/**
|
|
@@ -599,7 +599,7 @@ export const sweetPotatoFries = convertToRecipe({
|
|
|
599
599
|
[salt.id]: 1,
|
|
600
600
|
},
|
|
601
601
|
condition: state => (state.itemsSold[items.sweetPotato.id] || 0) >= 100,
|
|
602
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
602
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
603
603
|
})
|
|
604
604
|
|
|
605
605
|
/**
|
|
@@ -621,7 +621,7 @@ export const onionRings = convertToRecipe({
|
|
|
621
621
|
(state.itemsSold[vegetableOil.id] || 0) > 20 &&
|
|
622
622
|
(state.itemsSold[soyMilk.id] || 0) > 20 &&
|
|
623
623
|
(state.itemsSold[items.wheat.id] || 0) > 30,
|
|
624
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.KITCHEN,
|
|
624
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.KITCHEN),
|
|
625
625
|
})
|
|
626
626
|
|
|
627
627
|
/**
|
|
@@ -638,7 +638,7 @@ export const bronzeIngot = convertToRecipe({
|
|
|
638
638
|
condition: state =>
|
|
639
639
|
state.purchasedSmelter > 0 &&
|
|
640
640
|
(state.itemsSold[items.bronzeOre.id] || 0) >= 50,
|
|
641
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.FORGE,
|
|
641
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.FORGE),
|
|
642
642
|
})
|
|
643
643
|
|
|
644
644
|
/**
|
|
@@ -655,7 +655,7 @@ export const ironIngot = convertToRecipe({
|
|
|
655
655
|
condition: state =>
|
|
656
656
|
state.purchasedSmelter > 0 &&
|
|
657
657
|
(state.itemsSold[items.ironOre.id] || 0) >= 50,
|
|
658
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.FORGE,
|
|
658
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.FORGE),
|
|
659
659
|
})
|
|
660
660
|
|
|
661
661
|
/**
|
|
@@ -672,7 +672,7 @@ export const silverIngot = convertToRecipe({
|
|
|
672
672
|
condition: state =>
|
|
673
673
|
state.purchasedSmelter > 0 &&
|
|
674
674
|
(state.itemsSold[items.silverOre.id] || 0) >= 50,
|
|
675
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.FORGE,
|
|
675
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.FORGE),
|
|
676
676
|
})
|
|
677
677
|
|
|
678
678
|
/**
|
|
@@ -689,7 +689,7 @@ export const goldIngot = convertToRecipe({
|
|
|
689
689
|
condition: state =>
|
|
690
690
|
state.purchasedSmelter > 0 &&
|
|
691
691
|
(state.itemsSold[items.goldOre.id] || 0) >= 50,
|
|
692
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.FORGE,
|
|
692
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.FORGE),
|
|
693
693
|
})
|
|
694
694
|
|
|
695
695
|
export const compost = convertToRecipe({
|
|
@@ -702,7 +702,7 @@ export const compost = convertToRecipe({
|
|
|
702
702
|
state.purchasedComposter > 0 &&
|
|
703
703
|
(state.itemsSold[items.weed.id] || 0) >= 100,
|
|
704
704
|
description: 'Can be used to make fertilizer.',
|
|
705
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.RECYCLING,
|
|
705
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.RECYCLING),
|
|
706
706
|
type: itemType.CRAFTED_ITEM,
|
|
707
707
|
})
|
|
708
708
|
|
|
@@ -720,7 +720,7 @@ export const fertilizer = convertToRecipe({
|
|
|
720
720
|
state.purchasedComposter > 0 && (state.itemsSold[compost.id] || 0) >= 10,
|
|
721
721
|
description: 'Helps crops grow and mature a little faster.',
|
|
722
722
|
enablesFieldMode: fieldMode.FERTILIZE,
|
|
723
|
-
recipeType: /** @type {farmhand.recipeType} */ recipeType.RECYCLING,
|
|
723
|
+
recipeType: /** @type {farmhand.recipeType} */ (recipeType.RECYCLING),
|
|
724
724
|
type: itemType.FERTILIZER,
|
|
725
725
|
value: 25,
|
|
726
726
|
})
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* @property farmhand.module:enums.cropType
|
|
8
8
|
* @enum {string}
|
|
9
9
|
*/
|
|
10
|
-
export const cropType = /** @type {const} */ {
|
|
10
|
+
export const cropType = /** @type {const} */ ({
|
|
11
11
|
ASPARAGUS: 'ASPARAGUS',
|
|
12
12
|
CARROT: 'CARROT',
|
|
13
13
|
CORN: 'CORN',
|
|
@@ -28,25 +28,25 @@ export const cropType = /** @type {const} */ {
|
|
|
28
28
|
WATERMELON: 'WATERMELON',
|
|
29
29
|
WHEAT: 'WHEAT',
|
|
30
30
|
WEED: 'WEED',
|
|
31
|
-
}
|
|
31
|
+
})
|
|
32
32
|
|
|
33
33
|
/**
|
|
34
34
|
* @property farmhand.module:enums.recipeType
|
|
35
35
|
* @enum {string}
|
|
36
36
|
*/
|
|
37
|
-
export const recipeType = /** @type {const} */ {
|
|
37
|
+
export const recipeType = /** @type {const} */ ({
|
|
38
38
|
FERMENTATION: 'FERMENTATION',
|
|
39
39
|
FORGE: 'FORGE',
|
|
40
40
|
KITCHEN: 'KITCHEN',
|
|
41
41
|
RECYCLING: 'RECYCLING',
|
|
42
42
|
WINE: 'WINE',
|
|
43
|
-
}
|
|
43
|
+
})
|
|
44
44
|
|
|
45
45
|
/**
|
|
46
46
|
* @property farmhand.module:enums.fieldMode
|
|
47
47
|
* @enum {string}
|
|
48
48
|
*/
|
|
49
|
-
export const fieldMode = /** @type {const} */ {
|
|
49
|
+
export const fieldMode = /** @type {const} */ ({
|
|
50
50
|
CLEANUP: 'CLEANUP',
|
|
51
51
|
FERTILIZE: 'FERTILIZE',
|
|
52
52
|
HARVEST: 'HARVEST',
|
|
@@ -56,13 +56,13 @@ export const fieldMode = /** @type {const} */ {
|
|
|
56
56
|
SET_SPRINKLER: 'SET_SPRINKLER',
|
|
57
57
|
SET_SCARECROW: 'SET_SCARECROW',
|
|
58
58
|
WATER: 'WATER',
|
|
59
|
-
}
|
|
59
|
+
})
|
|
60
60
|
|
|
61
61
|
/**
|
|
62
62
|
* @property farmhand.module:enums.stageFocusType
|
|
63
63
|
* @enum {string}
|
|
64
64
|
*/
|
|
65
|
-
export const stageFocusType = /** @type {const} */ {
|
|
65
|
+
export const stageFocusType = /** @type {const} */ ({
|
|
66
66
|
NONE: 'NONE', // Used for testing
|
|
67
67
|
HOME: 'HOME',
|
|
68
68
|
FIELD: 'FIELD',
|
|
@@ -72,23 +72,23 @@ export const stageFocusType = /** @type {const} */ {
|
|
|
72
72
|
INVENTORY: 'INVENTORY',
|
|
73
73
|
WORKSHOP: 'WORKSHOP',
|
|
74
74
|
CELLAR: 'CELLAR',
|
|
75
|
-
}
|
|
75
|
+
})
|
|
76
76
|
|
|
77
77
|
/**
|
|
78
78
|
* @property farmhand.module:enums.cropLifeStage
|
|
79
79
|
* @enum {string}
|
|
80
80
|
*/
|
|
81
|
-
export const cropLifeStage = /** @type {const} */ {
|
|
81
|
+
export const cropLifeStage = /** @type {const} */ ({
|
|
82
82
|
SEED: 'SEED',
|
|
83
83
|
GROWING: 'GROWING',
|
|
84
84
|
GROWN: 'GROWN',
|
|
85
|
-
}
|
|
85
|
+
})
|
|
86
86
|
|
|
87
87
|
/**
|
|
88
88
|
* @property farmhand.module:enums.itemType
|
|
89
89
|
* @enum {string}
|
|
90
90
|
*/
|
|
91
|
-
export const itemType = /** @type {const} */ {
|
|
91
|
+
export const itemType = /** @type {const} */ ({
|
|
92
92
|
COW_FEED: 'COW_FEED',
|
|
93
93
|
CRAFTED_ITEM: 'CRAFTED_ITEM',
|
|
94
94
|
CROP: 'CROP',
|
|
@@ -102,32 +102,32 @@ export const itemType = /** @type {const} */ {
|
|
|
102
102
|
STONE: 'STONE',
|
|
103
103
|
TOOL_UPGRADE: 'TOOL_UPGRADE',
|
|
104
104
|
WEED: 'WEED',
|
|
105
|
-
}
|
|
105
|
+
})
|
|
106
106
|
|
|
107
107
|
/**
|
|
108
108
|
* @property farmhand.module:enums.fertilizerType
|
|
109
109
|
* @enum {string}
|
|
110
110
|
*/
|
|
111
|
-
export const fertilizerType = /** @type {const} */ {
|
|
111
|
+
export const fertilizerType = /** @type {const} */ ({
|
|
112
112
|
NONE: 'NONE',
|
|
113
113
|
STANDARD: 'STANDARD',
|
|
114
114
|
RAINBOW: 'RAINBOW',
|
|
115
|
-
}
|
|
115
|
+
})
|
|
116
116
|
|
|
117
117
|
/**
|
|
118
118
|
* @property farmhand.module:enums.genders
|
|
119
119
|
* @enum {string}
|
|
120
120
|
*/
|
|
121
|
-
export const genders = /** @type {const} */ {
|
|
121
|
+
export const genders = /** @type {const} */ ({
|
|
122
122
|
FEMALE: 'FEMALE',
|
|
123
123
|
MALE: 'MALE',
|
|
124
|
-
}
|
|
124
|
+
})
|
|
125
125
|
|
|
126
126
|
/**
|
|
127
127
|
* @property farmhand.module:enums.cowColors
|
|
128
128
|
* @enum {string}
|
|
129
129
|
*/
|
|
130
|
-
export const cowColors = /** @type {const} */ {
|
|
130
|
+
export const cowColors = /** @type {const} */ ({
|
|
131
131
|
BLUE: 'BLUE',
|
|
132
132
|
BROWN: 'BROWN',
|
|
133
133
|
GREEN: 'GREEN',
|
|
@@ -136,7 +136,7 @@ export const cowColors = /** @type {const} */ {
|
|
|
136
136
|
RAINBOW: 'RAINBOW',
|
|
137
137
|
WHITE: 'WHITE',
|
|
138
138
|
YELLOW: 'YELLOW',
|
|
139
|
-
}
|
|
139
|
+
})
|
|
140
140
|
|
|
141
141
|
const { RAINBOW, ...standardCowColors } = cowColors
|
|
142
142
|
export { standardCowColors }
|
|
@@ -145,7 +145,7 @@ export { standardCowColors }
|
|
|
145
145
|
* @property farmhand.module:enums.dialogView
|
|
146
146
|
* @enum {string}
|
|
147
147
|
*/
|
|
148
|
-
export const dialogView = /** @type {const} */ {
|
|
148
|
+
export const dialogView = /** @type {const} */ ({
|
|
149
149
|
NONE: 'NONE',
|
|
150
150
|
ACCOUNTING: 'ACCOUNTING',
|
|
151
151
|
ACHIEVEMENTS: 'ACHIEVEMENTS',
|
|
@@ -155,50 +155,50 @@ export const dialogView = /** @type {const} */ {
|
|
|
155
155
|
PRICE_EVENTS: 'PRICE_EVENTS',
|
|
156
156
|
SETTINGS: 'SETTINGS',
|
|
157
157
|
STATS: 'STATS',
|
|
158
|
-
}
|
|
158
|
+
})
|
|
159
159
|
|
|
160
160
|
/**
|
|
161
161
|
* @property farmhand.module:enums.toolType
|
|
162
162
|
* @enum {string}
|
|
163
163
|
*/
|
|
164
|
-
export const toolType = /** @type {const} */ {
|
|
164
|
+
export const toolType = /** @type {const} */ ({
|
|
165
165
|
SCYTHE: 'SCYTHE',
|
|
166
166
|
SHOVEL: 'SHOVEL',
|
|
167
167
|
HOE: 'HOE',
|
|
168
168
|
WATERING_CAN: 'WATERING_CAN',
|
|
169
|
-
}
|
|
169
|
+
})
|
|
170
170
|
|
|
171
171
|
/**
|
|
172
172
|
* @property farmhand.module:enums.toolLevel
|
|
173
173
|
* @enum {string}
|
|
174
174
|
*/
|
|
175
|
-
export const toolLevel = /** @type {const} */ {
|
|
175
|
+
export const toolLevel = /** @type {const} */ ({
|
|
176
176
|
UNAVAILABLE: 'UNAVAILABLE',
|
|
177
177
|
DEFAULT: 'DEFAULT',
|
|
178
178
|
BRONZE: 'BRONZE',
|
|
179
179
|
IRON: 'IRON',
|
|
180
180
|
SILVER: 'SILVER',
|
|
181
181
|
GOLD: 'GOLD',
|
|
182
|
-
}
|
|
182
|
+
})
|
|
183
183
|
|
|
184
184
|
/**
|
|
185
185
|
* @property farmhand.module:enums.notificationSeverity
|
|
186
186
|
* @enum {string}
|
|
187
187
|
*/
|
|
188
|
-
export const notificationSeverity = /** @type {const} */ {
|
|
188
|
+
export const notificationSeverity = /** @type {const} */ ({
|
|
189
189
|
INFO: 'INFO',
|
|
190
190
|
SUCCESS: 'SUCCESS',
|
|
191
191
|
WARNING: 'WARNING',
|
|
192
192
|
ERROR: 'ERROR',
|
|
193
|
-
}
|
|
193
|
+
})
|
|
194
194
|
|
|
195
195
|
/**
|
|
196
196
|
* @property farmhand.module:enums.cowTradeRejectionReason
|
|
197
197
|
* @enum {string}
|
|
198
198
|
*/
|
|
199
|
-
export const cowTradeRejectionReason = /** @type {const} */ {
|
|
199
|
+
export const cowTradeRejectionReason = /** @type {const} */ ({
|
|
200
200
|
REQUESTED_COW_UNAVAILABLE: 'REQUESTED_COW_UNAVAILABLE',
|
|
201
|
-
}
|
|
201
|
+
})
|
|
202
202
|
|
|
203
203
|
/**
|
|
204
204
|
* @property farmhand.module:enums.cropFamily
|
|
@@ -17,11 +17,9 @@ export default class CoalFactory extends Factory {
|
|
|
17
17
|
const amount = chooseRandom([1, 1, 1, 2, 3])
|
|
18
18
|
|
|
19
19
|
for (let i = 0; i < amount; i++) {
|
|
20
|
-
// @ts-expect-error
|
|
21
20
|
spawns.push(this.spawnCoal())
|
|
22
21
|
}
|
|
23
22
|
|
|
24
|
-
// @ts-expect-error
|
|
25
23
|
spawns.push(this.spawnStone())
|
|
26
24
|
|
|
27
25
|
return spawns
|
|
@@ -12,10 +12,8 @@ export default class OreFactory extends Factory {
|
|
|
12
12
|
constructor() {
|
|
13
13
|
super()
|
|
14
14
|
|
|
15
|
-
// @ts-expect-error
|
|
16
15
|
this.oreOptions = []
|
|
17
16
|
for (let o of SPAWNABLE_ORES) {
|
|
18
|
-
// @ts-expect-error
|
|
19
17
|
this.oreOptions.push({
|
|
20
18
|
ore: o,
|
|
21
19
|
weight: o.spawnChance || 0,
|
|
@@ -37,7 +35,6 @@ export default class OreFactory extends Factory {
|
|
|
37
35
|
* @private
|
|
38
36
|
**/
|
|
39
37
|
spawn() {
|
|
40
|
-
// @ts-expect-error
|
|
41
38
|
const spawnedOption = randomChoice(this.oreOptions)
|
|
42
39
|
return spawnedOption.ore
|
|
43
40
|
}
|
|
@@ -32,7 +32,6 @@ let instance = null
|
|
|
32
32
|
*/
|
|
33
33
|
export default class ResourceFactory {
|
|
34
34
|
constructor() {
|
|
35
|
-
// @ts-expect-error
|
|
36
35
|
this.resourceOptions = [
|
|
37
36
|
{ weight: ORE_SPAWN_CHANCE, itemType: itemType.ORE },
|
|
38
37
|
{ weight: COAL_SPAWN_CHANCE, itemType: itemType.FUEL },
|
|
@@ -47,7 +46,6 @@ export default class ResourceFactory {
|
|
|
47
46
|
*/
|
|
48
47
|
static instance() {
|
|
49
48
|
if (!instance) {
|
|
50
|
-
// @ts-expect-error
|
|
51
49
|
instance = new ResourceFactory()
|
|
52
50
|
}
|
|
53
51
|
|
|
@@ -119,13 +117,11 @@ export default class ResourceFactory {
|
|
|
119
117
|
}
|
|
120
118
|
|
|
121
119
|
if (randomNumberService.isRandomNumberLessThan(spawnChance)) {
|
|
122
|
-
// @ts-expect-error
|
|
123
120
|
const opt = randomChoice(this.resourceOptions)
|
|
124
121
|
const factory = ResourceFactory.getFactoryForItemType(opt.itemType)
|
|
125
122
|
|
|
126
123
|
if (factory) {
|
|
127
124
|
const generated = factory.generate()
|
|
128
|
-
// @ts-expect-error
|
|
129
125
|
resources = Array.isArray(generated) ? generated : [generated]
|
|
130
126
|
}
|
|
131
127
|
}
|
|
@@ -28,7 +28,6 @@ describe('ResourceFactory', () => {
|
|
|
28
28
|
false
|
|
29
29
|
)
|
|
30
30
|
|
|
31
|
-
// @ts-expect-error
|
|
32
31
|
expect(ResourceFactory.instance().generateResources(shovelLevel)).toEqual(
|
|
33
32
|
[]
|
|
34
33
|
)
|
|
@@ -40,7 +39,6 @@ describe('ResourceFactory', () => {
|
|
|
40
39
|
)
|
|
41
40
|
vi.mocked(randomChoice).mockReturnValueOnce({ itemType: itemType.ORE })
|
|
42
41
|
|
|
43
|
-
// @ts-expect-error
|
|
44
42
|
ResourceFactory.instance().generateResources(shovelLevel)
|
|
45
43
|
const factory = ResourceFactory.getFactoryForItemType(itemType.ORE)
|
|
46
44
|
|
|
@@ -54,7 +52,6 @@ describe('ResourceFactory', () => {
|
|
|
54
52
|
)
|
|
55
53
|
vi.mocked(randomChoice).mockReturnValueOnce({ itemType: itemType.FUEL })
|
|
56
54
|
|
|
57
|
-
// @ts-expect-error
|
|
58
55
|
ResourceFactory.instance().generateResources(shovelLevel)
|
|
59
56
|
const factory = ResourceFactory.getFactoryForItemType(itemType.FUEL)
|
|
60
57
|
|
|
@@ -68,7 +65,6 @@ describe('ResourceFactory', () => {
|
|
|
68
65
|
)
|
|
69
66
|
vi.mocked(randomChoice).mockReturnValueOnce({ itemType: itemType.STONE })
|
|
70
67
|
|
|
71
|
-
// @ts-expect-error
|
|
72
68
|
ResourceFactory.instance().generateResources(shovelLevel)
|
|
73
69
|
const factory = ResourceFactory.getFactoryForItemType(itemType.STONE)
|
|
74
70
|
|
|
@@ -19,7 +19,6 @@ export async function getData(url = '', data = {}) {
|
|
|
19
19
|
)
|
|
20
20
|
|
|
21
21
|
// Default options are marked with *
|
|
22
|
-
// @ts-expect-error
|
|
23
22
|
const response = await fetch(`${url}?${params}`, {
|
|
24
23
|
...commonFetchConfig,
|
|
25
24
|
method: 'GET',
|
|
@@ -30,7 +29,6 @@ export async function getData(url = '', data = {}) {
|
|
|
30
29
|
|
|
31
30
|
export async function postData(url = '', data = {}) {
|
|
32
31
|
// Default options are marked with *
|
|
33
|
-
// @ts-expect-error
|
|
34
32
|
const response = await fetch(url, {
|
|
35
33
|
...commonFetchConfig,
|
|
36
34
|
method: 'POST',
|