Page 1 of 1
Unic?
Posted: Thu Aug 16, 2007 9:54 am
by turk645
OK i have a few ideas for my main menu but there is just one thing stoping me, the unic tag. I can only use certain strings from a unic for text for options and what not and i wan to know if its possable to add more strings to a unic so things like spawn times can have proper lables.
Posted: Thu Aug 16, 2007 2:33 pm
by xzodia
correct me if im wrong but the unic points to strings in the string table in which cause you cant add strings but you can reuse unused strings
Posted: Thu Aug 16, 2007 2:43 pm
by Prey
Append your extra strings to the bottom of the string table, then link'em. Don't think any released program has that ability though.
Posted: Thu Aug 16, 2007 11:30 pm
by shade45
Prey wrote:Append your extra strings to the bottom of the string table, then link'em. Don't think any released program has that ability though.
Nah it wont work you need to add the string at its proper location in the unicode table then update the [unic] tag that points to that section of the table to include the new string. you would also have to shift the offsets in every other unic tag after the one you updated to make up for the added space.
Posted: Sat Aug 18, 2007 8:56 am
by turk645

so i have no chance of getting new strings in a unic or linking strings from another unic into the one i need?
Posted: Sat Aug 18, 2007 9:00 am
by neodos
turk645 wrote:
so i have no chance of getting new strings in a unic or linking strings from another unic into the one i need?
Yes you'll have to do a cheap knock off

Posted: Sat Aug 18, 2007 9:31 am
by Prey
Yea your right shade, each unic points to only a block of strings, so instead of appending you would have to do some inserting
Your not completely out of luck turk. If you first go to the end of the english unicode table and count up the space(padding) to the beginning of the next unicode index(if your not sure where it starts just check the uberanalyzer), then go to the end of the block of strings referenced by the unic tag in question, and add your string in (making sure you don't go over the size of the padding you just counted), and then go back to the padding and delete the length of the string you just wrote, then go to the english unicode index and add your string offset in the table to the end of it (overwriting the index's padding), and then go into entity and through every unic tag and if it's english offset is larger than the unic tag your editing, increment that offset by the length of the string you just inserted.
Not really that hard to do, your only problem is there may not be much padding

..gl anyway

Posted: Sat Aug 18, 2007 9:39 am
by turk645
havent even looked yet but i can already guess there isnt enough for what i want to do cause i need to add several new strings to the unics used for gametype options so there are things like 0 second arm time on assault bombs and what not with proper lables.
Posted: Sat Aug 18, 2007 10:09 am
by Prey
True, the most padding you'll ever get is 511 bytes, and thats being optimistic.
What you could do though is find the last string in the block that is referenced, open up Blu and find that string, add in a bunch of spaces, then back in hex overwrite the spaces with your new strings, insert the offsets into the english index, delete away the padding of the index that you 'overwrite' (as in one offset takes 4 bytes, so subtract 4 bytes) and then increase the english string count in the unic tag your editing by how many you entered (forgot to mention that part before).
EDIT: You'll have to go through the unic tags and fix their offset if its larger again as well actually, Blu doesn't do that so you'll have to increment by the number of spaces you added.
Your only problem though is there may not be enough padding at the end of the english index to fit all the new offsets. GL again though

Posted: Sun Aug 19, 2007 8:38 am
by OwnZ joO
Have you used up all of the unicode strings already? I mean there are a lot of them that have to do with Live aren't there, and I'm guessing most people won't be using live with your mainmenu.
Posted: Sun Aug 19, 2007 12:28 pm
by turk645
you dont understand the issue. Some strings are links to specific UNIC's. The live ones arent part of the game varient unic so i cant use them.
Posted: Sun Aug 19, 2007 3:05 pm
by OwnZ joO
I guess I didn't think of that, it makes sense.
Posted: Sun Aug 19, 2007 3:13 pm
by Prey
Well I guess you could delete the unneeded string, insert a string with the same char count in the block referenced by the unic tag, fix the other unic's, and the unicode index, and your good to go.
Posted: Sun Aug 19, 2007 3:47 pm
by xzodia
Prey wrote:Well I guess you could delete the unneeded string, insert a string with the same char count in the block referenced by the unic tag, fix the other unic's, and the unicode index, and your good to go.
that sounds like that kinda thing that needs an app really
Posted: Sun Aug 19, 2007 4:18 pm
by turk645
yes cause i didnt understand what you said at all.