Skip to main content
gamedev.net
🔒 Locked

Team Texturing...........

Started by Raptor 5 replies 300+ views
Original Post
Raptor
Raptor
how do i render an object which is textured, in a different manner so as to distinguish it from another object belonging to a different team?? is it possible to use diffuse color(material properties) along with the texture to shade the same texture using a different color? thnx in advance, Raptor
DekuTree64
DekuTree64
You mean tint the texture some color? Just change the color of the vertices of the polygon it''s on. As far as I know, you can''t brighten it (white is untinted), but if you just need to have it greenish or something, that should work.



-Deku-chan

DK Art (my site, which has little programming-related stuff on it, but you should go anyway^_^)

"I'm dropping like flies!" - me, playing Super Smash Bros. (and losing)
"What fun!" - me, playing Super Smash Bros. (and beating the crap out of somebody)
risingdragon3
risingdragon3
Ahha! I believe that your thinking of the Homeworld type team coloring thing? It was done by procedural textures. At least I think so . Basically, you have a base texture, with a one particular color declared 'paint over', and when you choose your team color, it will repaint all of _your_ textures with the new team color, coloring over all the 'paint over' parts. Although this might be a bit texture intensive. However, in Homeworld, notice that there are only 5 or 6 textures per race/team, so it doesn't eat that much memory.
What I did, I had multiple TextureLists, each unit had a 'owner' class, which had a textureList pointer, which was used to get the unit's textures. All the textures are superfically the same, apart from the 'paint over' bits.
With a bit of skill, you can have nice color schemes that change color depending on what team your're with
Oh yeah - I also meant to say, that you did all the repainting when you loaded up. Of course .

------------------------------
BCB DX Library - RAD C++ Game development for BCB

Edited by - c++freak on October 1, 2000 9:22:34 PM
Raptor
Raptor
As our game supports upto 12 players (multiplayer) i cannot opt the method of overdrawing parts of the texture for each player.


How do i go about?I am using Direct3D.

Is it possible to change the palette (in high color modes) to achieve this?

thnx again,

Raptor
Bandures
Bandures
Methods:
1) 2-nd Texture ( like light-map , but for color use)
2) separate colored part of object and render it with material set to color
3) separate colored part of object and set it''s texture to somethink like "TEXTURE_TEAM" , then rendering , change this texture to some simple team texture.
exm:
if(texture == "TEXTURE_TEAM")
{
____if team == 1 then set texture="TEXTURE_TEAM1"
____...
____if team == 100 then set texture="TEXTURE_TEAM100"
}



risingdragon3
risingdragon3
I just got another idea:
1) have your textures with transparency for the paint over bits
2) Have a 2nd texture with multi-texturing and make that like, 2 by 2, so it would cover over the transparent bits. I don''t really know how to do this. Something like alpha_modulate or something? I haven''t really dabbled with multi-texturing.
That would work, with tiny mem. usage.

What do you think?


------------------------------
BCB DX Library - RAD C++ Game development for BCB

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.