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
Questions
Romulator Offline
Not Tech Support ;-)

Posts: 3,628
Threads: 63
Joined: Jan 2013
Reputation: 195
#21
RE: UNEXPECTED ERROR

Well, I can't fix it now, because I have to sleep, but if you can't solve the problem, consider uploading your map and script file somewhere and link us to it - one of us will surely (if not, then I will myself in the morning) have a look at it and correct it.

Discord: Romulator#0001
[Image: 3f6f01a904.png]
06-06-2014, 05:44 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#22
RE: UNEXPECTED ERROR

What do you mean ? -_-

oww ;S okey Sleepwell Big Grin and thanks for you try!
i'm uploading today... and if no one helps.. i will give the link to you tomorrow Big Grin

And for tomorrow.. my link of the files ( maps AND hps... )
https://www.mediafire.com/?22ktc3cf2256f5z
(This post was last modified: 06-06-2014, 05:51 PM by Amnesiaplayer.)
06-06-2014, 05:44 PM
Find
Mudbill Offline
Muderator

Posts: 3,881
Threads: 59
Joined: Apr 2013
Reputation: 179
#23
RE: UNEXPECTED ERROR

This is your script at the moment:
PHP Code: (Select All)
void OnStart()
{
    
AddEntityCollideCallback("Player""Teleport""jumpscare"true1);
}

void jumpscare1(string &in asParentstring &in asChildint alState)
{
    
SetEntityActive("jumpscare1"true);
    
AddPropForce("jumpscare1", -1000000"world");
    
PlaySoundAtEntity("""24_iron_maiden.snt""jumpscare1"0false);


You need to change the line
PHP Code: (Select All)
void jumpscare1(string &in asParentstring &in asChildint alState

to not use the number '1' after jumpscare, like this:
PHP Code: (Select All)
void jumpscare(string &in asParentstring &in asChildint alState

Edit:
I also checked out your level. The reason the collision isn't detected is because your area is 0 in width. You need to have something more. Try increasing it to 0.25 instead. I tested it and it worked.

(This post was last modified: 06-06-2014, 06:12 PM by Mudbill.)
06-06-2014, 06:07 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#24
RE: UNEXPECTED ERROR

Doesn't work Sad i do every steps.. but why! please check my new post and download my map to test it out... Sad
06-06-2014, 06:13 PM
Find
Mudbill Offline
Muderator

Posts: 3,881
Threads: 59
Joined: Apr 2013
Reputation: 179
#25
RE: UNEXPECTED ERROR

Did you read my edit?

06-06-2014, 06:14 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#26
RE: UNEXPECTED ERROR

Omg thankyou !! thank you really much!! omgg I scared the **** OUT OF MEE
i thougt i did it wrong... omg I ..... Scared too muich :S but really thankss!!!!
alone the way where he goes is wrong.. i'm Trying to fix that with one older post... Thanks!!!
06-06-2014, 06:18 PM
Find
Mudbill Offline
Muderator

Posts: 3,881
Threads: 59
Joined: Apr 2013
Reputation: 179
#27
RE: UNEXPECTED ERROR

If you want to reverse the direction, remove the minus from the AddPropForce.

PHP Code: (Select All)
AddPropForce("jumpscare1"1000000"world"); 

(This post was last modified: 06-06-2014, 06:20 PM by Mudbill.)
06-06-2014, 06:20 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#28
RE: UNEXPECTED ERROR

it worked to!!!
thanks mann!!!
Finally !!!
really thanks!!
06-06-2014, 06:24 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#29
Unlocking door Error...

Can someone help me please ?!
i made a key and a door... but i don't now what to type in the EXTRA LANGE ENGLI SH thing or something like that... MY key name is : badkey
and my door name is : door1
Sad and i got error in my hps ... unexpected again! i copy and pastE ALONE the things that gives the error... so the other 30+ lines i don't copy!
this is the thing

first of all.
(there are more things and yes i have { and }... )
AddUseItemCallback("", "badkey", "door1", "UsedKeyOnDoor", true);

but they said the error is here...
void UsedKeyOnDoor (string &in asItem, string &in asEntry)
(
SetSwingDoorLocked("door1", false, true);
PlaySoundAtEntry("", "unlock_door.snt", "door1", 0, false);
RemoveItem("badkey");

can someone please help me :S
06-07-2014, 11:33 AM
Find
Romulator Offline
Not Tech Support ;-)

Posts: 3,628
Threads: 63
Joined: Jan 2013
Reputation: 195
#30
RE: Unlocking door Error...

...Assuming that this is the only error in your code:
Quote:void UsedKeyOnDoor(string &in asItem, string &in asEntry)
(
SetSwingDoorLocked("door1", false, true);
PlaySoundAtEntry("", "unlock_door.snt", "door1", 0, false);
RemoveItem("badkey");
You have to use braces ( {} ) and not brackets ( () ) to open and close a void.
Also, there is no script for asEntry or PlaySoundAtEntry. It is asEntity and PlaySoundAtEntity respectively.

PHP Code: (Select All)
void UsedKeyOnDoor (string &in asItemstring &in asEntity)
{
SetSwingDoorLocked("door1"falsetrue);
PlaySoundAtEntity("""unlock_door.snt""door1"0false);
RemoveItem("badkey");


You can find all the scripts on the wiki at this page: https://wiki.frictionalgames.com/doku.ph..._functions
And you can find a tutorial all about unlocking doors here: https://wiki.frictionalgames.com/hpl2/tu...cks_a_door

Discord: Romulator#0001
[Image: 3f6f01a904.png]
(This post was last modified: 06-07-2014, 11:48 AM by Romulator.)
06-07-2014, 11:46 AM
Find




Users browsing this thread: 1 Guest(s)