Petrenko wrote:
Heyho,
how do signs work? how do i add new ones?
Can i make a rectangle and attach every texture as .png i want?
how do the sizes work?
You should create a new sign set image, basically similar to media\textures\signs.png. When you add a sign object in inkscape, refer to your custom sign image in the description, and figure out the coordinates for the sign in scale of [0.000, 1.000]. The easiest way is to have your sign image with size 1000x1000, so when you track the rectangle coordinates for each sign in the image, you get the coordinate for the inkscape file by dividing each pixel coordinate dimension with 1000. The rectangle coordinates to input are made of x1 y1 x2 y2.
Having every sign texture in separate images is also possible, but not as efficient.
The sign object size in the game is calculated automatically. Each sign has the same height, and the width is then calculated from the aspect ratio of the sign rectangle.
Petrenko wrote:
Thanks in advance!
Edit:
How do materials work?
How do i add new?
Hod do i add them to map?
I tried different things from adding new .materials and rename the png's plus names etc.
Also: are all meshes saved in the models folder?
I saw the enclosure declared as a mesh (in map) and as material (in data1.pak) but found no mesh in the models folder.
Preferred way is to not work with .material files at all.
All externally provided meshes are in the models folder. Some of the meshes, enclosure, chairset, hedgehog, etc, are procedurally generated within the game code, so they have no external .mesh files.
These internal meshes are using specific material files, as they just happened to be implemented that way in the past. The work is in progress to make them all use the generic material that is used for e.g. cars and parasols.
Ideally, if you want a new look for a mesh, you'd add a mesh object in inkscape, and set the texture for it like:
name = parasol.mesh;
texture0 = parasol_blue.png;
This makes the entity use the generic material but switch the texture to something you wanted. If the mesh is made of multiple submeshes, you can provide multiple textures with texture1, texture2 and texture3. The internal meshes are theoretically modifiable like this as well, you could set in a mesh object in inkscape the name as name = chair, table, pipe, hedgehog, utilityPost, enclosure, ContainerMesh, CrateMesh, GrenadeCrateMesh, hmm, likely some others would work as well but I'm not going to dig them up right now. The texture won't fit in there quite that nicely though, as the internal meshes are made of more than 4 submeshes due to the way they are generated. This is something I intend to fix at some point.
So, for now, if you're into modding meshes in the game, you're better off providing your own meshes and exporting them as .mesh files (
http://www.ogre3d.org/tikiwiki/OGRE+Exporters), and place them in the map using inkscape and point them to the textures you want. No need to touch the material files.