I am trying to set the boolean newEnergy to true only when the item is found. However, it is true at the beginning of the game and remains true until the command 'use' is used. Is there anyway to set newEnergy = true only when the item is found or taken?

        //Add Energy
        Item energy = new Item(" Double energy. \n" + "Type 'use' or 'consume' to use the energy. \n", "energy", 0);
        newEnergy = true;

Initialise it to false, then set it to true in the code where you find or take an item? Or is the problem actaually more complicated than that?