playMaker

Author Topic: Dialogue System  (Read 12663 times)

ZeroSigma

  • Playmaker Newbie
  • *
  • Posts: 7
Dialogue System
« on: November 12, 2012, 06:43:04 AM »
Is it possible to do a complex dialogue system in playMaker? Can it handle logical branching? Example can the FSM execute a logical statement and according to the result move to a new state; effectively choosing one that was attached to it?

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Dialogue System
« Reply #1 on: November 12, 2012, 07:39:14 AM »
Hi,

 This is actually where PlayMaker excels to be honest. logical branching becomes a brease because you can visually describe your dialog logic, AND as the game is running see where the logic goes, and debug it when paused ( stepping back in time logical steps to see from where a particular state transited to, etc etc)

bye,

 Jean

FractalCore

  • 1.2 Beta
  • Full Member
  • *
  • Posts: 100
Re: Dialogue System
« Reply #2 on: November 15, 2012, 01:24:58 AM »
If I could ask a follow up question. I'd like to try out a dialog system in Playmaker. The branching is the easy part, another question might be how would you store/display the actual text;

Playmaker strings?
GUI text?
text file?
some kind of script?
a sequence of images that have the text "baked in"?

These are ideas I've thought up but they're either hard to implement or not ideal. Is there a nice easy way that allows for big blocks of text that can be changed easily at any time? eg. GUI text will easily do one line of text but not multiple lines. As far as I know. As a non-programmer :)

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Dialogue System
« Reply #3 on: November 15, 2012, 02:10:25 AM »
Hi,

 All text, assets can be stored using ArrayMaker or a Sqlite database framework ( yes, I am on the case, coming soon for playmaker :) )

You could also have it defined in XML ( I am also working on that) and then query using xpath to get to a reference for an asset or simply a string.

You can also do it all within the Fsm hardcoding the content their.

Do you have a use case so we can see how far you are willing to take this?
 
 bye,

 Jean

FractalCore

  • 1.2 Beta
  • Full Member
  • *
  • Posts: 100
Re: Dialogue System
« Reply #4 on: November 15, 2012, 11:39:31 PM »
Yeah, I thought a database would be the answer. Databases are one of those things I've heard are useful for games, but Unity doesn't come with one and there's some available but they aren't free. So I just haven't had a chance to experiment, and haven't committed enough to purchase... Excuses, in another words :)

I also want to try an inventory. I've thought of how I'd do a simple one with just a collection of Playmaker variables that I save. But I know, to do it right you need a database.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Dialogue System
« Reply #5 on: November 16, 2012, 02:33:43 AM »
Hi,

 it really depends your need, you might be able to get away with just ArrayMaker or XmlMaker ( cooking at the moment) which allows you to do powerful search in xml to get to a particular node content.

bye,

 Jean

Drunkenoodle

  • Playmaker Newbie
  • *
  • Posts: 25
Re: Dialogue System
« Reply #6 on: November 16, 2012, 04:41:47 AM »
Just stepping in here also (if it's not too late), this is also something that I'm looking into. Been pestering Jean quite a bit about it so if you fancy having a chat about it or general discussion, give me a shout. Might be cool to share some ideas.

Got some prototypes on the way so when they're done, I'll swing them this way if you like!

Cheers guys,
-D

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Dialogue System
« Reply #7 on: November 16, 2012, 05:41:47 AM »
Hi,

 yes, you are always welcomed  to share and participate :)

bye,

 Jean

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Dialogue System
« Reply #8 on: November 16, 2012, 07:31:25 AM »
Hi,

 ok, Xml is now accessible within PlayMaker, it's very much the beginning of it, but it might be suitable for what you want already as is.

http://hutonggames.com/playmakerforum/index.php?topic=2583.0

bye,

 Jean

Drunkenoodle

  • Playmaker Newbie
  • *
  • Posts: 25
Re: Dialogue System
« Reply #9 on: November 16, 2012, 12:02:20 PM »
Jean,
You're the best. Just sayin'. ;) Great job, going to have a play around with this over the weekend and shall relay back the results.

Thanks very much again for all your hard work! :)

- D

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Dialogue System
« Reply #10 on: November 16, 2012, 01:42:11 PM »
Hi,

 you are welcome, I am really having fun doing them small tools. And the potential is huge with this xml, I can import from csv, json, database, from resources or from online queries and then simply serve it with Xpath great power and flexibility. The ability to also edit and save the xml will be good too.

bye,

 Jean

kenuab

  • Playmaker Newbie
  • *
  • Posts: 10
Re: Dialogue System
« Reply #11 on: November 28, 2012, 06:41:39 PM »
FYI: if you need something easy right away try speechbubble for playmaker (in the unity store).  We've been using it for complex dialogue trees and have found it works great. 

Ken