Welcome to the Builder Academy

Question Hidden doors

More
30 Jan 2018 18:22 #7469 by Sascha
Hidden doors was created by Sascha
When a player finds a hidden door, and opens it, should that exit now be visible until the door is closed again? I checked the doors on both sides, they have matching doors, door flags and zone commands.


l
In a Thicket
Nestled behind a protected screening of grass is a thicket of thorn covered
berry bushes. They grow so densely together that it seems almost accidental,
until noticing that their trunks are spaced precisely apart.
[ Exits: n e ] <-- the only exits visible

124H 259M 98V >
open thorns
Okay. <-- ahah! Hidden door!

124H 259M 98V >
l
In a Thicket
Nestled behind a protected screening of grass is a thicket of thorn covered
berry bushes. They grow so densely together that it seems almost accidental,
until noticing that their trunks are spaced precisely apart.
[ Exits: n e ] <-- Wait. Didn't we just open a hidden door to the west?

124H 259M 98V >
w <-- Heck, let's go west anyway.
A Campsite in the Grasses <-- Yep, there's a room here!
A slight depression in the earth offers protection from both sight and the wind
that blows across the grasslands. A section of earth has been cleared around a
ring of blackened stone that holds charred remnants of wood and animal dung.
Thorn-covered bushes ring the site in a natural protective barricade.
[ Exits: None!] <-- Hmm. I know there's an exit here to the east, as I just entered from the west...
A handful of gold coins have been scattered here.
Some crates are piled together haphazardly.
Lazy wafts of smoke drift upward from a fire ring.
Some gold coins are piled together.
A scrawny bandit eyes you greedily.
A scrawny bandit eyes you greedily.
Dietr Aylarn, self-styled bandit chief, stands here.



Dietr Aylarn says, 'Light bless us, look who just walked in.'

125H 259M 96V >

Dietr Aylarn says, 'Your money, if you please.'
You tickle Dietr Aylarn as you hit him.

Will you stand against the coming Storm? After the Breaking: STORMRIDERS MUD - atbmud.dune.net port 4000

Please Log in or Create an account to join the conversation.

More
30 Jan 2018 20:45 #7470 by JTP
Replied by JTP on topic Hidden doors
Hidden is always hidden, even After opening it

Please Log in or Create an account to join the conversation.

More
30 Jan 2018 22:51 #7472 by Sascha
Replied by Sascha on topic Hidden doors
That's just so... illogical. I've been toying with a script to make it a "real" exit by changing the conditions when opened from hidden to a regular door, I suppose that may have to do.

Will you stand against the coming Storm? After the Breaking: STORMRIDERS MUD - atbmud.dune.net port 4000

Please Log in or Create an account to join the conversation.

More
30 Jan 2018 23:05 - 30 Jan 2018 23:06 #7473 by Parnassus
Replied by Parnassus on topic Hidden doors
Well, I'm sure everyone is expecting this answer from me :)

Have you considered using a trigger? Here's an example .

Also, there's a set of hidden door triggers in zone 555, Ultima, in the library. These include finding, opening and closing the door. There's also one to close the door automatically at zone reset, made to fake a 'real' door closing at zone reset except with a message (tstat 55533).

Edit: Oops, I guess I was thinking too long :)
Last edit: 30 Jan 2018 23:06 by Parnassus. Reason: Sasha mentioned script :)

Please Log in or Create an account to join the conversation.

More
30 Jan 2018 23:21 #7475 by Sascha
Replied by Sascha on topic Hidden doors
LOL! Thanks, Parnassus. Fizban has been teaching me the mantra that "The answer is almost always script!". ;) I figured I'd ask, though, just in case there was some sneaky bug running around...

Will you stand against the coming Storm? After the Breaking: STORMRIDERS MUD - atbmud.dune.net port 4000

Please Log in or Create an account to join the conversation.

More
31 Jan 2018 03:19 #7485 by WhiskyTest
Replied by WhiskyTest on topic Hidden doors
And because coding is fun, here is my solution :D

inside act.information.c
Code:
static void do_auto_exits(struct char_data *ch) { . . . - if (EXIT_FLAGGED(EXIT(ch, door), EX_HIDDEN) && !PRF_FLAGGED(ch, PRF_HOLYLIGHT)) + if ( (EXIT_FLAGGED(EXIT(ch, door), EX_HIDDEN) && EXIT_FLAGGED(EXIT(ch, door), EX_CLOSED)) && !PRF_FLAGGED(ch, PRF_HOLYLIGHT))
Code:
ACMD(do_exits) { . . . - if (EXIT_FLAGGED(EXIT(ch, door), EX_HIDDEN) && !PRF_FLAGGED(ch, PRF_HOLYLIGHT)) + if ( (EXIT_FLAGGED(EXIT(ch, door), EX_HIDDEN) && EXIT_FLAGGED(EXIT(ch, door), EX_CLOSED)) && !PRF_FLAGGED(ch, PRF_HOLYLIGHT))

So the logic becomes, "if the door is hidden AND closed, and the character doesn't have holy light" then don't show it.
The following user(s) said Thank You: Sascha

Please Log in or Create an account to join the conversation.

Time to create page: 0.184 seconds