The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 906 - File: showthread.php PHP 7.2.24-0ubuntu0.18.04.17 (Linux)
File Line Function
/showthread.php 906 errorHandler->error



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
Nothing happens when player collides with area.
Datguy5 Offline
Senior Member

Posts: 629
Threads: 25
Joined: Dec 2011
Reputation: 12
#1
Nothing happens when player collides with area.

So basically the problem is.When the player collides with an area called Bang nothing happens.Here is my hps file.
////////////////////////////
// Run when entering map
void OnStart()
{
PlayMusic("hall.ogg", true, 1.0f, 1.0f, 1, false);
SetEntityPlayerLookAtCallback("Areas", "Sign_1", false);
AddEntityCollideCallback("Player", "Bang", "Scare1", true, 1);
}
void Sign_1(string &in asEntity, int alState)
{
SetMessage("Signs", "Sign3", 2);
}
void Scare1(string &in asTimer)
{
PlaySoundAtEntity("", "scare_male_terrified5.ogg", "Player", 0, false);
CreateParticleSystemAtEntity("", "Phaa", "Particle", false);
AddTimer("", 0.2, "Thimer");
}
void Thimer(string &in asTimer)
{
GiveSanityDamage(10.0f, true);
PlaySoundAtEntity("", "react_sigh.snt", "Player", 0, false);
}
////////////////////////////
// Run when entering map
void OnEnter()
{
}
////////////////////////////
// Run when leaving map
void OnLeave()
{
}
Help?

(This post was last modified: 04-06-2012, 05:24 PM by Datguy5.)
04-06-2012, 04:00 PM
Find


Messages In This Thread
Nothing happens when player collides with area. - by Datguy5 - 04-06-2012, 04:00 PM



Users browsing this thread: 1 Guest(s)