Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System.Collections.Generic;
- using UnityEngine;
- public class Encyclopedia : MonoBehaviour
- {
- public enum PlantKind
- {
- Borage,
- Camellia, Caraway, Chamomile, Chicory, Clove, ClubMoss,
- Dandelion,
- Eyebright,
- Fairywand,
- Galbanum, GardenPea, GroundElder,
- Heather,
- LemonMyrtle, Licorice, LilyValley,
- Moonwort, Mugwort,
- Parsley, Primrose,
- Rosemary,
- SickleHareEar, SolomonSeal,
- Tragacanth, Turmeric,
- Vetiver,
- WitchGrass, WoodSorrel,
- Yarrow, Fern, Rose
- };
- public enum PlantEffects
- {
- Abundance,
- Calm,
- Change,
- Cleansing,
- Creativity,
- ElementAir,
- ElementEarth,
- ElementFire,
- ElementWater,
- Energy,
- Friendship,
- Growth,
- Happiness,
- Healing,
- Love,
- Luck,
- Moon,
- Protection,
- Strength,
- Sun,
- Truth,
- Wishes,
- Wisdom,
- Witchcraft
- }
- // A class to store information about a single plant
- public class PlantEntry
- {
- public string name;
- public string info;
- }
- public class PlantEffectMagnitude
- {
- public string effectName;
- public float effectMag;
- }
- // A dictionary to store information about all of the plants
- public static Dictionary<PlantKind, PlantEntry> allPlants = new()
- {
- { PlantKind.Borage, new PlantEntry() { name = "Borage", info = "Borage is often used to boost courage." }, new PlantEffects() { Abundance } },
- { PlantKind.Camellia, new PlantEntry() { name = "Camellia sinensis", info = "This is tea." } },
- { PlantKind.Fern, new PlantEntry() { name = "Fern", info = "This is fern." } },
- { PlantKind.Dandelion, new PlantEntry() { name = "Dandelion", info = "This is dandelion." } },
- { PlantKind.Rose, new PlantEntry() { name = "Rose", info = "This is rose." } }
- };
- public static PlantEntry GetEntry(PlantKind plantKind)
- {
- return allPlants[plantKind];
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement