コード例 #1
0
    public IEnumerator JSONWriteTest()
    {
        UpgradeSystem upgradeSystem = new UpgradeSystem();
        Upgrade       testUpgrade   = new Upgrade("Bomb Count", 1);

        upgradeSystem.AddUpgrade(testUpgrade);
        testUpgrade = new Upgrade("Speed", 2);
        upgradeSystem.AddUpgrade(testUpgrade);
        testUpgrade = new Upgrade("Range", 5);
        upgradeSystem.AddUpgrade(testUpgrade);
        UpgradeSystem.SaveUpgrades(upgradeSystem.GetUpgradeList());
        yield return(null);
    }
コード例 #2
0
        public IEnumerator JSONWriteTest()
        {
            UpgradeSystem upgradeSystem = new UpgradeSystem();
            Upgrade       testUpgrade   = new Upgrade("Attack", 1);

            upgradeSystem.AddUpgrade(testUpgrade);

            /*testUpgrade = new Upgrade("Speed", 2);
            *  upgradeSystem.AddUpgrade(testUpgrade);
            *  testUpgrade = new Upgrade("Range", 5);
            *  upgradeSystem.AddUpgrade(testUpgrade);*/
            upgradeSystem.SaveUpgrades();
            yield return(null);
        }