Jump to content


Photo

Issue #139 Base Facilities Texturing


  • Please log in to reply
226 replies to this topic

#201 Vaaish

Vaaish

    Artwork Department

  • Xenocide Inactive
  • 1,625 posts

Posted 12 March 2008 - 07:08 AM

I agree about destructible walls in alien ships and above ground buildings, but in the underground bases, being able to destroy the module outer walls won't really add much since there is nothing beyond them except dirt/rock. I guess we could have dirt stream through if a chunk of outer wall goes up.

#202 dteviot

dteviot

    Programming Department

  • [Xenocide Senior Members]
  • 1,479 posts

Posted 12 March 2008 - 12:39 PM

Yes, the props (The table for the barracks) the server and microscope for the lab etc etc are not attached. The table for instance is one piece, but we would only want half of it destroyed though if it was hit like in the game.

But the walls even in the alien ships were destructible with enough power.

2ndly If you had the game not render pieces of the model, wall etc how would that look, because there is nothing on the side of a destroyed wall

OK, if I follow you, you're saying the 3D facility models are not a single mesh. The "breakables" are included as sub meshes in the model. OK, that's a step on the way, but it leaves me with the problem of how to map the "sub meshes" to volumes in the battlescape. So I the game engine can path around them, line of sight visibility, damage them with weapons fire/explosions etc.

Basically, I'm trying to figure out the structure for the battlescape game rules and graphics engines.
Saving the world from the scum of the universe is hard work. Especially when you have to create the scum to begin with.

#203 Shinzon

Shinzon

    Artwork Department

  • Xenocide Artwork Department
  • 265 posts

Posted 12 March 2008 - 03:02 PM

That still leaves the problem with the barracks; the bunkbeds are all part of the model; so the logic of rock outside pushing doesn't flow with them.... What if an explosion goes of in the rax; do the walls were the bunk beds remain unharmed?

I can see how if the outer wall is damaged their texture can be changed with some scortch marks or something...

The same goes for the Lab where the specimens are contained; the wall itself and even the door are part of the model...

#204 dteviot

dteviot

    Programming Department

  • [Xenocide Senior Members]
  • 1,479 posts

Posted 12 March 2008 - 03:33 PM

do the walls were the bunk beds remain unharmed?

Sorry, I don't understand. Please clarify.
Saving the world from the scum of the universe is hard work. Especially when you have to create the scum to begin with.

#205 Shinzon

Shinzon

    Artwork Department

  • Xenocide Artwork Department
  • 265 posts

Posted 12 March 2008 - 07:00 PM

In the barrakcs there are bunk beds that are intergrated into the wall correct? I am persuming that those "Inner" "walls" could be blown up, compared to the "Outer Wall"

#206 dteviot

dteviot

    Programming Department

  • [Xenocide Senior Members]
  • 1,479 posts

Posted 12 March 2008 - 10:07 PM

In the barracks there are bunk beds that are integrated into the wall correct? I am presuming that those "Inner" "walls" could be blown up, compared to the "Outer Wall"

I'm still not sure what you're asking.
there's the 3D model, and a cell layout (that's used by the "rules engine") At the current time, the walls in the cell layout that mark the positions of the bunks are unbreakable. I haven't implemented breakable walls in the rules engine, yet, but it should not be difficult to do. (Just give each wall an "armor factor". Any explosion that does more damage than the armor factor will destroy the wall (so I would remove the wall from the cell layout.) But I' don't know what the graphic engine would need to do to the 3D model to reflect the destroyed bunk. Or even how. Simplest case might be to not draw the bunk. But then I've got the problem of how do I map cell walls X, Y and Z in the cell layout to mesh "bunk3" (or whatever it is) in the 3D model.
I hope that clarifies things
Saving the world from the scum of the universe is hard work. Especially when you have to create the scum to begin with.

#207 Vaaish

Vaaish

    Artwork Department

  • Xenocide Inactive
  • 1,625 posts

Posted 12 March 2008 - 10:26 PM

I believe he means leave the walls surrounding the module as unbreakable and any walls that subdivide the interior of the module as breakable.

#208 Shinzon

Shinzon

    Artwork Department

  • Xenocide Artwork Department
  • 265 posts

Posted 12 March 2008 - 10:30 PM

Yes you got it vaaish ^_^

#209 dteviot

dteviot

    Programming Department

  • [Xenocide Senior Members]
  • 1,479 posts

Posted 12 March 2008 - 10:33 PM

