Weapon Tint/Color
#1

Hi guys, I have seen in some servers that you can buy guns from ammunitions and choose the tint/color of the weapon, like for example you buy a 9MM gold tinted (yellow all over it) or a Blue Tinted M4 (blue al over it).
My question is how can I do that, how is that possible? I will +rep for any answer. Thanks.!
Reply
#2

I believe that he is replacing the real weapons with the weapons objects, and he is using SetObjectMaterial to change the colors take a look at the last parameter "material color" thats only in the shop, and about he can hold in his hand he is just using SetPlayerAttachedObject it also can change the color , i will try to make some and post the results, i might create a filterscript for this also if it worked!
Reply
#3

Thank you, I will +rep you...also, when you make it, can you PM me or post the result here, please?
Reply
#4

It worked for me, its not accurate at all i just wanted to test if it will work or not,
output:

if you would like to check it: here is the codes:
pawn Code:
public OnPlayerSpawn(playerid)
{
    GivePlayerWeapon(playerid,24,1000);
    SetPlayerAttachedObject(playerid,0, 348,6,0.007000 ,0.004000 ,-0.011999 ,8.599973 ,0.000000 ,0.000000 ,0.940000 ,1.354999 ,1.286999,0xFFFF0000,0xFFFF0000);
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)