Ejemplo n.º 1
0
        public override bool minutesElapsed(int minutes, GameLocation environment)
        {
            this.updateInfo();
            //ModCore.log(this.info.animationManager.currentAnimationName);

            if (this.updatesContainerObjectForProduction)
            {
                //ModCore.log("Update container object for production!");
                //this.MinutesUntilReady -= minutes;
                int remaining = minutes;
                //ModCore.log("Minutes elapsed: " + remaining);
                while (remaining > 0)
                {
                    if (LocationUtilities.IsThereWaterAtThisTile(environment, (int)this.TileLocation.X, (int)this.TileLocation.Y))
                    {
                        this.GetFluidManager().produceFluid(ModCore.ObjectManager.resources.getFluid("Water"), 100);
                    }
                    remaining -= 10;
                }

                return(false);
            }
            return(false);

            //return base.minutesElapsed(minutes, environment);
        }
Ejemplo n.º 2
0
        public override bool minutesElapsed(int minutes, GameLocation environment)
        {
            int remaining = minutes;

            while (remaining > 0)
            {
                if (LocationUtilities.IsThereWaterAtThisTile(environment, (int)this.TileLocation.X, (int)this.TileLocation.Y))
                {
                    this.GetFluidManager().produceFluid(ModCore.ObjectManager.resources.getFluid("Water"), 100);
                }
                remaining -= 10;
            }
            return(false);
        }