Garry's Mod

Garry's Mod

gm_boreas
Smoothie 25 Oct, 2022 @ 6:44am
NPCs can't open bunker doors
For some reason, NPC's such as combine can't open the bunker doors (the white ones with windows and keypads). Is there a workaround?
< >
Showing 1-4 of 4 comments
Blueberry_pie  [developer] 25 Oct, 2022 @ 10:50am 
As far as I can tell, sliding doors in HL2/GMod can not be used by NPCs unless they are specifically scripted to do so. I did some quick experimenting but I don't think there's much I can do to solve this without introducing other issues.

However, if you're playing in singleplayer mode or if you're admin on a server, you can run some console commands to open all of these doors at once. To do so, open the console with Shift+Esc and enter the following two lines (enter them separately, because the command is too long otherwise):
ent_fire archiveDoor* open; ent_fire controlRoomDoor* open; ent_fire corridorDoor* open; ent_fire generatorsDoor* open; ent_fire greeneryDoor* open; ent_fire kitchenDoor* open; ent_fire livingQuartersDoor* open
ent_fire quarantineDoor* open; ent_fire recRoomDoor* open; ent_fire scienceLabDoor* open; ent_fire serversDoor* open; ent_fire sickBayDoor* open; ent_fire siloDoor* open; ent_fire storageDoor* open

This should have the same effect as if you'd opened each door of this type manually. Each door will remain open until you use its keypad again.

Alternatively, to remove these doors completely, enter these commands:
ent_fire archiveDoor* kill; ent_fire controlRoomDoor* kill; ent_fire corridorDoor* kill; ent_fire generatorsDoor* kill; ent_fire greeneryDoor* kill; ent_fire kitchenDoor* kill; ent_fire livingQuartersDoor* kill
ent_fire quarantineDoor* kill; ent_fire recRoomDoor* kill; ent_fire scienceLabDoor* kill; ent_fire serversDoor* kill; ent_fire sickBayDoor* kill; ent_fire siloDoor* kill; ent_fire storageDoor* kill

I should note that both workarounds will also affect a couple of non-sliding doors that happen to have a similar name, but that shouldn't cause any issues. I've only tested this briefly, though, so I can't make any guarantees.
Last edited by Blueberry_pie; 25 Oct, 2022 @ 10:55am
Smoothie 25 Oct, 2022 @ 12:07pm 
That's been the solution so far, (ent_fire *door* open, interferes with other stuff but is fast), however I've noticed that nextbots tend to have no trouble with said doors (presumably due to a more up to date codebase), and as impossible as it sounds, do you think there is a way to implement interact nodes into the nodegraph to cause NPCS to trigger the keypads?
Blueberry_pie  [developer] 25 Oct, 2022 @ 1:11pm 
Originally posted by Red:
do you think there is a way to implement interact nodes into the nodegraph to cause NPCS to trigger the keypads?
A nodegraph really only provides information on navigating the world, strategic opportunities and visual points of interest. The actual behaviour resulting from that information depends entirely on the NPC's programming.

It probably wouldn't be too hard to create custom NPCs or extend existing NPCs so that they interact with nearby buttons when they encounter a closed door, but something like that would be better off being its own addon (if it doesn't exist already). It's not something that I'm interested in building and maintaining.
Smoothie 25 Oct, 2022 @ 2:20pm 
Was thinking hints, but idk if that would work anyway. Thanks for the help tho, this map is hella underrated and you should be proud of it
Last edited by Smoothie; 25 Oct, 2022 @ 3:46pm
< >
Showing 1-4 of 4 comments
Per page: 1530 50