/// <summary>
 /// Creates a new Returnable Item.
 /// Textures and attributes of the Item are assigned by passed-in Type
 /// from list constructor (above) through a switch statement.
 /// </summary>
 /// <param name="type">Type of Returnable Item</param>
 public returnableItem(returnablesLIST.Type newType)
 {
     #region SWITCH FOR TYPE OF RETURNABLE
     switch (newType)
     {
         case returnablesLIST.Type.glass:
             type = newType;
             break;
         case returnablesLIST.Type.plastic:
             type = newType;
             break;
         case returnablesLIST.Type.can:
             type = newType;
             break;
     }
     #endregion
 }
예제 #2
0
        /// <summary>
        /// This function creates a new character for use by the player, based on the
        /// parameters passed in from the "createCharacter" function in the
        /// "characterSelection" class.
        /// </summary>
        /// <param name="alcoholTolerance"></param>
        /// <param name="bodyOdor"></param>
        /// <param name="temperment"></param>
        /// <param name="courage"></param>
        /// <param name="speed"></param>
        /// <param name="clumsiness"></param>
        /// <param name="radial"></param>
        /// <param name="fuzz"></param>
        /// <param name="shaking"></param>
        /// <param name="handTexture"></param>
        public character(float alcoholTolerance, float bodyOdor, float temperment, float courage, 
                            int carryingCapacity, float speed, float clumsiness, string name, float radial,
                            float fuzz, float shaking, Texture2D portrait)
        {
            DATA = new charactersData(alcoholTolerance, bodyOdor, temperment, courage, speed, clumsiness, name);
            VISUALS = new characterVisuals(radial, fuzz, shaking);
            INVENTORY = new returnablesLIST(carryingCapacity);
            VOUCHERS = new List<ticket>();

            intoxicationLevel = 15;
            odorLevel = 25;
            energy = 100;
            wantedLevel = 1;

            cash = 0;
            this.carryingCapacity = carryingCapacity;
            face = portrait;
            ticketsValue = 0;
            score = 0;
            scoreThreshold = 15000;
        }