A thought that occurs to me, goes something like this:
1. Currently the rule engine divides the battlescape up into cells.
2. Each cell has 3 faces north, west and ground.
3. The graphic engine draws a textured quad for each face. The result looks UGLY.

So, what happens if we get rid of the faces. Instead each cell holds a 3D model. e.g. Instead of having a cell having a north wall, the cell would have a 3D model of a wall segment, running east/west. Then drawing the battlescape would be a case of looking up all the models and drawing them. (Note, because the screen would be made of hundreds of 3D models, I'd probably need to use model instancing to draw, so individual models can't be too complicated.
60 fps and 20 x 20 cells per layer, and 4 layers = aprox 100,000 models per second. So, poly count of maybe 100 per model? Note, most models would be floor tiles, so just a simple quad. (2 triangles)
Saving the world from the scum of the universe is hard work. Especially when you have to create the scum to begin with.

#210 dteviot

dteviot

    Programming Department

  • [Xenocide Senior Members]
  • 1,479 posts

Posted 12 March 2008 - 10:37 PM

I believe he means leave the walls surrounding the module as unbreakable and any walls that subdivide the interior of the module as breakable.

I'm not following where you're going with this.
As I said, at moment no walls are breakable.
Also I have no problem, in theory, with some objects being not breakable.
Where I have the problem is handling breakables.
Saving the world from the scum of the universe is hard work. Especially when you have to create the scum to begin with.

#211 Vaaish

Vaaish

    Artwork Department

  • Xenocide Inactive
  • 1,625 posts

Posted 13 March 2008 - 07:48 AM

We aren't saying that any walls currently are, we are simply saying which ones we don't think SHOULD be breakable. I'm attaching an image to try to explain better.

Attached Files



#212 Mad

Mad

    Creative Text Department

  • [Xenocide Senior Members]
  • 1,958 posts

Posted 13 March 2008 - 08:00 AM

I think the main problem - correct me if I'm wrong - is "what should the gfx engine display after destroying a destroyable wall? There is nothing to be displayed. No floor, no wall...
Keep smiling while dying

Of course I have gone mad with power! It would be completely ridiculous to go mad without power!
And no, this is not a quote from the Simpson's movie, I want it on paper, that I actually wrote that quite some time before the movie came out.

Posted Image

#213 Shinzon

Shinzon

    Artwork Department

  • Xenocide Artwork Department
  • 265 posts

Posted 13 March 2008 - 10:08 AM

Depending on what was destroyed the engine might go and look into "Doodade" sub models; which contain things like gibs, and pre modeled broken stuff; and all the engine does is replace the said wall with a broken one... By wall I mean cell

#214 dteviot

dteviot

    Programming Department

  • [Xenocide Senior Members]
  • 1,479 posts

Posted 13 March 2008 - 01:12 PM

I think the main problem - correct me if I'm wrong - is "what should the gfx engine display after destroying a destroyable wall? There is nothing to be displayed. No floor, no wall...

Er, not exactly, it's more a case of how do the gfx engine handle breakables? And how do the rules engine communicate breakable information to the gfx engine?
Note, discussion here is somewhat difficult due to my limited knowledge of models. (I just use XNA to drag the model in and render it.)
Let me try and explain some of the issues.
  • Lets start by assuming we have a destroyable wall (Say the internal walls in the Lab facility)
  • So, is this wall one model, or multiple models?
  • Assume the wall is made up of several 3D models, one model per cell.
  • How do I associate cells to models? How do I say which whole group of cells are drawn using a single unbreakable model, and other cells have their own model?

Edited by dteviot, 13 March 2008 - 01:13 PM.

Saving the world from the scum of the universe is hard work. Especially when you have to create the scum to begin with.

#215 dteviot

dteviot

    Programming Department

  • [Xenocide Senior Members]
  • 1,479 posts

Posted 22 March 2008 - 05:20 PM

Please read, and respond to, http://www.xcomufo.c...topic=242028636
I'm assuming art people don't read my posts in the programming area.
Saving the world from the scum of the universe is hard work. Especially when you have to create the scum to begin with.

#216 Vaaish

Vaaish

    Artwork Department

  • Xenocide Inactive
  • 1,625 posts

Posted 22 March 2008 - 10:11 PM

Can the graphics engine dynamically add an alpha map to a model where the wall has been destroyed and if appropriate place premade rubble cells in the transparent area?

#217 kafros

kafros

    Creative Text Department

  • Xenocide Creative-Text Departmen
  • 1,800 posts

Posted 23 March 2008 - 01:00 PM

Can the graphics engine dynamically add an alpha map to a model where the wall has been destroyed and if appropriate place premade rubble cells in the transparent area?

That's a totally different way of thinking and actually very interesting!!

Another (almost identical approach) is to check which wall cells where affected, and then overlay a texture (probably with an alpha map, but it isn't vital). You don't have to add/remove models or part of the wall mesh. In addition, you can either add tiny rubble models (which can collide with neighbouring models) or even generate particle effects (debris and smoke)

Edited by kafros, 23 March 2008 - 01:06 PM.


#218 dteviot

dteviot

    Programming Department

  • [Xenocide Senior Members]
  • 1,479 posts

Posted 24 March 2008 - 01:13 PM

Can the graphics engine dynamically add an alpha map to a model where the wall has been destroyed and if appropriate place premade rubble cells in the transparent area?

I think you mean, "could the graphics engine I'm going to write do this." :)
And the answer is. I think so, but I don't think it would help any.
  • Firstly, It doesn't do anything to help with how to go from the cell geometry in the "rules engine" to the UV co-ordinates in the texture. In fact, it's probably harder to do that with the texture than it is with the 3D vertexes.
  • Second, and I'm not sure, but I suspect trying to modify a texture more work than dropping vertexes out of mesh.
  • Thirdly, if the mesh is a 3D volume, and I make parts of the surface transparent, then you're going to see the inside of the mesh. e.g. If its a wall, and we slice a hole through it, you're not going to see brick inside the hole, you'll see nothing.

Edited by dteviot, 24 March 2008 - 01:13 PM.

Saving the world from the scum of the universe is hard work. Especially when you have to create the scum to begin with.

#219 Vaaish

Vaaish

    Artwork Department

  • Xenocide Inactive
  • 1,625 posts

Posted 24 March 2008 - 01:56 PM

on your third point, that is what the rubble cell does. It prevents you from seeing the inside of the mesh since it now occupies the location you can see through. in this way we only need to worry about having rubble models that can be reused instead of having to have every model broken into chunks and worry about things like how the texture wraps around the new break.

Edited by Vaaish, 24 March 2008 - 01:58 PM.


#220 Shinzon

Shinzon

    Artwork Department

  • Xenocide Artwork Department
  • 265 posts

Posted 29 March 2008 - 01:31 PM

Something compleatly unrelated:

Does the baseview need its own skybox? I would think so...

#221 dteviot

dteviot

    Programming Department

  • [Xenocide Senior Members]
  • 1,479 posts

Posted 29 March 2008 - 02:42 PM

Something compleatly unrelated:

Does the baseview need its own skybox? I would think so...

Assuming by baseview you mean the screen where you layout facilities in an outpost.
Then, no, it doesn't need a skybox, because the view never moves. However, a background image might be nice. (Not sure thought.)
Saving the world from the scum of the universe is hard work. Especially when you have to create the scum to begin with.

#222 Darkhomb

Darkhomb

    Captain

  • Xenocide Artwork Department
  • 628 posts

Posted 29 March 2008 - 03:23 PM

I don't know what it would be besides dirt...

#223 Shinzon

Shinzon

    Artwork Department

  • Xenocide Artwork Department
  • 265 posts

Posted 29 March 2008 - 03:29 PM

In that case is it possible to genearte a diffrent image (From a pool of images) depending on where the base is located?

Ex:

Mountains - Lots of big rocks; huge granite formations and such
Costal - sedement mostly, no big rocks
"Normal" - normal "Dirt"
Proximity to city - possible pipes and such

#224 Darkhomb

Darkhomb

    Captain

  • Xenocide Artwork Department
  • 628 posts

Posted 29 March 2008 - 03:32 PM

That would be kind of cool, but that would still be on the backburner for prog dept. So we could always do the dirt one now and have others ready for later.

Edited by Darkhomb, 29 March 2008 - 03:33 PM.


#225 Shinzon

Shinzon

    Artwork Department

  • Xenocide Artwork Department
  • 265 posts

Posted 30 March 2008 - 12:21 PM

So after this talk about destructables; should I continue working on theese as if they are meant to be part of the base invasion mission; or strictly just part of the baseview?

#226 Darkhomb

Darkhomb

    Captain

  • Xenocide Artwork Department
  • 628 posts

Posted 30 March 2008 - 05:04 PM

Baseview just has a screenshot of the facility from above. So yes they will be used in base invasion.

#227 Vaaish

Vaaish

    Artwork Department

  • Xenocide Inactive
  • 1,625 posts

Posted 31 March 2008 - 07:36 AM

I would say continue. as mentioned, at the least they can be used for baseview and at best for battleview as well.