If player has lantern - 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: If player has lantern (/thread-30344.html) |
If player has lantern - User01 - 08-02-2015 Player gets lantern on map A. In map B an entity is supposed to be active when player has the item. My first try (I like this better cause it seems simpler) Map B PHP Code: void OnStart() My second try Map A PHP Code: void OnStart() Map B PHP Code: void OnEnter() RE: If player has lantern - Mudbill - 08-02-2015 The first should work, although you really don't need that timer. PHP Code: void OnStart() Just make sure your entity actually can be scripted with. Not all types can. StaticProp does not support activating/deactivating. Also, since this is in OnStart, not OnEnter, make sure this is the first time the player enters this map, not returning. Is your entity actually inactive when you enter the map? Check for map_caches and internal names. RE: If player has lantern - User01 - 08-02-2015 Yep it works now. Thanks. |