Beispiel #1
0
 public PedProp this[PedPropType propId]
 {
     get
     {
         if (!_pedProps.TryGetValue(propId, out PedProp prop))
         {
             prop = new PedProp(_ped, propId);
             _pedProps.Add(propId, prop);
         }
         return(prop);
     }
 }
 public PedProp this[PedProps propId]
 {
     get
     {
         PedProp prop = null;
         if (!this._pedProps.TryGetValue(propId, out prop))
         {
             prop = new PedProp(this._ped, propId);
             this._pedProps.Add(propId, prop);
         }
         return(prop);
     }
 }
Beispiel #3
0
        public PedProp[] GetAllProps()
        {
            List <PedProp> props = new List <PedProp>();

            foreach (PedProps propId in Enum.GetValues(typeof(PedProps)))
            {
                PedProp prop = this[propId];
                if (prop.HasAnyVariations)
                {
                    props.Add(prop);
                }
            }
            return(props.ToArray());
        }
        public PedProp[] GetAllProps()
        {
            List <PedProp> list = new List <PedProp>();

            foreach (PedProps props in Enum.GetValues(typeof(PedProps)))
            {
                PedProp item = this[props];
                if (item.HasAnyVariations)
                {
                    list.Add(item);
                }
            }
            return(list.ToArray());
        }