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
Need some help with my FAST MONSTER script
NaxEla Offline
Senior Member

Posts: 415
Threads: 5
Joined: Dec 2012
Reputation: 28
#11
RE: Need some help with my FAST MONSTER script

(12-22-2012, 10:16 PM)dnalange Wrote:
(12-22-2012, 09:24 PM)beecake Wrote: Please explain a bit more.

What do you mean by touched? There is only one way to interact with entities.
Do you mean that an entity collides with the door?


I would like to do this -->

Player toutches a door { like you want to open a door , hehe }

But it's locked -> all 4 doors are locked!

when toutched the 4th {randomly, ""the doors are in a circle"" door, one of the doors open let's say door 4 opens..Or unlocks OR anything..

Do you understand now?

So there's 4 doors and the player is in the middle of them. All doors are locked. Once the player has touched each door at least once, a random door chosen from the 4 doors will unlock.

Have I got that right?

In Ruins [WIP]
(This post was last modified: 12-22-2012, 10:45 PM by NaxEla.)
12-22-2012, 10:44 PM
Find
FlawlessHappiness Offline
Posting Freak

Posts: 3,980
Threads: 145
Joined: Mar 2012
Reputation: 171
#12
RE: Need some help with my FAST MONSTER script

Yes.

In the interact-tab in the doors properties you write: Interact4Doors

script:

void Interact4Doors(string &in asEntity)
{
if(GetLocalVarInt("4Doors") == 4)
{
SetSwingDoorLocked("Door_"+RandInt(1,4), false, true);
}

else
{
if(GetLocalVarInt(asEntity) == 1)
{
return;
}
AddLocalVarInt("4Doors", 1);
AddLocalVarInt(asEntity, 1);
}
}

This means the 4 doors should be named: Door_1, Door_2, Door_3, Door_4

Trying is the first step to success.
12-22-2012, 10:55 PM
Find
DnALANGE Offline
Banned

Posts: 1,549
Threads: 73
Joined: Jan 2012
#13
RE: Need some help with my FAST MONSTER script

(12-22-2012, 10:55 PM)beecake Wrote: Yes.

In the interact-tab in the doors properties you write: Interact4Doors

script:

void Interact4Doors(string &in asEntity)
{
if(GetLocalVarInt("4Doors") == 4)
{
SetSwingDoorLocked("Door_"+RandInt(1,4), false, true);
}

else
{
if(GetLocalVarInt(asEntity) == 1)
{
return;
}
AddLocalVarInt("4Doors", 1);
AddLocalVarInt(asEntity, 1);
}
}

This means the 4 doors should be named: Door_1, Door_2, Door_3, Door_4

I am gonna check it out!
Thank you for the fast response!
Keep you up if works ..
IT WILL hehheh! Just to let you nkow!
THANKS!!
12-23-2012, 01:00 AM
Find
DnALANGE Offline
Banned

Posts: 1,549
Threads: 73
Joined: Jan 2012
#14
RE: Need some help with my FAST MONSTER script

(12-22-2012, 10:44 PM)NaxEla Wrote:
(12-22-2012, 10:16 PM)dnalange Wrote:
(12-22-2012, 09:24 PM)beecake Wrote: Please explain a bit more.

What do you mean by touched? There is only one way to interact with entities.
Do you mean that an entity collides with the door?


I would like to do this -->

Player toutches a door { like you want to open a door , hehe }

But it's locked -> all 4 doors are locked!

when toutched the 4th {randomly, ""the doors are in a circle"" door, one of the doors open let's say door 4 opens..Or unlocks OR anything..

Do you understand now?

So there's 4 doors and the player is in the middle of them. All doors are locked. Once the player has touched each door at least once, a random door chosen from the 4 doors will unlock.

Have I got that right?


IT'S WORKING!!!

Ohhh it was me again...
one of the doors was Door_43 ... hehheee
THANKS!!!
Probly come soon with some more questions..

how could i make it like door_3 will only get oens... and NOT randonly???
Would be a bit more easy to build the scripts in one hallway..

Also fixed!!
I'm getting here!!

Are you interested in what the FC would look like?
are there ANY people still interested?

Would like to show a very experienced person how it looks like

You would like to see it trough skype.. for around 5 min of your time!
(This post was last modified: 12-24-2012, 12:40 AM by DnALANGE.)
12-24-2012, 12:26 AM
Find




Users browsing this thread: 3 Guest(s)