def close_lid(self):

        if not self.db.lid_open:
            return
        desc = self.db.desc_lid_closed
        if not desc:
            desc = "This is a large red button, inviting yet evil-looking. "
            desc += "Its glass cover is closed, protecting it."
        self.db.desc = desc
        self.db.lid_open = False

        # clean out scripts depending on lid to be open
        self.scripts.validate()
        # add scripts related to the closed state
        self.scripts.add(scriptexamples.ClosedLidState)
Close the glass lid. This validates all scripts on the button,
dataset/ETHPy150Open evennia/evennia/evennia/contrib/tutorial_examples/red_button.py/RedButton.close_lid