Frictional Games Forum (read-only)
Death by light? - 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 (https://www.frictionalgames.com/forum/forum-35.html)
+--- Thread: Death by light? (/thread-6984.html)



Death by light? - LifeRemixed - 03-21-2011

I was wondering if it's possible to make it so that when i have my lantern active in an area it will fade enemies to smoke and get rid of them but if the lantern is inactive nothing will happen.


RE: Death by light? - Pandemoneus - 03-21-2011

It's similiar to that:
http://www.frictionalgames.com/forum/thread-5143.html?highlight=lantern


RE: Death by light? - LifeRemixed - 03-21-2011

(03-21-2011, 09:21 PM)Pandemoneus Wrote: It's similiar to that:
http://www.frictionalgames.com/forum/thread-5143.html?highlight=lantern

I'm really sorry but i'm pretty new to scripting and I couldn't figure out how to make that work..


RE: Death by light? - Hooumeri - 03-24-2011

I never could get my script to work. Activating the lantern is something you cant realy work into a script..

Atleast I cant.


RE: Death by light? - MrBigzy - 03-25-2011

You can use the callback: SetLanternLitCallback(string &asCallback);
Syntax: MyFunc(bool abLit)

So everytime the lantern is lit, it'll do whatever is in the callback function.

Turning enemies to smoke is: FadeEnemyToSmoke(string& asName, bool abPlaySound);

Actually, now that I think of it, you'll need to check if enemies are a certain distance away from you. Not sure how to do that...