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


Post Reply 
 
Thread Rating:
  • 4 Vote(s) - 4 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Anyone need help?
Author Message
Kyle Offline
Posting Freak

Posts: 911
Joined: Sep 2010
Reputation: 7
Post: #21
RE: Anyone need help?

How do I enable it then? Tongue

05-07-2011 07:43 PM
Find all posts by this user Quote this message in a reply
Exostalker Offline
Member

Posts: 204
Joined: Aug 2010
Reputation: 3
Post: #22
RE: Anyone need help?

(05-07-2011 07:43 PM)Kyle Wrote:  How do I enable it then? Tongue

Push on private messages
on the left side there is "edit options" in your profiel menu, push on it
Messaging and Notification


Receive private messages from other users.

enable it

05-07-2011 07:46 PM
Find all posts by this user Quote this message in a reply
Kyle Offline
Posting Freak

Posts: 911
Joined: Sep 2010
Reputation: 7
Post: #23
RE: Anyone need help?

Alright, it's on. Smile

05-07-2011 07:54 PM
Find all posts by this user Quote this message in a reply
Dominic0904 Offline
Member

Posts: 63
Joined: Apr 2011
Reputation: 0
Post: #24
RE: Anyone need help?

Quick question since you're offering. When you create some random event that lower's the player's sanity.
Say for mine I want the player to walk into a room and once he's at the centre he hears a loud roar and get's shaken up.
Now my question is, when his sanity is lowered ((because of the void StartRandomInsanityEvent(); ))
does the player give off scared reaction? Like does he naturally gasp or do I have to add the sound file into that script as well?

Tell me if it sounds confusing, think I may have confused myself Tongue
05-08-2011 07:53 PM
Find all posts by this user Quote this message in a reply
Simpanra Offline
Senior Member

Posts: 314
Joined: Mar 2011
Reputation: 0
Post: #25
RE: Anyone need help?

(05-08-2011 07:53 PM)Dominic0904 Wrote:  Quick question since you're offering. When you create some random event that lower's the player's sanity.
Say for mine I want the player to walk into a room and once he's at the centre he hears a loud roar and get's shaken up.
Now my question is, when his sanity is lowered ((because of the void StartRandomInsanityEvent(); ))
does the player give off scared reaction? Like does he naturally gasp or do I have to add the sound file into that script as well?

Tell me if it sounds confusing, think I may have confused myself Tongue

i know this isnt my thread to answer on, but i might as well =P

Ok, first of all i would use a different function called GiveSanityDamage =) look it up on the wiki to find where to put the inputs, this function allows you to choose (out of 100) how much sanity damage the player suffers,

Then in the same void function, place a PlaySoundAtEntiy function =)

Then set the sound that plays as "react_scare1" if i remember correctly =)

So this is what your script will look like;
{
AddEntityCollideCallback("Player", "MiddleOfRoom", "LoudRoarEvent")
}
void LoudRoarEvent( Parent, Child, State)
{
GiveSanityDamage( 10,)
PlaySoundAtEntity("react_scare1", "Player")
}



NOTE; this script wont work in game as i haven't put any variables in (apart from the sanity damage, i set as ten cos thats my favourite), you will need to find the functions i used on the wiki and place them where i have put mine and put in your chosen variables =)

Hope this helps =)

Edd,
05-08-2011 07:58 PM
Find all posts by this user Quote this message in a reply
Dominic0904 Offline
Member

Posts: 63
Joined: Apr 2011
Reputation: 0
Post: #26
RE: Anyone need help?

Thanks, I'll give it a try when I get down to scripting it all!
There should be a sticky-ed general help thread like this I think. For like minor scripting or building questions, so that the other threads can be created for any major problems people are having haha.
05-08-2011 08:55 PM
Find all posts by this user Quote this message in a reply
RawkBandMan Offline
Posting Freak

