The chaser
Posting Freak
Posts: 2,486
Threads: 76
Joined: Jun 2012
Reputation:
113
|
RE: How to achieve this scenario?
(02-01-2013, 04:09 AM)serbusfish Wrote: Thanks for being patient with me, but something is still wrong because I pasted that exact code and the game throws up an error message saying 'ERR - expected '('.
It must have something to do with the line
"void BreakPotPlant(string &in asParent, string &in asChild, int alState)"
because the map loads when this is deleted. Am I supposed to replace the text in this line?
If it helps here is the entire content of my .hps file so far:
//===========================================
// This runs when the map first starts
void OnStart()
{
if(ScriptDebugOn())
{
GiveItemFromFile("tinderbox", "tinderbox.ent);
AddEntityCollideCallback("Player", "ScriptArea_2", "BreakPotPlant", true, 1);
}
}
void BreakPotPlant(string &in asParent, string &in asChild, int alState)
{
SetPropHealth("pot_plant_small02_1", 0);
}
//===========================================
// This runs when the player enters the map
void OnEnter()
{
//----AUDIO----//
PlayMusic("10_amb", true, 5, 1, 0, true);
}
//===========================================
// This runs when the player leaves the map
void OnLeave()
{
}
There, fixed it.
THE OTHERWORLD (WIP)
Aculy iz dolan.
|
|
02-01-2013, 10:28 AM |
|