Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

I need the NPC to unlock the door when they've done their thing.

So what I was hoping for was something like:

door1: is_locked = "true"

If (npc_has_done_their_thing){

:unlock (door1)

But I can't see that such an :unlock command exists. If it doesn't, then  I can work around it using a condition on a block path barrier.

you can do that with normal barriers, since barriers have option to be locked when a bool returns true ( for you, !npc_has_done_their_thing because your bool returns true when you want the door to be unlocked, so you need to reverse that)

Than you just need to set that bool to true when the NPC is done, or to check if the NPC is present in the room and then set it to false, and to true when they are not present.