Jump to content

Changing hair textures


You are about to reply to a thread that has been inactive for 3073 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

Hello:) I have a problem that I hope someone knows the solution to. I have started to get really into making hair and experimenting with it. But the thing is I would like to be able to make several different colors of it. The way I am doing it now involves replacing each and every texture by hand (or at least by mouse) Its very tiresome and if you also have alpha textures it starts to get really annoying. Then I started thinking if I couldnt geta texture changing script and change the textures that way...but the thing is.. I feel its very complicated to do! Maybe I am just dense but these scripts are very confusing to me. Is there a simpler script that can accomplish the thing I want to do or some easier way I would be happy to know it. Maybe this one is for the scripting forum but I feel its more about building so please help.
Link to comment
Share on other sites

So long as you are simply needing a tool for your own convenience while you are creating the hair, you don't need a fancy script.  All you need is something like this (off the top of my head and untested, so try it on a backup copy first) .......

// 1. Put this script in your multi-prim object// 2. Drop a texture into the object's Contents.//       The script will put the texture on all faces of all prims in the object,//       and will then delete the texture from the object's Contents.// 3. Repeat step 2 if you want to change textures again.// 4.  When you have finished, left-click the object to delete this script.default{	state_entry()	{		integer i;		while (i < llGetNumberOfPrims() )		{			llSetLinkTexture(i,llGetInventoryName(INVENTORY_TEXTURE,0),ALL_SIDES);			++i;		}		llRemoveInventory(llGetInventoryName(INVENTORY_TEXTURE,0));	}		changed (integer change)	{		if (change & CHANGED_INVENTORY)		{			if (llGetInventoryNumber(INVENTORY_TEXTURE))			{				llResetScript();			}		}	}	touch_start(integer num)	{		llRemoveInventory(llGetScriptName() );	}}

 Don't forget to left-click the hair to remove this script before you give the hair to someone else.

Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 3073 days.

Please take a moment to consider if this thread is worth bumping.

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
 Share

×
×
  • Create New...