public static void TryDroppingItem(string itemName) { // try to drop from inventory IItem droppedItem = Player.Drop(itemName); if (droppedItem != null) { // print result of action IO.OutputNewLine("You dropped the " + itemName + "."); // then add back to current room CurrentRoom.AddItem(droppedItem); } else { IO.OutputNewLine(GameStrings.NotInInventory); } }