Jump to content

String + Text = Vector(Name)


Killi Cloud
 Share

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

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

Recommended Posts

Maybe it's just getting late and google does not like me, but I am currently trying to use llGetsubstring to get the letter from a string and then add to a vector name.


May not make sence, so here...

vector texta = <0.0, -0.0, 0.0>;

string words = "abc";

(vector)text + llGetSubString((string)words, 0, 0) // THIS LINE NOT WORKING FOR ME

 

How would i go about doing this or am i doing it all wrong?

 

(This is so i can change the texture vector baced on string without each texture change every time i make changes)

 

 

 

Link to comment
Share on other sites

It's a bit unclear what you're attempting but if you're trying to dynamically change the name of a variable, that can't be done.

 

If you're wanting to use different textures according to a letter in a supplied string, extract the letter into a string variable and then use an if else chain to set a variable to the one you wish to display.

Link to comment
Share on other sites


Killian Jayaram wrote:

Problem from when i come from PHP and JS the rules change, I will try making the vector to a list and output based on string and see if that works nay better as if and else make this to long and to much of a lag.

I feel that would be an excellent approach to the problem! I wish you good luck in implementing it and if you encounter any problems with it, just ask.

  • Like 1
Link to comment
Share on other sites

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

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

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...