The Daily Click ::. Forums ::. Klik Coding Help ::. Muz's continued conversation problems
 

Post Reply  Post Oekaki 
 

Posted By Message

Muz



Registered
  14/02/2002
Points
  6499

VIP MemberI'm on a BoatI am an April FoolHonored Admin Alumnus
26th September, 2003 at 10:49:30 -

After fooling around with this conversation editor thingy, I've decided that the best way would just be to make it in a text file or some other data file instead of INI or arrays.

I could go on and on about why I think so, but I'm a bit short of time. Here's a little explaination of what I'm trying to do.

Every line in the text file goes along this format:
(command) (id no) (goto/command 2) (command 3) (anything else...)

Example: /res1 00001 00002 x Hello.

List of commands:
/tnam Name of talking character
/ssay What the talking character said
/res1 Response choice 1
/res2 Response choice 2
(and so on with those /res stuff)
/strt Start (the first line the engine checks)
/end End (causes the conversation to end)
/req Used when a requirement check is needed

The /req command is a special case. It's uses a different, custom format, depending on the list. It's used in case checks need to be made to see the character's stats, if he has enough money, etc. It doesn't really have a format but for this example, it's...
/req (character who's being checked) (minimum amount of gold)

And the commands don't have to have that slash... I'm just used to slashes in front of commands.

That goto thing is used to tell which id number the engine should go to as soon as the player clicks on a number. The command 3 really has no purpose, but its there just in case I need to put something else in. It's more of a temporary data storage thing.

Here's an example of the player conversing with Bill, a friendly shopkeeper. The player can choose to respond by running away, responding to the greeting, or making a purchase. If the player chooses to make a purchase, he'll do one of those requirement checks.
/strt 00000 00001 x x
/tnam 00001 x x Bill
/ssay 00001 x x Greetings. How are you today?
/res1 00001 /end x Leave me be! [Runs away]
/res2 00001 00002 x I am fine!
/res3 00001 00003 req1 I wish to make a purchase.
/tnam 00002 x x Bill
/ssay 00002 x x Very well then. Goodbye.
/res1 00002 /end x Bye. [end]

/req1 characterA 1

/tnam 00003 x reqyes Bill
/ssay 00003 x reqyes Choose what you want to purchase
/res1 00003 /end reqyes I don't want anything.
/tnam 00003 x reqno Bill
/ssay 00003 x reqno You don't have enough money.
/res1 00003 /end reqno Bye. [Leaves]


So... there it is, my whole plan on the conversation editor thingy I was working on. Too bad my comp died before I had the chance to put it to the test. So... now I'm wondering, are there any flaws in this design? I'm thinking that it may be possible through proper use of the Tokens object & Rich edit object. But... well, anyone wanna try it while my computer's away?

BTW, the title's supposed to be Muz's continued conversation editor problems. I apologize for the typo. Can't seem to find anything that edits the topic name.

Image Edited by the Author.

 
Disclaimer: Any sarcasm in my posts will not be mentioned as that would ruin the purpose. It is assumed that the reader is intelligent enough to tell the difference between what is sarcasm and what is not.

Image

Muz



Registered
  14/02/2002
Points
  6499

VIP MemberI'm on a BoatI am an April FoolHonored Admin Alumnus
4th October, 2003 at 08:53:06 -

Uh, maybe I missed it out somewhere, but where did you put that idea?

 
Disclaimer: Any sarcasm in my posts will not be mentioned as that would ruin the purpose. It is assumed that the reader is intelligent enough to tell the difference between what is sarcasm and what is not.

Image

Kris

Possibly Insane

Registered
  17/05/2002
Points
  2017
4th October, 2003 at 09:17:45 -

SOMEBODY MAKE A CONVERSATION EXTENSION

 
"Say you're hanging from a huge cliff at the top of mt. everest and a guy comes along and says he'll save you, and proceeds to throw religious pamphlets at you while simultaniously giving a sermon." - Dustin G

Shawn Wolfram



Registered
  15/08/2003
Points
  435
4th October, 2003 at 09:19:52 -

SOMEONE TELL ME WHAT THIS IS. Really, I wan't to learn, not to sound like a noob or anything... oh crap I am one, now I have to realease some games... brb.

 
http://www.myspace.com/gidek = Myspace is for fags.

<fag?
   

Post Reply



 



Advertisement

Worth A Click