Update of /cvsroot/pythianproject/PythianProject/Source/Conversation/Editor In directory usw-pr-cvs1:/tmp/cvs-serv23470/Conversation/Editor Added Files: Branch1.bmp Conversation1.bmp ConversationEditor.cfg ConversationEditor.dof ConversationEditor.dpr ConversationEditor.res Delay1.bmp Jump1.bmp NPCResponse1.bmp NPCSpeech1.bmp PlayerOption1.bmp Script1.bmp groupClosed.bmp ignore.bmp mainWin.dfm mainWin.pas notes.txt test2.cml Log Message: Adding conversation stuff -mike --- NEW FILE --- BM6 --- NEW FILE --- BM6 --- NEW FILE --- <convdata><conversation name="Test conversation"><playeroption id="1">Hi there! How are you doing? test test 1 2 3<npcspeech id="4">Fine thanks. You?</npcspeech><playeroption id="5">Oh not bad thanks.<npcspeech id="8">That's welcome news. Now listen, I've got something to tell you.</npcspeech><jump id="23" to="21"></jump></playeroption><playeroption id="6">Actually not to good recently.<npcspeech id="7">Really? That's too bad. Anyway, listen carefully.</npcspeech><jump id="24" to="21"></jump></playeroption><group name="Joke Group" id="21"><npcspeech id="22">I've got this totally great joke to tell you!</npcspeech><playeroption id="27">Groan!<jump id="30" to=""></jump></playeroption><playeroption id="28">Go on then, shock me.<npcspeech id="29">Here we go then - What is the largest species of mouse in the world?</npcspeech><playeroption id="35">I don't know. What is the largest species of mouse in the world?<npcspeech id="36">A hippopotamouse!</npcspeech><playeroption id="37">That's pathetic.</playeroption><playeroption id="38">That's rubbish.</playeroption><playeroption id="39">That's ****.</playeroption></playeroption></playeroption></group></playeroption><playeroption id="3">Hey you - what are you doing here?<npcspeech id="12">Well if you're going to be like that I'm off!</npcspeech><script name="NPC Leaves" id="13">test script</script></playeroption></conversation><conversation name="Explanation Conversation"><npcspeech id="47">Welcome to the demo conversation :)This will show you the features of the conversation engine, and demonstrate how it works and how conversations are designed. This node is an NPC node, meaning that the character to whom this conversation is with would speak it.A conversation is organised like a tree. The interpreter runs each node in turn, starting with the top and working downwards. Here, this is spoken first, and when that is done the player options a, b and c are shown.</npcspeech><playeroption id="48">This is player option (a). The player can choose this option from a list of options that are displayed when the interpreter runs this node. If the player chooses this the options children are run. When a player option node is run, all available options are cleared.Options have two flags: "force select", which means the player -must- select that option, and "disable-on-run" which if true means that the option can only be selected once.<npcspeech id="52">This is an NPC speech node. It is run (and the speech spoken) if the player selects option (a).</npcspeech><delay time="1000" id="53"></delay><npcspeech id="54">This NPC speech is run 1 second after the first. Because nodes are run in order, you can implement several neat features like this.After this node is run, control moves immediately back up a level and the player options (b) and (c) are run. In fact, all the options are processed, but when an option is selected, it is marked as "done", and therefore not readded. When control is returning up a level, only player options are run, no others are.</npcspeech></playeroption><playeroption id="50">This is player option (b) The player can also choose this option. This node is run immediately after option (a), so the player sees the options appear virtually at the same instant.<npcspeech id="55">This is another NPC speech node. It is run when option (b) is selected.</npcspeech><playeroption id="56">This is another option (b-a). It is run when option (b) is selected by the player. If a set of children contains player options then execution halts when control is about to return up a level. This allows the player to select an option. Execution only returns to the parent level once all the player options marked "force select" have been selected. The force select flag means that the player has to choose the option before execution can return. For instance, if an option is chosen and it contains 3 other options, all with force select = true then the player must say all three things before he can go back. However, if none of them have force-select then the player can only choose 1 of them. However, the rest of the options will then be impossible to select. Force select is currently not editable.<groupenable id="72" target="68"></groupenable><npcspeech id="76">If the player sees this npc speech then the group has been enabled. That means that if the player selects option (b) then (c), they get extra options.</npcspeech></playeroption><npcspeech id="57">This node will be run immediately after the player chooses (b). However, after this node execution will stop, until a player option has been selected.</npcspeech></playeroption><playeroption id="51">This is option (c) Like the others the player can choose this at the beginning of the conversation.<npcspeech id="67">This is a response to the user selecting (c). The following nodes are in a group.</npcspeech><group name="Explanation Group" id="68"><playeroption id="69">This option is in a group. By default groups are enabled, and when execution reaches a group it passes into it without hesitation.If a group is disabled (groups can be enabled/disabled with commands) then execution may or may not pass into it. However, it is perfectly possible to jump into a group that is disabled. Groups are -not- automatically run when enabled.</playeroption><playeroption id="70">This option is also in a group. These options will only be available if the player has first selected option (b)</playeroption><jump id="81" to="80"></jump></group></playeroption><groupdisable id="78" target="79"></groupdisable><group name="Misc Group" id="79"><npcspeech id="80">This will not be run at first, because it's in a group that's disabled. However, the group can be used to store various nodes that are jumped to later. When something is jumped to, it is treated like the jumped nodes are added where the jump command is. This is to preserve context.</npcspeech><playeroption id="82">This option will appear alongside the other two before the jump, because these nodes will appear to be where the jump command is.</playeroption></group><npcspeech id="88">New NPC Speech</npcspeech></conversation></convdata> |