Beispiel #1
0
        public VegetableClass this[int index]
        {
            get
            {
                return(state.vegetablesOnLevel[levelIndx][index]);
            }

            set
            {
                state.vegetablesOnLevel[levelIndx][index] = value;
                state.saveVegetable(
                    levelIndx,
                    index,
                    state.vegetablesOnLevel[levelIndx][index].Health,
                    state.vegetablesOnLevel[levelIndx][index].Damage,
                    state.vegetablesOnLevel[levelIndx][index].Score,
                    state.vegetablesOnLevel[levelIndx][index].Speed,
                    state.vegetablesOnLevel[levelIndx][index].Prefab,
                    state.vegetablesOnLevel[levelIndx][index].Cost
                    );
            }
        }