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
Door isn't working right!
Imevil23 Offline
Member

Posts: 83
Threads: 23
Joined: Jan 2012
Reputation: 0
#1
Sad  Door isn't working right!

Yes, I have yet another issue. But I'm learning. So anyway, I'm completely done with the first map and is currently making the second map, but I want to connect them. I've looked at tutorials and did everything correctly, but when I go to test it out, it's still locked/ wont go to the next area! It even takes the key and makes the unlocking noise, but it wont go into the next map. If you can help me (again) please leave a reply.

02-01-2012, 08:13 PM
Find
trollox Offline
Member

Posts: 215
Threads: 16
Joined: Dec 2011
Reputation: 3
#2
RE: Door isn't working right!

Easy you need to go inside of the map editor select the door and press "entity" Once ther go to the "MapFile" and select the level you which it to lead to. Easy as that.

Trollox.
02-01-2012, 08:17 PM
Find
Imevil23 Offline
Member

Posts: 83
Threads: 23
Joined: Jan 2012
Reputation: 0
#3
RE: Door isn't working right!

(02-01-2012, 08:17 PM)trollox Wrote: Easy you need to go inside of the map editor select the door and press "entity" Once ther go to the "MapFile" and select the level you which it to lead to. Easy as that.

Trollox.
I did that, but it still didn't work. Maybe I should delete and replace the door. It's worth a shot. Or maybe the selected map was in another folder since I tend to move the maps around.



02-01-2012, 08:24 PM
Find
trollox Offline
Member

Posts: 215
Threads: 16
Joined: Dec 2011
Reputation: 3
#4
RE: Door isn't working right!

Yeah most be in the same folder.
02-01-2012, 08:33 PM
Find
Prelauncher Offline
Senior Member

Posts: 451
Threads: 11
Joined: May 2011
Reputation: 13
#5
RE: Door isn't working right!

You also must select where on the map the player will start: StartPos

Socialism (noun): A great way to run out of other people's money.
02-01-2012, 09:00 PM
Find
Zjurc Offline
Junior Member

Posts: 43
Threads: 8
Joined: Jan 2012
Reputation: 0
#6
RE: Door isn't working right!

Ahh i see what you mean - regular doors and and level doors have a DIFFERENT type of script!
This should help you:

void OnStart()
{
AddUseItemCallback("", "KEYNAME", "LEVELDOOR", "KeyOnDoor", true);
}

void KeyOnDoor(string &in asItem, string &in asEntity)
{
SetLevelDoorLocked("LEVELDOOR", false);
PlaySoundAtEntity("", "unlock_door", "LEVELDOOR", 0, false);
RemoveItem("KEYNAME");
}

KEYNAME - name of your key, of course. To avoid any problems name your key without any numbers -
'Name' section and "CustomSubItemTypeName" section should also be named the same - can be different but i prefer same (its easier)
LEVELDOOR - obviously name of your door. the door does not need "CustomSubItemTypeName" as far as I know.
02-03-2012, 07:38 PM
Find




Users browsing this thread: 1 Guest(s)