Vertex colour and paintjobs [SOLVED]

The place to discuss scripting and game modifications for X4: Foundations.

Moderators: Moderators for English X Forum, Scripting / Modding Moderators

User avatar
Axeface
Posts: 2980
Joined: Fri, 18. Nov 05, 00:41
x4

Re: Vertex colour and paintjobs [SOLVED]

Post by Axeface » Sat, 19. Dec 20, 18:46

Max Bain wrote:
Sat, 19. Dec 20, 18:39
btw i just tried to add a sec color but it is not possible for me to make a second color without a soft transition from green to red. But I want a sharp edge between green and red like you did on your ship. How dd you do that? Or are these 2 separate objects?
I talk about this on page 2 of this thread. The UV's need to be separated, so on my cyclops I cut the mesh where I wanted the lines to create edges and then seperated the UV's carefully (the mesh is not separated, just has edges where I want them). Some areas look smooth because I placed the lines in areas where there are no details. Kinda hard to explain, if you look at the cyclops you'll see what I ended up doing.
Devs can do this without cutting the mesh in 3dsmax apparently.

Max Bain
Posts: 1463
Joined: Wed, 27. Jun 18, 19:05
x3ap

Re: Vertex colour and paintjobs [SOLVED]

Post by Max Bain » Sat, 19. Dec 20, 18:49

Axeface wrote:
Sat, 19. Dec 20, 18:46
Max Bain wrote:
Sat, 19. Dec 20, 18:39
btw i just tried to add a sec color but it is not possible for me to make a second color without a soft transition from green to red. But I want a sharp edge between green and red like you did on your ship. How dd you do that? Or are these 2 separate objects?
I talk about this on page 2 of this thread. The UV's need to be separated, so on my cyclops I cut the mesh where I wanted the lines to create edges and then seperated the UV's carefully (the mesh is not separated, just has edges where I want them). Some areas look smooth because I placed the lines in areas where there are no details. Kinda hard to explain, if you look at the cyclops you'll see what I ended up doing.
Devs can do this without cutting the mesh in 3dsmax apparently.
Oh Ok, thanks. I dont want to mess with the UV maps for now. So maybe I try with just one color for the start and maybe in the future I will try to add a second.
XR Ship Pack (adds several ships from XR) Link
Weapon Pack (adds several new weapons) Link
Economy Overhaul (expands the X4 economy with many new buildings) Link
X4 Editor (view stats of objects and make your own mod within a few clicks) Link

aurumgallente
Posts: 121
Joined: Sun, 14. Jun 20, 14:45
x4

Re: Vertex colour and paintjobs [SOLVED]

Post by aurumgallente » Sat, 19. Dec 20, 23:52

I suppose you can detach part of the mesh, color both parts independently and merge it again. Just make sure UV maps on both parts have the same name before merging or you will lose one.
Also fast googling showed me this.

Max Bain
Posts: 1463
Joined: Wed, 27. Jun 18, 19:05
x3ap

Re: Vertex colour and paintjobs [SOLVED]

Post by Max Bain » Mon, 21. Dec 20, 14:15

One last question Axeface:

I have added vertex colors to most of my ships now, but in the ship configuration menu the parts that should look grey/blueish the color is pure black. I tried to color the first vertex color in green (from page one), red or even white and it makes no difference. When I change the paint job it looks much better, so it might be the default paint job. But its not black on your ship or vanilla ships.

https://steamuserimages-a.akamaihd.net/ ... 2EB4AA306/
XR Ship Pack (adds several ships from XR) Link
Weapon Pack (adds several new weapons) Link
Economy Overhaul (expands the X4 economy with many new buildings) Link
X4 Editor (view stats of objects and make your own mod within a few clicks) Link

User avatar
Axeface
Posts: 2980
Joined: Fri, 18. Nov 05, 00:41
x4

Re: Vertex colour and paintjobs [SOLVED]

Post by Axeface » Mon, 21. Dec 20, 17:18

Max Bain wrote:
Mon, 21. Dec 20, 14:15
One last question Axeface:

I have added vertex colors to most of my ships now, but in the ship configuration menu the parts that should look grey/blueish the color is pure black. I tried to color the first vertex color in green (from page one), red or even white and it makes no difference. When I change the paint job it looks much better, so it might be the default paint job. But its not black on your ship or vanilla ships.

https://steamuserimages-a.akamaihd.net/ ... 2EB4AA306/
Ive not had that issue before no, when you say grey/blueish you mean the default empire theme grey/blue? Perhaps the empire theme isnt working on some of the ships. Did you switch the material to an X4 vanilla one on that ship too like with the red knight?

Max Bain
Posts: 1463
Joined: Wed, 27. Jun 18, 19:05
x3ap

Re: Vertex colour and paintjobs [SOLVED]

Post by Max Bain » Mon, 21. Dec 20, 17:23

Axeface wrote:
Mon, 21. Dec 20, 17:18
Max Bain wrote:
Mon, 21. Dec 20, 14:15
One last question Axeface:

I have added vertex colors to most of my ships now, but in the ship configuration menu the parts that should look grey/blueish the color is pure black. I tried to color the first vertex color in green (from page one), red or even white and it makes no difference. When I change the paint job it looks much better, so it might be the default paint job. But its not black on your ship or vanilla ships.

https://steamuserimages-a.akamaihd.net/ ... 2EB4AA306/
Ive not had that issue before no, when you say grey/blueish you mean the default empire theme grey/blue? Perhaps the empire theme isnt working on some of the ships. Did you switch the material to an X4 vanilla one on that ship too like with the red knight?
Because the paint jobs work, I havent switched the textures. Its just that the blueish areas are way darker than they should but with most paint jobs tey look good.
XR Ship Pack (adds several ships from XR) Link
Weapon Pack (adds several new weapons) Link
Economy Overhaul (expands the X4 economy with many new buildings) Link
X4 Editor (view stats of objects and make your own mod within a few clicks) Link

