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
Player Collide Area question
Equil Offline
Member

Posts: 94
Threads: 8
Joined: Sep 2010
Reputation: 0
#1
Player Collide Area question

I was wondering which functions you need to use to tell the game to do a certain event while the player is inside an area and a different one if he leaves or none at all. Also how to make the event re-occur if the player enters this area again. I'm guessing that for the collide callback you need "bool abDeleteOnCollide" as false and "int alState" as 0(?)

I tried using the "GetEntitiesCollide" in an if else ladder to check if the player is in the room or not, but it wouldn't seem to work. I tried something like this:

void MyFunc(string &in asParent etc etc..)

{
        if(GetEntitiesCollide("Player", "AreaCollide_1") == false){
        Stuff I want to happen
        }
}
09-29-2010, 08:48 AM
Find
jens Offline
Frictional Games

Posts: 4,093
Threads: 199
Joined: Apr 2006
Reputation: 202
#2
RE: Player Collide Area question

Check script tutorial 1 and specifically the last video tutorial from mulledks http://hpl2.frictionalgames.com/tutorials which is very detailed in showing how to do it.
09-29-2010, 08:58 AM
Website Find
Frontcannon Offline
Senior Member

Posts: 538
Threads: 10
Joined: Jul 2010
Reputation: 2
#3
RE: Player Collide Area question

I'd make two areas in the same place, one that activates when entered and the other one when left.


╔═════════════════╗
☺ Smoke weed everyday ☺
╚═════════════════╝
09-29-2010, 03:31 PM
Find




Users browsing this thread: 1 Guest(s)