Пример #1
0
        public pWeaponLaunchType(string parent, pEngramRange engramRange, string child, string target, int time,
                           string initialState, Dictionary<string, object> startupParameters)
        {
            this.parent = parent;
            this.engramRange = engramRange;
            this.child = child;
            this.time = time;
            this.target = target;
            this.initialState = initialState;
            this.startupParameters = startupParameters;

        }
Пример #2
0
 public pApplyType(pEngramRange engramRange, string fromDM, string toDM, int time)
 {
     this.engramRange = engramRange;
     this.fromDM = fromDM;
     this.toDM = toDM;
     this.time = time;
 }
Пример #3
0
        public pAttack_Request_Approval_Type(string capability, string actor, Boolean actorIsSpecies, string target, Boolean targetIsSpecies,
List<string> targetStates, Boolean useDefault, pEngramRange engramRange, string failure)
        {
            this.capability = capability;
            this.actor = actor;
            this.actorIsSpecies = actorIsSpecies;
            this.target = target;
            this.targetIsSpecies = targetIsSpecies;
            this.useDefault = useDefault;
            this.engramRange = engramRange;
            this.failure = failure;
            if (null != targetStates)
                for (int i = 0; i < targetStates.Count; i++)
                {
                    this.targetStates.Add(targetStates[i]);
                }
        }
Пример #4
0
        public pLaunchType(string parent, pEngramRange engramRange, string child, string kind, int time, pLocationType relativeLocation,
                           string initialState, Dictionary<string, object> startupParameters)
        {
            this.parent = parent;
            this.engramRange = engramRange;
            this.child = child;
            this.kind = kind;
            this.time = time;
            this.relativeLocation = relativeLocation;
            this.initialState = initialState;
            this.startupParameters = startupParameters;

        }
Пример #5
0
         public pRemoveVoiceChannelAccessType(pEngramRange engramRange, string decisionMaker, string voiceChannel, int time)
 {
     this.engramRange = engramRange;
     this.decisionMaker = decisionMaker;
     this.voiceChannel = voiceChannel;
     this.time = time;
 }
Пример #6
0
 /*       private List<object> targetDoThisList = new List<object>();
        public List<object> TargetDoThisList
        {
            get
            { return targetDoThisList; }
            set { targetDoThisList = value; }
        }
        */
 public pAttack_Successful_Completion_Type(string species, string capability, List<object> doThisList, string targetSpecies, /*List<object> targetDoThisList,*/ pEngramRange engramRange, string newState)
 {
     // nb -- either list or Target Species can be null/empty
     this.species = species;
     if (null == targetSpecies)
     {
         this.targetSpecies = "";
     }
     else
     {
         this.targetSpecies = targetSpecies;
     }
     this.capability = capability;
     if (doThisList != null)
     {
         for (int i = 0; i < doThisList.Count; i++)
         {
             this.doThisList.Add(doThisList[i]);
         }
     }
     /*          if (targetDoThisList != null)
               {
                   for (int i = 0; i < targetDoThisList.Count; i++)
                   {
                       this.targetDoThisList.Add(targetDoThisList[i]);
                   }
               }*/
     this.engramRange = engramRange;
     if (newState != null)
         this.newState = newState;
 }
Пример #7
0
        public pStateChangeType(string unitID, pEngramRange engramRange, int timer,
            string newState)
        {
            this.unitID = unitID;
            this.engramRange = engramRange;
            this.timer = timer;
            this.newState = newState;

        }
Пример #8
0
 public pTransferType(string unitID, pEngramRange engramRange, int timer, string from, string to)
 {
     this.unitID = unitID;
     this.engramRange = engramRange;
     this.timer = timer;
     this.from = from;
     this.to = to;
 }
