Revisit 7 - Building Collision

Web log of development issues.

Revisit 7 - Building Collision

Postby adamsderk » Tue Jun 23, 2009 9:56 pm

Greetings,

I have had some "fun" in the engine and figured out how to make my building able to be walked through while the roof can be walked upon. I have made the trigger object (the thing that surrounds the building and turns on and off the physical effect of modifying the player's velocity when they are in the building) collidable when it is below the player, and non-collidable when the player is in or below it.

The snag is that the trigger object isn't sent to the client, so when the client "interpolates" between server updates, it makes the player fall and then bounce back up... making camera jitter. So that is next to be fixed. Then I will probably make a new object type that joins the model, trigger, and physical effect into one item.

The bad news is that it means that all roofs in the game will have to be flat as that is the only way to know where the roof is located.

Thanks.
Image
adamsderk
Site Admin
 
Posts: 1404
Joined: Tue Apr 19, 2005 11:52 pm
Location: Western Washington

Postby Hana Yuriko » Sun Jun 28, 2009 11:09 am

I finally got your building mockup. Sorry it took so long to get to.

I now see what you mean by tabs at the edges of the walls. Would you like irregular shaped tabs to look more like destroyed wall sections?

Also we can't just have 4 walls without any doors and/or windows! How do you want to approach that issue?

Lastly, defensive wall sections like a barrier wall that surrounds a base. I think the previous one I had sent to you (made from hex pieces) would work since you can destroy parts of it instead of an entire wall. Just need to rebuild the damage tabs to make it look better.
Hana Yuriko
 
Posts: 274
Joined: Sat Apr 23, 2005 4:18 am

Postby adamsderk » Mon Jun 29, 2009 3:35 am

Hana,

A picture (or model) is worth a thousand words :)

I think irregular would look better, but I think it best to keep everything as simple as possible (and low poly) to prove the concept on each object type. Once that placeholder is proven, then we can open it up to see how far it can be pushed.

For my purposes, a building can be entered from any point. So maybe make the entire bottom be doors and windows above (since each level is two stories).

I agree with your wall, but I think it is too complex for this round, just three sections (like a single building wall) will provide the "resolution" that I can put into it. Maybe splitting it top and bottom as well, so I don't remove the bottom sections until it is really gone, otherwise it will look like there is a path through the wall when there isn't one.

Thanks.
Image
adamsderk
Site Admin
 
Posts: 1404
Joined: Tue Apr 19, 2005 11:52 pm
Location: Western Washington

Postby Hana Yuriko » Tue Jun 30, 2009 5:02 pm

I have some idea for 3 wall types that'll follow a similar design plan. When I have some time I'll mock up a wood frame, brick, and reinforced concrete wall.

Instead of tabs, for the wood frame wall I'll have three layers. The exterior wall, the wood frame itself and an interior wall. The exterior wall will look solid when joined together, but the sectioned parts will seem damaged when the pieces are separated. It can also have sectioned siding to further the "damage" look. The building's interior wall will be a simple 2d plane that's cut to fit the exterior wall section. The wood frame itself will act as the "tabs."
http://lizzy777.googlepages.com/walls.jpg

The brick wall will be easier. It'll have interlocking seams of bricks that run down the edges of the sections. The bricks themselves will again act as the "tabs."
http://lizzy777.googlepages.com/walls2.jpg

The concrete wall will basically be simple, irregular wall sections that look solid when together. I could add in some bent pieces of rebar for effect.
http://lizzy777.googlepages.com/walls3.jpg
Hana Yuriko
 
Posts: 274
Joined: Sat Apr 23, 2005 4:18 am

Postby adamsderk » Tue Jun 30, 2009 5:36 pm

Hana,

Wow, it really shows when a pro is involved. Excellent job taking my framework and turning it into a masterpiece.

I look forward to seeing it in game, as soon as I can get these collision boxes under control (grumble).

Thanks.
Image
adamsderk
Site Admin
 
Posts: 1404
Joined: Tue Apr 19, 2005 11:52 pm
Location: Western Washington

Postby adamsderk » Wed Jul 01, 2009 4:58 pm

Hana,

As I was thinking about these this morning, I realized that scale might be an issue. If "bricks" are the standard 8 inch high concrete blocks, they would be 24 high for a level 1 wall. If they are "construction blocks" which have to be moved by machines, they are two feet high and a level 1 wall would be 8 high. And if they are the standard 2.25 inch thick bricks, there would be 85 bricks high for a level 1 building (not including mortar).

