Facebook Twitter YouTube Frictional Games | Forum | Newsletter | Dev Blog | Dev Wiki | Support | Shelf | Store

Privacy Policy


Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Player falls
Author Message
Janni1234 Offline
Member

Posts: 135
Joined: Jan 2011
Reputation: 1
Post: #11
RE: Player falls
(06-14-2011 12:46 PM)Russ Money Wrote:  For the "lying on the floor" effect, use this function:

FadePlayerRollTo(50, 150, 150);

Then to return the camera back to horizontal

FadePlayerRollTo(0, 33, 33);

Insert those where they need to be in Janni1234's script.


Okay.Thanks.
06-14-2011 01:26 PM
Find all posts by this user Quote this message in a reply
Russ Money Offline
Senior Member

Posts: 360
Joined: Dec 2010
Reputation: 3
Post: #12
RE: Player falls
(06-14-2011 01:26 PM)Janni1234 Wrote:  Okay.Thanks.

No prob bob.

06-14-2011 01:47 PM
Find all posts by this user Quote this message in a reply
miguli Offline
Junior Member

Posts: 43
Joined: Jun 2011
Reputation: 0
Post: #13
RE: Player falls
Not working, and i dont know where put those:
FadePlayerRollTo(50, 150, 150);
FadePlayerRollTo(0, 33, 33);

Error comes and says:

FATAL ERROR: Could not load script file 'custosm_stories/plah/plah/plah/plaah/castleway.hps'! main(53,1) : ERR : No matching signatures to 'SetPlayerStateToNormal()'

Script:

Quote:void OnStart()
{
AddUseItemCallback("", "key_1", "door_locked_1", "UsedKeyOnDoor", true);
SetEntityPlayerInteractCallback("key_1", "Func03", true);
AddEntityCollideCallback("Player", "yourarea", "yourarea", true, 1);
}

void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("door_locked_1", false, true);
PlaySoundAtEntity("", "unlock_door", "door_locked_1", 0, false);
RemoveItem("key_1");
}

void Func03(string &in asEntity)
{
SetEntityActive("grunt_2", true);
AddEnemyPatrolNode("grunt_2", "PathNodeArea_1", 0.0f, "");
AddEnemyPatrolNode("grunt_2", "PathNodeArea_2", 0.0f, "");
AddEnemyPatrolNode("grunt_2", "PathNodeArea_3", 0.0f, "");
AddEnemyPatrolNode("grunt_2", "PathNodeArea_4", 0.0f, "");
AddEnemyPatrolNode("grunt_2", "PathNodeArea_5", 0.0f, "");
AddEnemyPatrolNode("grunt_2", "PathNodeArea_6", 0.0f, "");
AddEnemyPatrolNode("grunt_2", "PathNodeArea_7", 0.0f, "");
AddEnemyPatrolNode("grunt_2", "PathNodeArea_8", 0.0f, "");
AddEnemyPatrolNode("grunt_2", "PathNodeArea_9", 0.0f, "");

}

void yourarea(string &in asParent , string &in asChild , int alState)
{
SetPlayerCrouching(true);
FadeOut(2);
PlaySoundAtEntity("", "react_breath.snt", "Player", 0, false);
AddTimer("Timer", 2.0f, "wakeup");
SetPlayerJumpDisabled(true);
SetInventoryDisabled(true);
}

void wakeup(string &in asTimer)
{
StartPlayerLookAt("ScriptArea_1", 2.0, 3.0f, "");
FadeRadialBlurTo(0.07, 0.015f);
FadeIn(2);
AddTimer("Timer", 1.0f, "begin");
}

void begin(string &in asTimer)
{
SetPlayerCrouching(false);
SetPlayerJumpDisabled(false);
SetInventoryDisabled(false);
SetPlayerStateToNormal();
FadeRadialBlurTo(0, 1);
}

// Run when leaving map
void OnLeave()
{

}

Amnesia map:
Hope - Work in Progress.
06-14-2011 05:29 PM
Find all posts by this user Quote this message in a reply
xtron Offline
Senior Member

Posts: 402
Joined: May 2011
Reputation: 2
Post: #14
RE: Player falls
well...I guess you could try to change the SetPlayerStateToNormal(); to SetPlayerStateToNormal(false); or just delete it.

[Image: 44917299.jpg]Dubstep <3
06-14-2011 06:37 PM
Find all posts by this user Quote this message in a reply
Roenlond Offline
Senior Member

Posts: 331
Joined: Apr 2011
Reputation: 0
Post: #15
RE: Player falls
SetPlayerStateToNormal(); isn't a function, at least not in the wiki page. So it's probably calling a custom function and since there's nothing with that name to call, it errors out. Remove the line and you shouldn't have the error, I believe Smile
06-14-2011 06:45 PM
Find all posts by this user Quote this message in a reply
miguli Offline
Junior Member

Posts: 43
Joined: Jun 2011
Reputation: 0
Post: #16
RE: Player falls
Not working.. :/
Works, but i dont know where i put that falling.
(XD i forgot save map before testing, sorry guys!!)

Amnesia map:
Hope - Work in Progress.
(This post was last modified: 06-14-2011 08:22 PM by miguli.)
06-14-2011 08:03 PM
Find all posts by this user Quote this message in a reply
nemesis567 Offline
Posting Freak

Posts: 840
Joined: May 2011
Reputation: 10
Post: #17
RE: Player falls
nevermind it...

Today I dreamt the life I could live forever. You only know that when you feel it for you know not what you like until you've experienced it.
(This post was last modified: 06-14-2011 11:02 PM by nemesis567.)
06-14-2011 11:01 PM
Find all posts by this user Quote this message in a reply
miguli Offline
Junior Member

Posts: 43
Joined: Jun 2011
Reputation: 0
Post: #18
RE: Player falls
Now everything is perfect falling and everything Smile

Amnesia map:
Hope - Work in Progress.
06-15-2011 01:59 AM
Find all posts by this user Quote this message in a reply
Hardarm Offline
Senior Member

Posts: 701
Joined: Apr 2011
Reputation: 34
Post: #19
RE: Player falls
If you want the player really falling i don't know because the plane isn't an entity, though. Am i wrong? i can't even disable it when i click to it on the editor.

06-15-2011 01:23 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)