示例#1
0
        internal Pop(Depart depart, string name, double num, string party)
        {
            this.name = name;

            this.depart = depart;
            this.num    = (decimal)num;

            if (def.is_family)
            {
                var person_num = (int)num / 150;
                this.family = new Family(person_num > 3 ? person_num : 3, party);
            }

            if (def.is_collect_tax)
            {
                this.tax         = new ObsBufferedValue();
                this.adminExpend = new ObsBufferedValue();
            }

            if (def.consume != null)
            {
                this.consume = new ObsBufferedValue();
            }

            DataReactive(new StreamingContext());
        }
示例#2
0
 private Person()
 {
     this.relation = new ObsBufferedValue();
 }