Inheritance: DevCommand
Example #1
0
        public static bool TryParse(string c, out DevCommand command)
        {
            Match m;

            if ((m = REGEX1.Match(c)).Success)
            {
                command = new DevCommandFOW(FogOfWar.Active);
                return(true);
            }
            if ((m = REGEX2.Match(c)).Success)
            {
                command = new DevCommandFOW(FogOfWar.Nothing);
                return(true);
            }
            command = null;
            return(false);
        }
 private void ApplyLogic(GameState s, float dt, DevCommandFOW c)
 {
     foreach(var task in tbFOWCalculations.Tasks) {
         var t = task as FOWTask;
         t.SetAllFOW(c.fow, s.CGrid);
     }
 }
Example #3
0
 public static bool TryParse(string c, out DevCommand command)
 {
     Match m;
     if((m = REGEX1.Match(c)).Success) {
         command = new DevCommandFOW(FogOfWar.Active);
         return true;
     }
     if((m = REGEX2.Match(c)).Success) {
         command = new DevCommandFOW(FogOfWar.Nothing);
         return true;
     }
     command = null;
     return false;
 }