![]() |
Wraptext 2?
Wraptext 2, in GS1, I understand how it works.
Instead of tokens (gs1), can it read directly from the string you are wraptext2-ing now in GS2? I need to wrap multiple strings (text), but I don't want to use the same tokens over and over again. (I'll show an example later if people are unclear of what I am talking about.) I've got a HUD/GUI scripted in GS1 that works pretty well, I just can't go any further because I can't wrap but one string because it reads the wrapped text as tokens. |
Are asking if 'wraptext2' in GS2 can return to something else other than tokens?
|
Assign the tokens to an array. Example:
PHP Code:
|
Quote:
Anyways, The problem with using tokens for wraptext2 for what I am trying to script is I am doing this: Wraptext2 this1string. (examples only) Wraptext2 this2string. I am trying to place this1string in a certain position (there's no set# of letters/pixels it will be.) And I am trying to place this2string at another place. The problem with this is, with the for loop, it checks tokens [ for (this.i=0;this.i<tokenscount;this.i++) ] to display the text properly as well as wrap. I can get one string to wrap, but the second string shows up the same as the first, and there is no way that I can think of to determine the separate strings' token #'s. Understand better now? Anyways, I was informed that in GS2 the strings are set to arrays instead of tokens, so that they could be accessed better. (strlen i think? for the array in the foor loop.) so that it would display the correct text. True? |
Ok, I think I know where you are getting at (correct me if I am wrong). You want to wrap the text of two separate strings, but want them put into separate string arrays? If so, GS2 makes that super easy.
PHP Code:
|
Quote:
I had been told GS2 made it super easy because the problem had been ran into in the past. So...now all I have to do is convert my whole GUI to GS2. :) yay. |
the only problem I am having now is trying to display it in a showtext.
NPC Code: and later -> NPC Code: That could be horribly wrong, but I don't know much about the whole object system and how I would access the text I've wrapped.. Also, index is set to 1 for testing purposes only. I haven't assigned it an index yet. |
use:
PHP Code:
PHP Code:
|
sorry for double posting, but I was wondering if there was a max amount of characters that could be held in a string? Or displayed using wraptext2 ?
It seems like it cuts out half of the string when it wraps the text. |
2 Attachment(s)
Here are screenshots of my problem.
First SS: Both strings display properly, but they aren't maxed out to where they would have to wrap and display both beginning of the string and end. The string on top is: client.questtitle=This is a test to see if all of the stuff is working right. aaaaaaaaaaa bbbbbbbbb Second SS: The bottom string is still displaying properly, but when I add more text for the wraptext2 to wrap, it WRAPS the text correctly, but it takes away the text above it. Portion I am using to display the text: NPC Code: Would it be anything wrong with the way I am wraping the text? NPC Code: |
Quote:
(Yours isn't matching). |
Quote:
|
Quote:
PHP Code:
|
Quote:
Quote:
|
| All times are GMT +2. The time now is 04:31 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.