PDA

View Full Version : Material text


Ectazy
25/01/2013, 04:40 PM
Hi all, I have 152 objects, i want to change material text. Do I have create 152 lines with SetObjectMaterialtText fucntion?

Roach_
25/01/2013, 04:44 PM
Well, yes!
Or if all your object will have the same MaterialText, use a loop..

Ectazy
25/01/2013, 04:57 PM
Yes, I want to change the same MaterialText. Can you give me example?

Ectazy
26/01/2013, 11:40 AM
Up..

IgrexolonO
26/01/2013, 11:42 AM
for(new i = 152; i < ANIM_LIMIT; i++)
{
SetObjectMaterialText(myobject[i], "SA-MP {FFFFFF}0.3{008500}e {FF8200}RC7", 0, OBJECT_MATERIAL_SIZE_256x128,\"Arial", 28, 0, 0xFFFF8200, 0xFF000000, OBJECT_MATERIAL_TEXT_ALIGN_CENTER);
}

Threshold
26/01/2013, 01:01 PM
for(new i = 152; i < ANIM_LIMIT; i++)
{
SetObjectMaterialText(myobject[i], "SA-MP {FFFFFF}0.3{008500}e {FF8200}RC7", 0, OBJECT_MATERIAL_SIZE_256x128,\"Arial", 28, 0, 0xFFFF8200, 0xFF000000, OBJECT_MATERIAL_TEXT_ALIGN_CENTER);
}

Err what? Why would you be starting at 152 and going up? And what's with the ANIM_LIMIT? 0_o

for(new i = 0; i < sizeof(myobject); i++)
{
SetObjectMaterialText(myobject[i], "Your text here...", 0, OBJECT_MATERIAL_SIZE_HERE, "fonthere", 28, 0, 0xFFFFFFFF, 0xFFFFFFFF, OBJECT_MATERIAL_TEXT_ALIGN_HERE);
}
Just make sure you add the objects into an array, then replace the parameters with your own standards accordingly.

Ectazy
26/01/2013, 02:12 PM
Thanks!