/// <summary> /// Use this function to store weapons. It is a helper function for EquipLeftHand() /// and EquipRightHand(). /// </summary> /// <param name="weap">The "hand" holding the weapon to store</param> private bool storeWeapon(ref Weapon hand) { // Attempt to store existing weapon if currently holding one if (hand != null) { // Store the item in if (PlayerSettingsReference.AddItem(hand as Item)) { // Clear the hand hand = null; return(true); } else { return(false); } } return(false); }