Also, I think I'm going to go with your idea of stacking levels to make taller buildings.

Thanks.
Image
adamsderk
Site Admin
 
Posts: 1404
Joined: Tue Apr 19, 2005 11:52 pm
Location: Western Washington

Postby Hana Yuriko » Wed Jul 01, 2009 10:52 pm

I was thinking of scale as well. Especially when you consider the siding on a wood frame wall, and the bricks as you mentioned.

I figure the brick walls would be akin to a cinder block type structure. So the only thing I need to know is... How tall do I make each wall? 6m?

Since you plan on stacking floors to make taller buildings, will you need an entire floor, or do you want floor sections? Like a corner piece, a center wall panel, and a center (for the middle of the structure) interior piece?

http://lizzy777.googlepages.com/walls4.jpg (center column is optional)
Hana Yuriko
 
Posts: 274
Joined: Sat Apr 23, 2005 4:18 am

Postby adamsderk » Thu Jul 02, 2009 4:51 pm

Hana,

The buildings should be 6 meters tall and 16 meters wide and deep. This equates to a quarter hex building that is one level (two stories) high.

In the game, as you know, buildings take up a hex which is approximately 30 meters square (32 meters in my game). I am open to suggestions as how to represent them in the game; as fewer, bigger buildings are computationally better than many, smaller buildings.

As for the stacking, each level should have a floor and ceiling. I would like the floor and ceiling to be broken into the 9 sections, but with a larger center piece. I see that the wall could collapse taking a small amount of the ceiling and floor with it, but I don't want to take too much of the ceiling, because it can still be walked on until the entire level is destroyed.

Of note: the player will be able to go inside the building, so there needs to be an interior texture as well. And I love the column.

To think about: I'm wondering if instead of the "tabs" to just put a double sided plane in the middle of all the walls that has a semi-transparent texture that shows the "damaged" building. I'm thinking this route because the rules state that you cannot fire into or out of a building. Any weapon attacks will be absorbed by the building until it is destroyed. By having a semi-transparent damaged section, the players could "see" each other, but would also understand that their weapons would hit the building as there wouldn't be a "hole."

Thanks.
Image
adamsderk
Site Admin
 
Posts: 1404
Joined: Tue Apr 19, 2005 11:52 pm
Location: Western Washington

Postby Hana Yuriko » Thu Jul 02, 2009 6:48 pm

adamsderk wrote:By having a semi-transparent damaged section, the players could "see" each other, but would also understand that their weapons would hit the building as there wouldn't be a "hole."

Thanks.


Ooo... Bad idea. The plane would act as a solid barrier. The reason I hate it is if you can see through, you should be able to SHOOT through. It's like when playing a game and you can't shoot through a chain link fence. For some reason the rather porous fence absorbs bullets.

Also, you CAN shoot out of a building. IIRC shooting into one, the structure absorbs a specific amount of damage (according to its CF) while transferring the remainder to the units inside. Plus is you reduce the CF to where the walls collapse, you can literally drop a building on top of the people inside.
Hana Yuriko
 
Posts: 274
Joined: Sat Apr 23, 2005 4:18 am

Postby adamsderk » Thu Jul 02, 2009 8:57 pm

Hana,

The building doesn't have a collision mesh. The collision box is a cube surrounding the building. This is also how I know when a unit enters and exits a building and defines the area to slow them down. The box is non-collision for units (I do damage based on being in the building), but is collision for projectiles (otherwise they would fly through a building as if it wasn't there).

The damage rules are that weapons fire on a building will be partially absorbed by the building and the rest will be transferred to the units within. Let's say there is a Mech and an infantry unit in a building. If an enemy unit fires on the building, the damage will be split between the building, Mech, and infantry. Showing a weapon hit the Mech and then have the building and infantry take damage doesn't make sense (especially if I make little explosions around them). Having the building show the impact and then the contained units taking damage does make sense. I.e. when dealing with buildings, accuracy is not a factor, just damage amount. When a building is destroyed, the levels on top of it will collapse doing damage to all contained units and will be left with a rubble hex (don't know how I'm going to do the rubble yet).

So, having projectiles impact on a surface with a few holes (not chain link, there should be more building than holes) should make more visual sense.

