Loobinex / keeperfx-unofficial

KeeperFX - Unofficial release
60 stars 7 forks source link

Add way to build within a 3x3, 5x5, or 7x7 radius. #161

Closed AdamPlenty closed 4 years ago

AdamPlenty commented 4 years ago

So far it's rudimentary; it simply builds on every tile that can be built on within the specified (by the numberpad) radius.

Loobinex commented 4 years ago

It's a pretty big feature, and if it is implemented it would be used a lot and be a core gameplay mechanic. I think it would be a great feature if done well, but take away from the enjoyment of the game if done badly. I'll accept this feature, but only if it looks and feels right.

As for controls, I think it would make the most sense if the number you hold when building a room would become the radius. So hold 2 for a 2x2 room, and a 5 for the 5x5 room. Both around the cursor like you did, but with even numbers always the same way off-centered.

I don't know what can be done, but it would be great if a green square (something like you get now when you hold your cursor over dirt) could appear where the room would go when you hold said number while room building is active. And that the correct price would be visible.

Sound design and visuals are also important here, placing a 25 tile room should have more weight and impact as placing a single tile has. Say, bigger delay, bigger oomph.

Also, I think just placing whichever tiles fit when you have inaccessible tiles is the way to go, since that will make it easier to place rectangles and irregular rooms.

AdamPlenty commented 4 years ago

I should be able to do 2x2, 4x5 etc, but I'll need to do it another way; the current way relies of there being a centre tile. I'll have to assume a starting position, probably the upper-left corner, but that could confuse players who don't always play the game with the view going from north to south.

No idea what to do about tile highlighting :(.

Not sure what to do about the sound either; it plays a non-3d sound from sound.dat, and I don't think there are any similar sounds we could use instead.

This originally placed the room slab on all available tiles within the radius, and I think having it place whatever fits would require some rewriting. Other games such as Theme Hospital don't just place what fits; they don't build the room if there isn't room for what you specified. I think Dungeon Keeper should follow their example. It seems to me to be too much work for too little benefit.

Loobinex commented 4 years ago

Well, DK2 and the other clones with boundboxing do allow you to place the room when there are still slabs missing. I think there's a huge benefit actually, in how it feels. I doubt it's that hard, and I'm willing to help. I think it's just a question of placing all the room slaps in a loop, and check for each slab if it fits or not.

I think for even sized rooms you should still pick the center-tile. Just always take one tile top/left of camera orientation or something.

For sounds, we could change the parameters, play multiple overlapping sounds or even add a sound to the sound.dat. This would really be a major, major feature.

AdamPlenty commented 4 years ago

Do you mean that it should just place the slab on any tile that fits within the specified radius? That's the way it was originally, but that led to rooms being placed on either side of walls etc. It made it look like no care was taken with the feature. Or do you mean that it should just stop when it encounters a tile you can't build on. I think that would require a revamp to start building from the centre tile (at least for "even" radii). The feature already checks each tile to see if it can be built on; it just starts from the top left.

Also, I notice that the placing sound does seem slightly heavier for 9x9. Perhaps this is because it's playing many times at once?

Loobinex commented 4 years ago

I think so yes. I hope the green boundbox will mitigate the feeling of it being silly when on the other side of a wall, if you see it will be placed there. For DK2 that's no real problem either.

And if you can overlap rooms, you'd have less need for placing larger sizes. If you want to fill a 5x3 space with lair, you could just place two 3x3 batches and be done with it.

Loobinex commented 4 years ago

On the discord it has been reported that on this branch, when playing multiplayer - and perhaps when playing as other colors as well - all players hear all cannot build room warnings.