Re: STRING_TABLE

31 views
Skip to first unread message

drac...@aim.com

unread,
Sep 11, 2012, 11:50:56 AM9/11/12
to project...@googlegroups.com
I see that Edmund Horner replied to me instead of the list. The essential bits of a long pair of letters are:

STRING_TABLE is pretty much just a list of strings.  For conversations
it can optionally have strings for the sound files to play for each
phrase, and for the times to play them.

What you want to do is load the conversation file into a STRING_TABLE,
set CommData.ConversationPhrases to point to the actual strings in it,
and run the conversation, providing references to the strings by their
index into that string table.  This is exactly what it looks like
you're doing.

The problem is that little undocumented feature in which if you have N entries in a string table,
if that STRING_TABLE has certain bits set in its flags field, then
then after those N entries you also have N entries for the timestamps (which isn't that hard)
and N entries for the names of the voice files (which I haven't been able to track down the format of).

Now, I thought that I had those bits set to FALSE so that it wouldn't try to find timestamps or voice files,
but it seems that my setting those bits to FALSE is overridden somehow, so it crashes when trying to find things.

This could be due to either:
after I give the comm code my STRING_TABLE, it thinks it has to initialize it further, or
I messed up giving it my STRING_TABLE and it's actually using its own STRING_TABLE

I'm pretty sure the conditional check isn't broken.

Also, he briefly showed me how to use the resource system so I can load it properly. This might do the job.

Luke

On Sep 11, 2012, at 5:01 AM, Benjamin Wack wrote:

Hi,

I've seen Luke's message, I was going to answer and then I realized I was fooling myself, I don't have time to do this right now.
So yeah, alive, life's definitely in the way. I'm starting a new job this month and I'll most certainly be drowned in it until January. The good news is that afterwards I'll probably have a lot of free time on my hands.
Anyway, do tell us what you need the STRING_TABLE structure for and maybe one of us will feel the need to slack off from real work some day soon and help you with it.

Cheers,
B.


On 09/11/2012 01:42 AM, Damon Czanik wrote:
Greetings programs!

I hope you guys are doing well. I have a programmer question, and would just like to see where the status of it is.

Death 999 posted something in the forums: If a programmer can help me decipher the data format of the STRING_TABLE data structure as it's used in conversations, and track down how it's disposed of, that would help

Soo, I was just wondering if any of you fine gentlemen could help? As I recall the game just crashes right now, correct? So (please correct me if I'm wrong), the game is currently broken.  Also, how are you guys doing?  I hate to be the annoying guy, but I haven't heard from any of you.  I'd hate to think the project we've all worked so hard on is dead. I know life gets in the way, so if you are busy, that is fine. If you could just let us know you're alive that would be awesome :-)  I miss hearing from you.


Take care guys! :-)





Edmund Horner

unread,
Sep 11, 2012, 9:16:27 PM9/11/12
to drac...@aim.com, project...@googlegroups.com
I only have the checked in code to look at in
http://code.google.com/p/project6014/source/browse/trunk/sc2/src/uqm/conversation.c.
I assume we're talking about parseConversationModel.

out->table->flags doesn't get set at all here.

A related problem is you're setting out->table->strings starting at 1
instead of 0.

So are these problems also present in the code you're working on?

It's probably worth adding some log code to show which strings have
been populated into each index in the table, before returning it.
Reply all
Reply to author
Forward
0 new messages