Frictional Games Forum (read-only)
[SCRIPT] FIXED!!!Why wont my script work in my CS? - 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: [SCRIPT] FIXED!!!Why wont my script work in my CS? (/thread-19694.html)



FIXED!!!Why wont my script work in my CS? - CptLogicDev - 12-27-2012

Hey every Programmer there! Smile
Just want a question trying to solve this problem for a while now but it dosn't work for me :S

my HPS wont work in my map Sad
Any tips of it ??

Code:
void OnStart()
{
AddEntityCollideCallback("", "scriptarea1", "LookAt", true, 1);
}

void LookAt(string &in asParent, string &in asChild, int alState)
{
StartPlayerLookAt("LookAt", 1, 2, "");
AddTimer("", 3, "Timertrigger1");
}

void Timertrigger1(string &in asTimer)
{
SetMessage("Message", "WhatHappend", 5);
StopPlayerLookAt();
}



RE: Why wont my script work in my CS? - Statyk - 12-27-2012

You have no Parent declared in the AddEntityCollideCallback... Do this:

AddEntityCollideCallback("Player", "scriptarea1", "LookAt", true, 1);


RE: Why wont my script work in my CS? - The chaser - 12-27-2012

Oh, and:

It would bue useful that you told us what fails: If it doesn't work in the map, if it crashes, etc.


RE: Why wont my script work in my CS? - CptLogicDev - 12-27-2012

(12-27-2012, 07:04 AM)Statyk Wrote: You have no Parent declared in the AddEntityCollideCallback... Do this:

AddEntityCollideCallback("Player", "scriptarea1", "LookAt", true, 1);

ty man was a while ago i scripted!! Big Grin
was like 6 months have forgotten the most script Tongue
ty man!!!