Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Level Doors
XeOnTricks Offline
Junior Member

Posts: 27
Threads: 12
Joined: Feb 2017
Reputation: 0
#1
Level Doors

i was trying to lock and unlock a level door and i got most of the things right but when i went to go use the key on the level door all it did was make the unlock sound and i didn't unlock the level door. what am i doing wrong?
03-05-2017, 08:34 AM
Find
FlawlessHappiness Offline
Posting Freak

Posts: 3,980
Threads: 145
Joined: Mar 2012
Reputation: 171
#2
RE: Level Doors

Is it possible that you used SetSwingDoorLocked and not SetLevelDoorLocked?

PHP Code: (Select All)
SetLevelDoorLocked(stringasNamebool abLocked); 

Also make sure the name of the door in the editor and in the script is the same.

Trying is the first step to success.
03-05-2017, 02:32 PM
Find
XeOnTricks Offline
Junior Member

Posts: 27
Threads: 12
Joined: Feb 2017
Reputation: 0
#3
RE: Level Doors

heres my script. idk whats wrong with it.


AddUseItemCallback("", "Key", "LevelDoor", "UnlockLevel", true);
}




void UnlockLevel(string &in asItem, string &in asEntity)
{
SetLevelDoorLocked("LevelDoor", false);

PlaySoundAtEntity("", "unlock_door.snt", asEntity, 0, false);

RemoveItem(asItem);
}
03-06-2017, 05:59 AM
Find
Romulator Offline
Not Tech Support ;-)

Posts: 3,628
Threads: 63
Joined: Jan 2013
Reputation: 195
#4
RE: Level Doors

Is your door named LevelDoor in the editor?

You could even change the code's SetLevelDoorLocked(); code to reference the asEntity variable so that it unlocks the door you defined in the AddUseItemCallback();.

PHP Code: (Select All)
SetLevelDoorLocked(asEntityfalse); 

Discord: Romulator#0001
[Image: 3f6f01a904.png]
03-06-2017, 08:22 AM
Find
Traggey Offline
is mildly amused

Posts: 3,257
Threads: 74
Joined: Feb 2012
Reputation: 185
#5
RE: Level Doors

Moooving this to development support.
03-07-2017, 02:05 PM
Find
XeOnTricks Offline
Junior Member

Posts: 27
Threads: 12
Joined: Feb 2017
Reputation: 0
#6
RE: Level Doors

(03-07-2017, 02:05 PM)Traggey Wrote: Moooving this to development support.

i apologize if this was in the wrong place, still new to this forum :/
03-11-2017, 11:38 PM
Find
Slanderous Offline
Posting Freak

Posts: 1,606
Threads: 78
Joined: Dec 2012
Reputation: 63
#7
RE: Level Doors

(03-11-2017, 11:38 PM)XeOnTricks Wrote:
(03-07-2017, 02:05 PM)Traggey Wrote: Moooving this to development support.

i apologize if this was in the wrong place, still new to this forum :/

Just so that you know, this is the section where we post all the technical issues concerining modding.
(This post was last modified: 03-12-2017, 12:02 PM by Slanderous.)
03-12-2017, 12:01 PM
Find




Users browsing this thread: 3 Guest(s)