Jump to content

Apply a shader to a vehicle's door?


[WR]Weed

Recommended Posts

Posted

Good Morning Community,

First of all I must say that my english isn't as good as yours, because I'm german ;)

So, now to my problem:

I know how to apply a texture-shader to a texture, but..

I wan't to apply an image on the vehicle, but only to the door.

I have an Army-faction an i want to put the Faction-sign on the faction-vehicles, on the doors..

Can anyone tell me how?

Posted

It is the same thing as applying a shader to any other thing. Find the texture name of the door and apply a shader to it, or you can edit the texture file (TXD) of the model and load it on the server.

By the way, you write English better than most people, don't worry :)

Posted
It is the same thing as applying a shader to any other thing. Find the texture name of the door and apply a shader to it, or you can edit the texture file (TXD) of the model and load it on the server.

Thank you!

But i dont want the image all around the door, only a little place of it ;)

I hope you understand what i mean :)

By the way, you write English better than most people, don't worry :)

Thank you :D

Posted
It is the same thing as applying a shader to any other thing. Find the texture name of the door and apply a shader to it, or you can edit the texture file (TXD) of the model and load it on the server.

Thank you!

But i dont want the image all around the door, only a little place of it ;)

I hope you understand what i mean :)

By the way, you write English better than most people, don't worry :)

Thank you :D

So, what's the problem? Just edit the door's texture and place the things where you want..

Posted

If i put the image with a shader on the door-texture, the whole door have this image..

But i dont want that the image is on the whole door, only on a little place of a the door ;)

Posted

You're not getting me - what I'm trying to say is: use the original texture of the door, edit it and add your image on it (wherever you want), not change the original texture to the one you want.

Posted

So, now i have the second problem:

Where is the patriot-door-texture?

In the "patriot.txd" is nothing with doors, only the weels and some other stuff, but not the doors :/

I hope you can help :)

Posted

How about this ..

..

https://wiki.multitheftauto.com/wiki/DxCreateShader

1.Create a shader with 'layered' argument = true

That will create a shader "on top" of the vehicle texture.

https://wiki.multitheftauto.com/wiki/En ... rldTexture

2.Apply the shader only to a certain element (the 'targetElement' argument)

3.Create a texture with an alpha channel (.png is the best bet).

4. Add ' AddressU = Clamp; AddressV = Clamp; ' when declaring your sampler. , add ' AlphaBlendEnable = TRUE; DepthBias = -0.0003; AlphaRef = 1; ' in your 'pass P0 { }'

5.Try to maniputate UV's ( ' + ' and ' * ' them all texture coordinates) and rotation (if you have to - you find that in shader examples) to make the effect the way you want - (might have to make a small gui to get the proper values).

6.PROFIT ?

...or skip what i said and use https://wiki.multitheftauto.com/wiki/Dx ... rialLine3D

as mentioned before

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...