I’m trying to make a box that unlocks when you put in a passcode, just like on a padlock. When I put in the correct code, everything is fine and my box says what I want it to. But when I try to open or unlock the box, I get these:
open box
(first unlocking the jewelry box)
You lack a key that fits the jewelry box.
unlock box
You lack a key that fits the jewelry box.
There is no key to this box, so I don’t want this message. This happens even after I put the code in to “open” the box. I think that inputting the correct code doesn’t actually open the box, it just shows the message that I wrote.
So, I need to make it so that setting the dial to the correct code actually opens the box, and I need to remove a key from the equation.
Can we see the code you used for this? A snapshot of the problem, that is. You might have not changed the box’s locked state. You will likely want a unique “check unlocking” rule, or at least a unique message for the existing one.
EDIT: Additionally, would you be having multiple code-puzzles like this in your game? Would it be standard behaviour, or a one-time solution for a single puzzle?