3 Keys, One Door- Resolved
Posted: Wed Oct 17, 2012 4:24 pm
Hello,
My hope is that this is something basic in the scripting, but I'm having a devil of a time figuring it out. I have 1 door. Beside it are three locks on the wall. (Gold, Ornate and Circle). Spread around the dungeon are the three keys. I want the door to open only once all three keys have been put into their locks. What I am having a hard time figuring out is how to read if the locks have the keys in them. Is there an element in the scripting that will return "True" if the keys have been entered into the locks?
From the scripting reference I see we have this: Lock:setOpenedBy(key)
If I check the status of that, will it return True/False?
Any assistance on this is greatly appreciated.
EDIT: All that is required is a counter- See below.
My hope is that this is something basic in the scripting, but I'm having a devil of a time figuring it out. I have 1 door. Beside it are three locks on the wall. (Gold, Ornate and Circle). Spread around the dungeon are the three keys. I want the door to open only once all three keys have been put into their locks. What I am having a hard time figuring out is how to read if the locks have the keys in them. Is there an element in the scripting that will return "True" if the keys have been entered into the locks?
From the scripting reference I see we have this: Lock:setOpenedBy(key)
If I check the status of that, will it return True/False?
Any assistance on this is greatly appreciated.
EDIT: All that is required is a counter- See below.