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


Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
DOOR PROBLEM.. >:o
MicroDude Offline
Junior Member

Posts: 11
Threads: 1
Joined: Feb 2012
Reputation: 0
#1
DOOR PROBLEM.. >:o



THE PROBLEM WAS THAT MY SCRIPT DID NOT WORK...

The solution was to rename my 2 files (.hps and .map) into the correct ones as they had diffrent names. So what i did was to rename A gentlemans dream to A_Gentlemans_Dream









Okay so basically i cant get a door to close on a trigger/area..

I am going to provide all the things that you guys could need.. I guess its just something easy
as pie.. Anyways lets get started ..

HERE IS MY PROBLEM INGAME U WILL PROBABLY UNDERSTAND WHERE IM POINTING:




PHOTO OF SCRIPT (For seeing if i got correct scripting language (.HPS))
directlink: http://lookpic.com/O/i2/1597/ANEk4zSl.png
[Image: ANEk4zSl.png]

SCRIPT IN TEXT:

////////////////////////////
// Run First time starting map
void OnStart()

{
AddEntityCollideCallback("Player", "ScriptArea1", "func_slam", true, 1);
}

void func_slam(string &in asParent, string &in asChild, int alState)
{
SetSwingDoorClosed("door1", true, true);

PlaySoundAtEntity("", "react_breath_slow.snt", "Player", 0, false);

PlaySoundAtEntity("", "react_scare", "Player", 0, false);

PlaySoundAtEntity("", "close_door.snt", "Player", 0, false);

GiveSanityDamage(5.0f, true);
}
////////////////////////////
// Run when leaving map
void OnLeave()
{

}


PICTURE FROM EDITOR:

directlink: http://lookpic.com/O/i2/310/PZ9dWpfA.png
[Image: PZ9dWpfA.png]
directlink: http://lookpic.com/O/i2/1852/0Q3sSlHw.png
[Image: 0Q3sSlHw.png]

Now i belive all u need is just the scripting part, but i just threw it all in there..
(This post was last modified: 02-04-2012, 11:58 PM by MicroDude.)
02-04-2012, 10:16 PM
Find
Elven Offline
Posting Freak

Posts: 862
Threads: 37
Joined: Aug 2011
Reputation: 26
#2
RE: DOOR PROBLEM.. >:o

Sure it is ScriptArea1, not ScriptArea_1?

The Interrogation
Chapter 1

My tutorials
02-04-2012, 10:38 PM
Find
MicroDude Offline
Junior Member

Posts: 11
Threads: 1
Joined: Feb 2012
Reputation: 0
#3
RE: DOOR PROBLEM.. >:o

(02-04-2012, 10:38 PM)Elven Wrote: Sure it is ScriptArea1, not ScriptArea_1?
Yepp recently checked it. It is ScripArea1 Big Grin
02-04-2012, 10:42 PM
Find
Elven Offline
Posting Freak

Posts: 862
Threads: 37
Joined: Aug 2011
Reputation: 26
#4
RE: DOOR PROBLEM.. >:o

So, any of them doesn't work?

The Interrogation
Chapter 1

My tutorials
02-04-2012, 10:48 PM
Find
MicroDude Offline
Junior Member

Posts: 11
Threads: 1
Joined: Feb 2012
Reputation: 0
#5
RE: DOOR PROBLEM.. >:o

I have tried the same script on 2 doors, still not working. Hold on im going to provide u with a vid..
Here maybe this photo will work ..

[Image: fuckina.png]
(This post was last modified: 02-04-2012, 10:57 PM by MicroDude.)
02-04-2012, 10:51 PM
Find
Elven Offline
Posting Freak

Posts: 862
Threads: 37
Joined: Aug 2011
Reputation: 26
#6
RE: DOOR PROBLEM.. >:o

And where is door Big Grin?

Plus you didn't answer my previous question Tongue

The Interrogation
Chapter 1

My tutorials
02-04-2012, 10:58 PM
Find
MicroDude Offline
Junior Member

Posts: 11
Threads: 1
Joined: Feb 2012
Reputation: 0
#7
RE: DOOR PROBLEM.. >:o

By saying does "any of them work" I only have one door with the script currently ;o ..

And the door is right beneat the text saying "ACTIVE" ^-^
02-04-2012, 11:00 PM
Find
Elven Offline
Posting Freak

Posts: 862
Threads: 37
Joined: Aug 2011
Reputation: 26
#8
RE: DOOR PROBLEM.. >:o

Okay. But, do the sounds work?

The Interrogation
Chapter 1

My tutorials
02-04-2012, 11:02 PM
Find
MicroDude Offline
Junior Member

Posts: 11
Threads: 1
Joined: Feb 2012
Reputation: 0
#9
RE: DOOR PROBLEM.. >:o

Nope the sound doesn't work either :/

[Image: 13b84e27ae884ad0a24d817d23b75be0.png]
02-04-2012, 11:05 PM
Find
Elven Offline
Posting Freak

Posts: 862
Threads: 37
Joined: Aug 2011
Reputation: 26
#10
RE: DOOR PROBLEM.. >:o

Thanks for that info. That gave me lots of info Big Grin

And I might have solved it Big Grin

void OnStart()



{

AddEntityCollideCallback("Player", "ScriptArea1", "func_slam", true, 1);

}

Why the hell there is space in between on start and scripts?

The Interrogation
Chapter 1

My tutorials
02-04-2012, 11:10 PM
Find




Users browsing this thread: 1 Guest(s)