Frictional Games Forum (read-only)
Script Error... again - 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 Error... again (/thread-13235.html)



Script Error... again - Imevil23 - 02-11-2012

Hello. I am in need of some help again. So everything was going great and my scripting skills are getting better, but there's this one issue I have never seen before. So the way I test my map is to actually go INTO amnesia and play it. Now as I go through the level door, an error pops up saying that it couldn't load the script file because there were no matching signatures for "AddEntityCallbackFunc(string yadda yadda)" (It didn't actually say "yadda yadda") WHAT DOES THIS MEAN AND HOW CAN I RESOLVE IT?? Huh



RE: Script Error... again - flamez3 - 02-11-2012

It means you have not put the right callback. Post your script.


RE: Script Error... again - Imevil23 - 02-11-2012

(02-11-2012, 03:50 AM)flamez3 Wrote: It means you have not put the right callback. Post your script.
All right


////////////////////////////
// Run first time starting map
void OnStart()
{
AddEntityCallbackFunc("key_laboratory_1", "monsterspawn");
}

void monsterspawn(string &in asEntity, string &in type)
{
SetEntityActive("monster_1", true);
ShowEnemyPlayerPosition("monster_1");
}





I only posted what the error said was wrong.




RE: Script Error... again - flamez3 - 02-11-2012

Do you want it to happen when you go through a script area, or when you pick something up?



RE: Script Error... again - Imevil23 - 02-11-2012

Pick something up



RE: Script Error... again - flamez3 - 02-11-2012

SetEntityCallbackFunc("
key_laboratory_1 ", "
monsterspawn" );


void monsterspawn(string &in asEntity, string &in type)
{
SetEntityActive("monster_1", true);
ShowEnemyPlayerPosition("monster_1");
}



RE: Script Error... again - Imevil23 - 02-11-2012

Ohhh, SETentitycallback not Add. ok got it