User avatar
Axeface
Posts: 2980
Joined: Fri, 18. Nov 05, 00:41
x4

Re: Vertex colour and paintjobs [SOLVED]

Post by Axeface » Mon, 21. Dec 20, 21:47

Its probably just because the texture in those areas is intentionally dark.

Oh, I was just having another look at the SV split ships, they use all red not green in the first channel, this makes the entire ship the secondary highlight colour instead of (usually) grey, I wasnt sure about this so sorry for saying you should colour it green. If you colour the red knight 1st channel red instead, it will be red, yellow, blue etc etc - depending on empire screen default theme.

User avatar
Killjaeden
Posts: 5366
Joined: Sun, 3. Sep 06, 18:19
x3tc

Re: Vertex colour and paintjobs [SOLVED]

Post by Killjaeden » Wed, 23. Dec 20, 23:34

Late to the party here, but i think its worth pointing out:
Axeface wrote:
Fri, 28. Feb 20, 00:48
I was doing something similar by using split on the edges. But the same problem remains unfortunately, I get the hard edge for the paintjobs but the lighting between the 2 faces is not smooth.
Editing the vertex normals is the solution for this problem. The noticeable lighting edge will be gone, if both vertices after the split have identical vertex normal direction. If its a complex smooth surface, cutting into it and splitting that cut will lead to irregularities. Manual editing of the normals then can be a pita.
Idk about blender, but for max there is a very unique plugin set for aligning vertex normals to the shape you want. It allows you to do things you would never be able to fix properly without relying on baking from high poly (which is just not an option for tiling texture models).
https://gumroad.com/l/VertexNormalToolkit
[ external image ]
X-Tended TC Mod Team Veteran.
Modeller of X3AP Split Acinonyx, Split Drake, Argon Lotan, Teladi Tern. My current work:
Image

User avatar
Axeface
Posts: 2980
Joined: Fri, 18. Nov 05, 00:41
x4

Re: Vertex colour and paintjobs [SOLVED]

Post by Axeface » Thu, 24. Dec 20, 20:10

Killjaeden wrote:
Wed, 23. Dec 20, 23:34
Late to the party here, but i think its worth pointing out:
Axeface wrote:
Fri, 28. Feb 20, 00:48
I was doing something similar by using split on the edges. But the same problem remains unfortunately, I get the hard edge for the paintjobs but the lighting between the 2 faces is not smooth.
Editing the vertex normals is the solution for this problem. The noticeable lighting edge will be gone, if both vertices after the split have identical vertex normal direction. If its a complex smooth surface, cutting into it and splitting that cut will lead to irregularities. Manual editing of the normals then can be a pita.
Idk about blender, but for max there is a very unique plugin set for aligning vertex normals to the shape you want. It allows you to do things you would never be able to fix properly without relying on baking from high poly (which is just not an option for tiling texture models).
https://gumroad.com/l/VertexNormalToolkit
Lino mentioned this (vertex normals) earlier in the thread, maybe the feature/plugin you mention is what lino was talking about, thanks for the info though. I'll have another look but I dont think blender has this functionality.
In the meantime im going to make a small video about how I got around the problem (it isnt ideal but it works), might help some people.

Rothank
Posts: 53
Joined: Mon, 11. Aug 14, 22:48
x4

Re: Vertex colour and paintjobs [SOLVED]

Post by Rothank » Mon, 2. Oct 23, 22:24

Apologies for necro, but I figured that since this thread is being used as official guide to Vertex colors it needs some additional details. Attached is vertex-coloring cheat-sheet I am using on my ships:

[ external image ]

edit: can't figure out how to post an image directly :/
Image Image
Image

linolafett
EGOSOFT
EGOSOFT
Posts: 3380
Joined: Mon, 26. Mar 12, 14:57
x4

Re: Vertex colour and paintjobs [SOLVED]

Post by linolafett » Wed, 4. Oct 23, 15:50

At least with the new exporter tools, you should be able to support the "sharp edge" for coloring but a smooth shading on the same surface, as the better collada exporter does understand face corner data (which is needed for the vertex colouring to appear sharp).

I dont really understand your cheat sheet @rothank.
The green color was a attempt in getting a complimentary color into the asset, but it did not really work out, therefore i later only used the primary colour and skipped the secondary color.
01001100 01101001 01101110 01100101 01110011 00100000 01101111 01100110 00100000 01110100 01101001 01101101 01100101 01110011 00101110 00101110 00101110

My art stuff

Rothank
Posts: 53
Joined: Mon, 11. Aug 14, 22:48
x4

Re: Vertex colour and paintjobs [SOLVED]

Post by Rothank » Wed, 4. Oct 23, 18:05

linolafett wrote:
Wed, 4. Oct 23, 15:50
At least with the new exporter tools, you should be able to support the "sharp edge" for coloring but a smooth shading on the same surface, as the better collada exporter does understand face corner data (which is needed for the vertex colouring to appear sharp).

I dont really understand your cheat sheet @rothank.
The green color was a attempt in getting a complimentary color into the asset, but it did not really work out, therefore i later only used the primary colour and skipped the secondary color.
Hey Lino.
The complimentary color using green works with paints that have a hue to them. Let's use Mineral Rush or Violaceous as an example:
[ external image ]

For paints that have no color shift on secondary color (starting paints, for example) there will be no difference between white and green COL.
Image Image
Image

Return to “X4: Foundations - Scripts and Modding”