Posts: 1,146
Joined: Nov 2010
Reputation: 5
Post: #27
RE: Anyone need help?

How do I get a monster to spawn when I start to open a door/pick up a object? I know the script thing is void FunctionNameHere(string &in asEntity) But I don't know what the function is (I know the entity tho.)

I've come to learn to not fear the living, nor the dead... But the monsters that hide in closets.
05-08-2011 10:40 PM
Find all posts by this user Quote this message in a reply
Kyle Offline
Posting Freak

Posts: 911
Joined: Sep 2010
Reputation: 7
Post: #28
RE: Anyone need help?

Simpanra, I don't know why you are even trying to help him, you just screwed it all up, no offence. Tongue

void OnStart()
{
PreloadSound("react_scare");
AddEntityCollideCallback("Player", "ScriptArea_1", "LoadRoarEvent", true, 1);
}
void LoadRoarEvent(string &in asParent, string &in asChild, int alState)
{
GiveSanityDamage(10, true);
PlaySoundAtEntity("", "react_scare", "Player", 0, false);
}

The preloading of the sound will reduce the moment of lag between loading the sound and playing when it is used.
(05-08-2011 10:40 PM)XxRoCkBaNdMaNxX Wrote:  How do I get a monster to spawn when I start to open a door/pick up a object? I know the script thing is void FunctionNameHere(string &in asEntity) But I don't know what the function is (I know the entity tho.)

Here you go, this will be for when the player opens a door.

void OnStart()
{
SetEntityPlayerInteractCallback("door_1", "Function01, true);
}
Function01(string &in asEntity)
{
SetEntityActive("Monster", true);
}

This link will explain how to direct the monster with path nodes.

http://www.frictionalgames.com/forum/thread-7776.html?

(This post was last modified: 05-08-2011 10:52 PM by Kyle.)
05-08-2011 10:46 PM
Find all posts by this user Quote this message in a reply
RawkBandMan Offline
Posting Freak

Posts: 1,146
Joined: Nov 2010
Reputation: 5
Post: #29
RE: Anyone need help?

(05-08-2011 10:46 PM)Kyle Wrote:  Simpanra, I don't know why you are even trying to help him, you just screwed it all up, no offence. Tongue

void OnStart()
{
PreloadSound("react_scare");
AddEntityCollideCallback("Player", "ScriptArea_1", "LoadRoarEvent", true, 1);
}
void LoadRoarEvent(string &in asParent, string &in asChild, int alState)
{
GiveSanityDamage(10, true);
PlaySoundAtEntity("", "react_scare", "Player", 0, false);
}

The preloading of the sound will reduce the moment of lag between loading the sound and playing when it is used.
(05-08-2011 10:40 PM)XxRoCkBaNdMaNxX Wrote:  How do I get a monster to spawn when I start to open a door/pick up a object? I know the script thing is void FunctionNameHere(string &in asEntity) But I don't know what the function is (I know the entity tho.)

Here you go, this will be for when the player opens a door.

void OnStart()
{
SetEntityPlayerInteractCallback("door_1", "Function01, true);
}
Function01(string &in asEntity)
{
SetEntityActive("Monster", true);
}

This link will explain how to direct the monster with path nodes.

http://www.frictionalgames.com/forum/thread-7776.html?

So "Function01" activates/calls the monster? If so, thanks!

I've come to learn to not fear the living, nor the dead... But the monsters that hide in closets.
05-08-2011 10:57 PM
Find all posts by this user Quote this message in a reply
Kyle Offline
Posting Freak

Posts: 911
Joined: Sep 2010
Reputation: 7
Post: #30
RE: Anyone need help?

Inside of the function "Function01", it set the entity, the monster, "Monster" to true, thus spawning it.

So when the player activates the function, by the SetEntityPlayerInteractCallback, it calls the function, doing what ever is inside of it.

05-08-2011 10:59 PM
Find all posts by this user Quote this message in a reply
Post Reply 




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