Product Chat / Key Door Unlock Help

Author
Message
IBOL
20
Years of Service
User Offline
Joined: 30th Mar 2004
Location: @IBOL17
Posted: 18th Mar 2018 15:42
Hi all, seasoned DBP/AGK user here, brand new to GG...

I have tried and failed to create a simple door+key combination.

I have a door and a key.
I can make the door not open , but even putting the key in the "unlocks with" slot in the properties editor, either the door always unlocks regardless, or it never unlocks (i removed the lua script).

I also tried setting that door to "not spawn at start" , and replacing it with a static door , but then you can never get thru, the unlocking door doesn't spawn.

So what is the correct step-by-step process to create a door / key system?

Thanks,
Bob

Attachments

Login to view attachments
AmenMoses
GameGuru Master
8
Years of Service
User Offline
Joined: 20th Feb 2016
Location: Portsmouth, England
Posted: 18th Mar 2018 18:23
I just tried it, put down a door (has door.lua script) and typed 'Key' into the 'Use Key' parameter field, placed down a key (helpfully called 'Key') and it all worked fine.

Been there, done that, got all the T-Shirts!
PM
IBOL
20
Years of Service
User Offline
Joined: 30th Mar 2004
Location: @IBOL17
Posted: 19th Mar 2018 14:39 Edited at: 20th Mar 2018 12:48
maybe it has to do with the order in which things are placed into the world, i will try it.
[edit]
ok, i have eventually gotten this to work.
Len the man
8
Years of Service
User Offline
Joined: 12th Jun 2015
Location:
Posted: 20th Mar 2018 20:27 Edited at: 20th Mar 2018 20:28
(1) Click on the door and then click "properties"... (2) click on the section labeled "Use Key" in the properties menu on the left... (3) in the "Use Key" section type Key1... (4) At the lower left click "Apply Changes". (5) Then click on the key entity and click properties, (6) then at the top labeled "Name" in the properties menu, type Key1. Also make sure the door isn't static by going to the section labeled "Static" and set it to "No"... Also make sure the section labeled "Main" is set to the script "door.lua"...

I think this should work...

I had problems with this also, when I first started using GG...

I hope this helps.
PM
synchromesh
Forum Support
10
Years of Service
User Offline
Joined: 24th Jan 2014
Location:
Posted: 21st Mar 2018 01:07 Edited at: 21st Mar 2018 01:08
Lets make it easier .... " Anything can be a key "

Put an axe on the floor ( press Y to make it active ...Green )
Add " key.lua " to it .. and make sure you name it AXE

Select Properties on the door and type AXE in the "use key " field
That's it ... now the axe becomes a key ...

Use the key in the same way .... but objects make this less confusing to explain
The only person ever to get all his work done by "Friday" was Robinson Crusoe..
PM

Login to post a reply

Server time is: 2024-04-27 02:02:39
Your offset time is: 2024-04-27 02:02:39