Oh, and strangely enough, there are "no" rules about firing outside a building from inside a building, and requests on the CBT forums are unanswered. So, I'm taking the same line, if you are inside a building and fire at the walls, you will damage the building and debris will damage the units within, including yourself.

Thanks.
Image
adamsderk
Site Admin
 
Posts: 1404
Joined: Tue Apr 19, 2005 11:52 pm
Location: Western Washington

Postby Ben » Fri Jul 03, 2009 2:18 am

Darn, I don't have access to my rule books right now, but I'm with Hana. I think shooting out of a building does not damage the building. I'm almost certain that is the case for infantry. Shooting into a building is as you've both described.

I do have a couple of questions though. First, how are you planning on allowing infantry to change levels in a building? I'd lean towards something as simple as levitating up and down between levels. I don't think messing with stairs and stuff would be a good way to spend polys, or add that much to gameplay.

My other question is, do you have any thoughts about walking on top of buildings? How are you going to differentiate between a mech that wants to walk through a level 2 building, and one that wants to walk on top of it? Can't vehicles even drive on to a level 1 building? I can't think of a really good way to visually and gameplay wise handle those circumstances, any thoughts?
Ben
 
Posts: 169
Joined: Sat Apr 23, 2005 10:42 pm
Location: New Zealand

Postby Veers » Fri Jul 03, 2009 12:20 pm

I don't know about not having stairs, think about trapping infantry on one level by taking them out, you can then leave them and carry on knowing they can't get to you or finish them off.
Veers
 
Posts: 149
Joined: Wed Mar 08, 2006 10:32 pm
Location: UK

Postby adamsderk » Sat Jul 04, 2009 2:16 pm

Ben,

There are no, I mean no, rules about shooting from inside a building. Even the rules for infantry don't include inside, only from the roof.

On just a practical note, the only way a Mech or vehicle could fire out of a building without hitting the building would be through a window or door and they would have to be right next to a wall, i.e. destroying the room next to the window and the window would have to line up with their weapon.

Since the "resolution" of the roleplaying game is 30 square meters (a hex), assuming the unit is in the middle of the hex, there is no way they would have line of sight to anything outside the building.

Infantry will use an "elevator" to change levels :) Yea, levitating.

Oh, and the building object I'm working on is cool. If you are above the building, it is solid... you can walk on the roof (assuming sufficient CF). But if you are below the top of the building, you move through it (doing damage). A building will only be one level high, multiple level buildings will be a stack of one level buildings. So a Mech can walk through a level 1 building or jump on top of it. A Mech can use jump jets to move out of a building but not to a level below its current level, which allows it to "jump" up levels (doing damage all the way). Without jump jets, a Mech or vehicle can only enter a building at the level it was before the building hex, so to drive on the roof of a level one building, the vehicle would have to drive from a level one ground (so, the building would be embedded in a hill).

Veers,

The rules don't trap infantry, they can either move or are destroyed by a collapsing building.

Thanks.
Image
adamsderk
Site Admin
 
Posts: 1404
Joined: Tue Apr 19, 2005 11:52 pm
Location: Western Washington

Postby Ben » Sat Jul 04, 2009 10:12 pm

Hrm... I thought I remembered something about shooting out, but since my BTech stuff is on the other side of the world right now, I can't really argue with you :D

You're building object really sounds cool, I'm looking forward to checking it out, but I guess I wasn't clear on the second part of my question. I was wondering about mech's with out jump jets (or mech with JJs that don't want to use them). On the board game, those mechs can walk from level 0 ground, to the roof of a level 2 building by just expending movement points. It's just as if they were walking from level 0 ground to a level 2 hill. Of course, this is one of those areas that is glossed over in the board game. It's never really explained how these mechs manage to scale the sides of the buildings. Is this just a place where you'll need to vary from the game? Or, I guess, you could just make all the buildings 3 levels or taller :lol:
Ben
 
Posts: 169
Joined: Sat Apr 23, 2005 10:42 pm
Location: New Zealand

Postby Hana Yuriko » Sat Jul 04, 2009 11:45 pm

That is true. A 'mech can climb on top of a level 2 structure in the tabletop version. IIRC it takes a piloting skill roll. If failed the unit has a chance to fall into the building, suffering normal falling damage and damage from entering a building.
Hana Yuriko
 
Posts: 274
Joined: Sat Apr 23, 2005 4:18 am

Next

Return to Development Blog

Who is online

Users browsing this forum: No registered users and 1 guest

cron