Exemplo n.º 1
0
        void TryUpdate(BTriggerSystem ts, BTriggerCondition cond)
        {
            TriggerProtoDbObject dbo;

            if (!LookupTableContains(cond, out dbo))
            {
                var dbo_cond = new BTriggerProtoCondition(ts, cond);

                Conditions.DynamicAdd(dbo_cond, dbo_cond.Name);
                LookupTableAdd(dbo_cond);
            }
            else
            {
                int diff = dbo.CompareTo(ts, cond);
                if (diff < 0)
                {
                    var dbo_cond = new BTriggerProtoCondition(ts, cond);
                    LookupTable[GenerateHandle(cond)] = dbo_cond;
                    TraceUpdate(ts, dbo_cond);
                }
            }
        }
 public BTriggerProtoCondition(BTriggerSystem root, BTriggerCondition instance) : base(root, instance)
 {
     mAsync             = instance.Async;
     mAsyncParameterKey = instance.AsyncParameterKey;
 }