Loader
logo

Rooms and Hull Breaches

Started by Produno, August 11, 2021, 12:25:25 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Feedback on the following would be appreciated. We currently have rooms and these rooms can be assigned to pawns in a similar way to how beds are assigned to pawns in Rimworld, plus various other perks and features. It is also how atmosphere, heat etc all calculate and work.


I had been re-working the building as per the poll results which means we build hull, then we can build flooring over hull, similar to the way this works in Starship Theory.

The question is, how do we want to handle the way rooms works in regards to breaches. We currently have two choices that i can think of. Fyi, when i mention hull breach i mean either a hull or flooring tile has been removed or destroyed, leaving part of the ship open to space.


1. We remove the room and the atmosphere on a hull breach. This is easy to maintain because as soon as we have a hull breach, everything is removed so there is nothing to keep track of. Once the breach is sealed, the game re-creates the room and everything it needs. I suspect this will be annoying to the player though if they have a breach and it continually removes the room including the name and any pawns assigned. Though maybe it will not be much of a problem?

2. The second way is much more complex but may work better. We keep the room and alert the player there has been a breach. Atmosphere will slowly leak until the breach has been sealed. We need to consider at which point rooms will be destroyed though, so we need to keep track of this, ie, if more than 50% of a room is open to space we completely remove the room. Or do we remove any tiles open to space from the room, which could lead to other potential issues.


Any other ideas are welcomed, but from a technical perspective this is a pretty difficult problem to tackle.

Is there any way to perhaps automatically replace the destroyed sections with say, a blueprint? which could then be used to keep track? This could mean that although the room doesn't always get "destroyed", the room itself might not meet the minimum criteria to be active and accessible without a space suit.

I like the idea of number 2, is there any way to increase the rate at which the atmosphere leaks at depending on the size of the breach? I dont know if rooms can be assigned a template or blueprint per that last post but that may be a helpful way of keeping from having to reassign and designate a room every time there is a problem.

I think 2, though aiming to conceptualize the concern. 

Suppose the ship is 2 (col) by 3 (rows) matrix (i.e., 2 dimensional ship).   Under 1, when the first middle row room is lost that makes the previous inner walls, the outer walls.  If correct, the  2nd middle row can now be breached and you end up with two ships.  Also, wouldn't I see now stars when a room is empty (i.e., when the ship moves, I now see relative motion where the room was?   Suppose neither will occurr - then isn't that just 2 (so something is keeping track of individual (x,y) room?   Perhaps the hull is a superstructure that remains of which rooms can come and go.

Perhaps each room is a (x,y, status, assignments): So if status = destroyed you'ld end up with Mike-ODA's blueprint via assignments). 

In the end - I would think of a breach as non-functional space with a memory of prior assignments and the opportunity to reassign.

I think the first idea could work, maybe some testing could be done and see which one is the better fit. I do like the second idea too of course, but if it's too much of a hassle. Would a breach also leak over to other rooms in the ship if the room isn't sealed?

Thanks for the responses. I ended up with something closer to #2. We may as well do things properly eh  :D

So each time the room is breached it will alert the player, once sealed it will also alert the player. The room panel will show the status of the room too, so it will display the atmosphere and update in real time including its 'sealed' status.

If the room has more breached tiles than non breached, then the room will be lost completely.

All that is left is to actually cause the atmosphere to 'leak' but that will be done once the atmosphere stuff is finished. As mentioned by Got_Donuts, the room keeps track of how many breaches it has and that will dictate the rate in which atmosphere leaks - though the amount is still to be determined.


Quote from: TikTokToe on August 11, 2021, 06:52:12 PM
I think 2, though aiming to conceptualize the concern. 

Suppose the ship is 2 (col) by 3 (rows) matrix (i.e., 2 dimensional ship).   Under 1, when the first middle row room is lost that makes the previous inner walls, the outer walls.  If correct, the  2nd middle row can now be breached and you end up with two ships.  Also, wouldn't I see now stars when a room is empty (i.e., when the ship moves, I now see relative motion where the room was?   Suppose neither will occurr - then isn't that just 2 (so something is keeping track of individual (x,y) room?   Perhaps the hull is a superstructure that remains of which rooms can come and go.

Perhaps each room is a (x,y, status, assignments): So if status = destroyed you'ld end up with Mike-ODA's blueprint via assignments). 

In the end - I would think of a breach as non-functional space with a memory of prior assignments and the opportunity to reassign.

Currently you create your ship hull, then you place your flooring to create rooms. If the hull or flooring is destroyed then you are correct, they will be gone and you will see space, stars etc beneath them.
There will be issues where the ship can split, though i have ways to work around that. For instance you will need a ship core to build anything other than hull and floors and anything not connected to this ship core will need maintaining much more, ie it will lose health quicker. This will hopefully at least alleviate this issue a little. You can also only have one ship core. These ideas will need play testing though and feedback to see how it works out. So the game will only support one player ship. Any other ideas around this are welcomed though. That's the beauty of being involved whilst we are in development, we get to discuss ideas and possibly work up to something better :)

Just for clarification though, if you want to 'plug' the breaches, it will require a hull piece being build in that place, and then a flooring. As flooring can only be built on top of hull (Unless it is an external piece of hull then flooring cannot be built here).

Quick question when it relates to the hull, would it be possible to have multiple segments separate from one another? Or will everything have to setup to be a singular ship? Just curious really.