SetObjectMaterial() Help
#1

Hello friends,
As you see in my pictures, i added new walls on LSPD parking place. Now i want to change the texture of the new walls to those which near, but how can i get the tecture lib if i know only object id?

Код:
new Float:X, Float:Y, Float:Z;
new myobject;
GetPlayerPos(playerid, X, Y, Z);
myobject = CreateObject(19392,...);
SetObjectMaterial(myobject, 0, 3975, "???", "???", 0xFFFFFFFF);
Reply
#2

By using another map editor (MEd) that supports the viewing of the TXD. The one you want is probably this one;
Reply
#3

Oh thank you man, you are fastest!
Reply
#4

Nothing changed, what i did wrong?
PHP код:
new object1;
object1 CreateObject(193921539.64795, -1619.4659414.17000,   0.000000.000000.00000);
SetObjectMaterial(object103975"lanbloke""bow_concrete_drip"0); 
Reply
#5

Try different materialindex (1,2...all)
Reply
#6

I set materialindex until ...21, but nothing changed.
Reply
#7

I tried your code and it works fine i think.
Reply
#8

Quote:
Originally Posted by Vince
Посмотреть сообщение
By using another map editor (MEd) that supports the viewing of the TXD. The one you want is probably this one;
Well, I might be completely wrong: But couldn't you see it when you double click a object (JerneL's map editor).
Reply
#9

Quote:
Originally Posted by davve95
Посмотреть сообщение
Well, I might be completely wrong: But couldn't you see it when you double click a object (JerneL's map editor).
You're right. As you can see the "Texture" and the box even includes other information related to the object.

Reply
#10

Quote:
Originally Posted by davve95
Посмотреть сообщение
Well, I might be completely wrong: But couldn't you see it when you double click a object (JerneL's map editor).
Never mind I got what you meant now.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)