Tú eliges Capital SimCity Capital Sims Capital Spore
Capital SimCity

Modding: Cambio en el formato de los edificios.

Foro general para hablar de SimCity 2013

Moderador: Equipo moderador [CSC]

Modding: Cambio en el formato de los edificios.

Notapor NinoRivera » 08 Oct 2013, 17:49

Hi everyone, just wanted to give you a heads up on an upcoming change in the data format for building assets in the Cities of Tomorrow update.

A primer on the source assets
This isn't directly relevant to the change but I think the background will be useful. I'll be using this building http://i.imgur.com/3ztFfH6.pngfor the sample assets.
Building facades (color masks, specular, heightmap, etc.) are processed from art source and create the facade textures used by the game.
Example assets: 0x00000000!0x544bceb8.0x2f4e681c 0x00000000!0xb970e986.0x2f4e681c 0x00000000!0x984c19d8.0x2f4e681c

Interior map atlases.
Example asset: 0x00000000!0x7d155619.0x2f4e681b
Palettes.
Example asset: 0x00000000!0xdd762f1f.0x2f4e681b
Buildings.
Example asset: 0x00000000!0xf2c144d4.0x2f4e681b
* Each building is split into many materials in Maya; each material refers to a section of the facade, interior map, and palette.
* Each material also has tuning parameters for all of the above, such as how big the interior rooms are, and some seeding data for the RNG that controls how the lights turn on and off.

The old way:
Artist clicks to export the building--at this point my tools take over.
We grab the parameters from each material, munge & compress them, and put them into per-vertex data.
We glue all the materials together, and make a single material that just references the relevant textures.
Animated buildings have traditional skinning data, which we convert at runtime to a simpler format
Vertex format: Positon (float3), normal (ubyte4), tangent (ubyte4), texture coordinates 1 and 2 (texcoord0 float4), material data in the rest of the channels (color ubyte4, texcoord1 short4N, texcoord2 short4N, texcoord3 float4), and optionally skinning data (indices, weights)

The new way:
Artist clicks to export the building--at this point my tools take over.
We grab the parameters from each material, munge them, and create a new uncompressed floating point texture with one column per material in the source, and 4 rows to hold this data.
We glue all the materials together, and make a single material that just references the relevant textures.
The material index and the RNG seed for the interiors are stored in the color channels of the new building
In case of animated buildings, we process the animation here and strip the skinning data from the vertices.
Vertex format: Position (float3), normal (ubyte4), tangent (ubyte4), texture coordinates 1 and 2 (texcoord0 float4), material index & interior RNG (color ubyte4, 2 unused channels), optional animation data (texcoord1 ubyte4, texcoord2 short4).
And the material data that used to be in the vertices is stored in a texture that looks kind of like this:. (lossy img since it doesn't have float values <0 or >1)

Happy modding! I'm hopeful you'll all be able to come up with some amazing tools for creating new building models.

http://forum.ea.com/eaforum/posts/list/9741368.page
Imagen
http://www.simcitycoon.com/
Información sobre el mundo de los juegos de gestión Tycoon y Citybuilders
Avatar de Usuario
NinoRivera
Empresario
Empresario
 
Mensajes: 695
Registrado: 04 Jun 2004, 23:40
Ubicación: Elche
Género: Hombre

Volver a El juego

¿Quién está conectado?

Usuarios navegando por este Foro: No hay usuarios registrados visitando el Foro y 6 invitados

Comunidad Capital Sim (2003-2008) webmaster arroba capitalsim.net