Frictional Games Forum (read-only)
1 Trigger Won't work! - Printable Version

+- Frictional Games Forum (read-only) (https://www.frictionalgames.com/forum)
+-- Forum: Amnesia: The Dark Descent (https://www.frictionalgames.com/forum/forum-6.html)
+--- Forum: Custom Stories, TCs & Mods - Development (https://www.frictionalgames.com/forum/forum-38.html)
+---- Forum: Development Support (https://www.frictionalgames.com/forum/forum-39.html)
+---- Thread: 1 Trigger Won't work! (/thread-9657.html)



1 Trigger Won't work! - GreyFox - 08-08-2011

Hey guys I have a bunch of triggers and stuff But this 1 Won't work and I have no idea why.

I'll give you the few lines for it and maybe i'm just blind and don't see something so obvious

void OnStart()
{
AddEntityCollideCallback("Player", "Blowpaper", "CollideBlowPaper", true, 1);
}


void CollideBlowPaper(string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("WindGust", "general_wind_whirl.snt", "paper_pile_1", 0, false);
CreateParticleSystemAtEntity("PaperBlow", "ps_dust_paper_blow.ps", "paper_pile_1", true);
AddPropImpulse("mansion_6", -3, 0, 0, "world");
}

The Trigger in the level editor is called "Blowpaper"

Thanks guys. I'm going to keep trying and looking.
-Grey Fox




RE: 1 Trigger Won't work! - Dizturbed - 08-08-2011

wrong onstart()

use: void OnStart() instead Wink


RE: 1 Trigger Won't work! - GreyFox - 08-08-2011

its like that. I just didn't put it correctly sorry. Like i said I have many other triggers all working execpt this one. and some are very similar (IE, create particle, play noise, etc)

I will edit that though so nobody mentions that again.

Though thank you for the very quick reply