Exemplo n.º 1
0
        /// <summary>
        /// Adds a new item to Vehicle class list
        /// </summary>
        /// <param name="id">id of item</param>
        /// <param name="vehicle">vehicle class name</param>
        /// <param name="side">sets the side of the item, values: WEST,EAST,GUER,CIV,LOGIC,AMBIENT LIFE,EMPTY</param>
        /// <param name="position">position array</param>
        /// <param name="placement">placement radius</param>
        /// <param name="azimut">rotational radius 0 - 365</param>
        /// <param name="offsetY">offset in Y direction</param>
        /// <param name="special">Special flag of item, values: NONE, CARGO, FLY, IN FORMATION</param>
        /// <param name="player">Control flag, values: PLAY CDG, PLAYER COMMANDER, NON PLAYABLE</param>
        /// <param name="str_lock">Itel locked flag, values: UNLOCKED, LOCKED, LOCKEDPLAYER,DEFAULT</param>
        /// <param name="rank">rank of item, values: CORPORAL,SERGEANT,LIEUTENANT,CAPTAIN,MAJOR,COLONEL,PRIVATE</param>
        /// <param name="age">info age of item, values: ACTUAL, 5 MIN,10 MIN,15 MIN,30 MIN,60 MIN,120 MIN, UNKNOWN</param>
        /// <param name="text">item name, could be empty</param>
        /// <param name="init">init code of item, could be empty</param>
        /// <param name="description">item description, could be empty</param>
        /// <param name="skill">0.0 - 1.0 skill of item</param>
        /// <param name="health">0.0 - 1.0 health of item</param>
        /// <param name="fuel">0.0 - 1.0 fuel of item</param>
        /// <param name="ammo">0.0 - 1.0 ammo of item</param>
        /// <param name="presence">0.0 - 1.0 presence of item</param>
        /// <param name="presenceCondition">presence condition code</param>
        /// <param name="leader">leader of group 0 or 1</param>
        public void AddItem(int id,
                            string vehicle,
                            string side,
                            SqmPosition position,
                            double placement,
                            double azimut,
                            double offsetY,
                            string special,
                            string player,
                            string str_lock,
                            string rank,
                            string age,
                            string text,
                            string init,
                            string description,
                            double skill,
                            double health,
                            double fuel,
                            double ammo,
                            double presence,
                            string presenceCondition,
                            int leader
                            )
        {
            Vehicles_Item item = new Vehicles_Item();

            item.id                = id;
            item.vehicle           = vehicle;
            item.side              = side;
            item.position          = position;
            item.placement         = placement;
            item.azimut            = azimut;
            item.offsetY           = offsetY;
            item.special           = special;
            item.player            = player;
            item.str_lock          = str_lock;
            item.rank              = rank;
            item.age               = age;
            item.text              = text;
            item.init              = init;
            item.description       = description;
            item.skill             = skill;
            item.health            = health;
            item.fuel              = fuel;
            item.ammo              = ammo;
            item.presence          = presence;
            item.presenceCondition = presenceCondition;
            item.leader            = leader;
            ItemsList.Add(item);
        }
Exemplo n.º 2
0
 public void AddItem(Vehicles_Item item)
 {
     ItemsList.Add(item);
 }