Welcome to the Builder Academy

Question Should objects of type furniture also act as containers?

More
Yesterday 15:04 #11041 by Banlock
I want to place items on tables or similar objects that would normally be classified as furniture - if anything at all. So a mug could be on a bar, a plate of food on a table, a lamp on a nightstand, etc. What would make more sense:

1) Making anything classed as furniture also function as a container that isn't closable. This would probably be the easy way out, but having a character "look in table" seems clunky.

2) Make a new object type of, maybe, "surface". It would act like a container, but would not be closable or takeable and "look mantel" would return the mantel's description, plus something like "this mantel seems to have items on it". And then "look on mantel" would return a list of the items on the mantel. Obviously, bookshelves would still be typed as containers.

What do you folks think?

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

More
Yesterday 16:41 #11042 by Fizban
I wouldn't do the container hack personally. Furniture/surface though seems sensible.

Exact optimal implementation is subjective ofc, I don't think there's a "best" route necessarily.

Like, you could have:

look table, always shows the same thing and isn't dynamic
and look on table, shows the things on it

I think exactly how you want it to work though is a nuanced scenario without 1 obvious best implementation.
The following user(s) said Thank You: Banlock

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

More
Today 12:34 #11043 by thomas
Personally, I think adding a SURFACE type where the contents are listed to the room seems like the most interesting.

Main chamber
The room is lit by a bright light coming from the altar along one wall, so you are easily able to make out every fold of the flesh-like walls, the dripping viscera and the blood pools along the walls.
A bloody alter is here, stained by apparent decades of sacrifices ...It glows with a bright light
On the bloody altar you see a constrained, heartless body, a still-beating heart and a blood-dripping desert kris.

> examine altar
The altar seems to be made from a white stone, with grooves leading down to the blood pools on the floor.
It looks extremely heavy.
It glows with a bright light.
On it, you see:
- The constrained body of a willing peon, with its heart removed
- A still-beating heart, now just pumping air
- A desert kris, bloodied and left behind.

> get kris
You get the blood-dripping desert kris from the altar.

> get heart from altar
You get the still-beating heart from the altar.


In this example, the altar is a surface, with three items. The items are easily visible, and you can interact directly with them.
To make this work, there's quite a lot of code that needs to be adjusted, but it's a possible way to go.

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

Time to create page: 0.303 seconds