Пример #9
0
        /// <summary>
        /// Creates a completion triggered  event
        /// </summary>
        /// <param name="unit">Indentifier for unit</param>
        /// <param name="action">action that triuggers new event</param>
        /// <param name="doThis">New event</param>
        public pHappeningCompletionType(string unit, pEngramRange engramRange, string action, string newState)
        {
            this.unit = unit;
            this.engramRange = engramRange;
            this.action = action;
            this.newState = newState;


        }
Пример #10
0
 public pReiterateType(int start, pEngramRange engramRange)
 {
     this.start = start;
     this.engramRange = engramRange;
 }
Пример #11
0
 public pMoveType(string unitID, pEngramRange engramRange, int timer,
     pLocationType location, double throttle)
 {
     this.engramRange = engramRange;
     this.unitID = unitID;
     this.timer = timer;
     this.throttle = throttle;
     this.location = location;
     randomInterval = new pRandomIntervalType(0, 0);
 }
Пример #12
0
 public pRevealType(string unitID, pEngramRange engramRange, int time, pLocationType initialLocation,
                    string initialState, Dictionary<string, object> startupParameters)
 {
     this.unitID = unitID;
     this.engramRange = engramRange;
     this.time = time;
     this.initialLocation = initialLocation;
     this.initialState = initialState;
     this.startupParameters = startupParameters;
 }
Пример #13
0
 public EngramRange(pEngramRange range)
 {
     this.name = range.Name;
     this.unit = range.Unit;
     if ("" != range.Condition)
     {
         this.condition = range.Condition;
         this.compareTo = range.CompareTo;
     }
     else
     {
         this.testForIncluded = range.InclusionRange;
         this.values = range.ValueList;
     }
 }
Пример #14
0
        public override pEngramRange pGetEngramRange()
        {
            string name = "Unknown item";
            string unit = "";
            Boolean inclusionRange = false;
            List<string> valueList;
            string condition;
            string compareTo;
            pEngramRange returnValue;
            try
            {
                reader.Read();
                name = pGetString();
                if ("Unit" == reader.Name)
                    unit = pGetString();
                if ("Comparison" == reader.Name)
                {
                    reader.Read();//bypass "Comparison"
                    condition = pGetString();
                    compareTo = pGetString();
                    reader.ReadEndElement();
                    returnValue = new pEngramRange(name, unit, condition, compareTo);
                }
                else
                {
                    if ("Included" == reader.Name)
                    {
                        inclusionRange = true;
                    }
                    //Now get the block with the range values
                    //           reader.Read(); // pass the <Inclusion>/<Exclusion>
                    returnValue = new pEngramRange(name, unit, inclusionRange);

                    valueList = pGetStringList(commaRegex);
                    for (int i = 0; i < valueList.Count; i++) returnValue.Add(valueList[i]);
                    //  reader.ReadEndElement();
                }
                reader.ReadEndElement();
                return returnValue;

            }
            catch (SystemException e)
            {
                throw new ApplicationException("Error reading EngramRange with name " + name + ": " + e.Message);

            }

        }
Пример #15
0
        public override pEngramRange pGetEngramRange()
        {
            string name = "Unknown item";
            Boolean inclusionRange = false;
            List<string> valueList;
            try
            {
                reader.Read();
                name = pGetString();
                if ("Included" == reader.Name)
                {
                    inclusionRange = true;
                }
                //Now get the block with the range values
                //           reader.Read(); // pass the <Inclusion>/<Exclusion>
                pEngramRange returnValue = new pEngramRange(name, inclusionRange);
                //   while ("Value" == reader.Name)
                //   {
                //     returnValue.Add(pGetString());
                valueList = pGetStringList(commaRegex);
                for (int i = 0; i < valueList.Count; i++) returnValue.Add(valueList[i]);
                //    }
                //        reader.ReadEndElement();
                reader.ReadEndElement();
                return returnValue;

            }
            catch (SystemException e)
            {
                throw new ApplicationException("Error reading EngramRange with name " + name + ": " + e.Message);

            }

        }