The Comprehensive Dialogue Guide (1 Viewer)

Slingerbult

Content Creator
Joined
Sep 15, 2012
What's This?
This is a guide for writing your own SDT dialogues. Custom dialogues come in very different levels of complexity, from a few simple lines of spoken text to complex hypnotic adventures, from interactive eroge mini-games to fully automated hentai scenes. Your imagination is the only limit, but it is best to start small! In this guide, I'll go through both the core functions and share my own tips as a dialogue writer on how to make things run more smoothly.

Before We Begin...
First off, a caveat. Resources like these need continous updating since the core game and Loader mods are developing at such a rapid pace, and I'm not sure I'll be able to fulfill that long term. If I'm gone from the forum for several months or more, check out this thread for updates not included in the OP. Or check out the latest dialogues from some popular dialogue writers who are probably using the latest tech. If you have problems with your dialogue, please check the troubleshooting section below before asking for help in this thread.

I've tried to incorporate the wisdom from old threads in this new guide, but in case you're interested in previous dialogue tutorials, check out these threads:
EO's original dialogue guide from 2011
Kona's thread on custom variables

Table of Contents
1. What You'll Need
2. Lines, Triggers, Conditions and Variables
3. What to Use and How
4. Troubleshooting

What You'll Need
There are basically two ways to make a custom dialogue - using the in-game editor or a text editor, such as Notepad. DO NOT WORK IN A WORD PROCESSOR AT ANY POINT. It will ruin everything with auto formatting that's hard to remove or disable. Using the in-game editor can be a good way for some to learn the basics, but this guide assumes you're writing everything from scratch in a text editor, which is the way most dia writers do it.

So make a new .txt file and enter these lines at the top:
all:"CLEAR"
dialogue_name:"name"

And of course change "name" to whatever you want to call your dialogue - ideally, the same thing you named the .txt file. The CLEAR command clears whatever dia the game may have loaded previously. Now you're ready to add your dialogue!

If you want to go beyond this guide as far as dialogue scripting is involved, check out the Loader and in particular gollum's DialogueActions mod (eventually, its extra features will hopefully be included in the core game). But first learn stand, then learn fly, Daniel-san...

Lines, Triggers, Conditions and Variables
This section goes through a few fundamental concepts that it helps to have a basic understanding of to avoid unnecessarily banging your head against the wall. See the spoilers below for a complete listing or lines, triggers, conditions and variables.

A line always has a specific type that determines when the Her or Him model will say whatever it is you've typed. For example, an intro line will be spoken before he deepthroats her and never after, and a head_grabbed line will only be prompted when her head is grabbed. If you have several lines with the same name, one will be chosen randomly at the appropriate time (you can micromanage the order by using custom variables and conditions, see below). You can even make up your own line types from scratch, like so:

custom:"This is a custom line."

All lines share this basic format of type + colon + line within quotation marks. A line will fail unless formated like this. However, since the game doesn't know when it's supposed to use this custom line, you will have to call it up yourself in some other line through a trigger. A trigger causes something to happen in the game and is usually typed in capital letters within brackets, for instance [ARMS_LEGS] moves her arms to her legs and [HOLD] makes him grab her head. You call a custom line by using it as a trigger in another line:

intro:"I will now speak a custom line. [custom]"

This will cause the custom line to be spoken immediately after the intro line has been spoken in its entirety (it doesn't matter where in the line you put the [custom] trigger). If you want to substitute a word or short phrase INSIDE a line, you'll need to use a variable instead. More on that below. There's actually another way to call a custom line after a standard one, and that's using something I like to call conditions. Conditions are used to check, set or change a standard or custom variable, in order to modify a line, only display it during certain circumstances, or changing something behind the scenes when it's called. Conditions are always within wavy brackets at the end of a line, like so:

intro:"I will now speak a custom line." {"next":"custom"}

"Next" conditions that the next line to be played immediately after this intro line will be the line called custom. It doesn't really matter if you use a trigger or a condition to call your custom lines, the result is the same. Another very important use for conditions is to define the style of a line, that is if it's spoken by her or him, or if it's a thought line. Thought and him lines have the benefit of triggering even if her mouth is occupied, which is something I'll get back to in a bit.

There are a few hidden variables within the game that you can set in various ways. One is mood, which can be set via dialogue by triggers such as [HAPPY_MOOD] (or via Options menu). The four moods are also conditions that can be checked so that a line conditioned {"mood":"Happy"} will only play if her mood is indeed happy. Similarly, lines can be conditioned based on his arm positioning (whether he's holding her or not). Variables can also be called mid-sentence by using asterisks, like so:

intro:"Hey* YOU*, this is an intro line."

YOU is a hidden variable that substitutes whatever you've entered as your name in the Options menu. Note that you can include other characters like commas and spaces between the asterisks, so if you haven't entered a name, the above line will simple play like "Hey, this is an intro line." *ME* works the same way but uses the Her model's name as specified under charName in Her character code. YOUR and MY works similarly.

FINISHES is another hidden variable that automatically increases when the Him model cums, so that whenever this variable is called, the appropriate line will be displayed. This can be immensely useful in creating a progressive dialogue. Though you could accomplish the same thing through custom variables, using finishes makes it easier by using a mechanism already hard coded into SDT.

Setting and checking your own custom variables is a more advanced form of dialogue coding that let's you micromanage how the dia will progress. You make up a variable, decide when it changes and can condition lines to played only when it has a certain value. This is coded like a "condition within a condition", like so:

intro:"Hey* YOU*, this is an intro line." {"set":{"intro":"true"}}

This sets the variable intro (which you just made up) to true, telling the game that this intro line has now been played. This can then be used to condition other lines, perhaps intro lines, to only be played when intro is true, that is after this first line has been played, by using check rather than set:

intro:"This is a second intro line, played only after the first." {"check":{"intro":"true"}}

The variable can be a number or string, depending on what's preferable. DO NOT attempt to set and check the same variable in the same line condition, it won't work so you'll need to use several lines to accomplish this. More on using custom variables below, this is just to introduce the concept. If you use custom variables, you can set their initial value when the dialogue is loaded like so:

initial_settings:{"variable1":0,"variable2":"false"}

The formating when using wavy brackets and setting variables is quite important. You can't stack sets of wavy brackets after each other, but must use a comma instead, as per the example above. Also note that straight numbers are without quotation marks, but you must use quotation marks as soon as a non-numerical is part of the variable's value. Many more examples will follow below and hopefully clear this up. The following spoilers list all the available lines, triggers, conditions and variables for easy reference:

//These line types play only before first deepthroat.
intro - When idle, this will trigger eventually.
resistance - When going down far enough and encountering resistance.
first_throat - As with resistance, but requires more force to get down deep enough.
first_dt - What she says on the first full deep throat when her resistance is gone.
//These line types play only after first deepthroat.
general -When idle, this will trigger eventually
vigorous - Triggers from fast and deep throat fucking
pull_off - Triggers often, typically when sliding off the cock or pulling her off.
held - When held down through spacebar/mouse.
//Cum-related lines.
pre_cum - Triggers when your screen does that white, flashy thing before he cums.
cum_on_face - When he comes on her face.
cum_in_mouth - When he comes in her mouth.
cum_in_throat - When he comes in her throat.
cum_in_eye - When he comes in her eye.
cum_in_nose - When cum squirts out from her nose, due to the cock being inserted at the appropriate depth when cumming.
restart - When you continue after ejaculating.
//These line types always trigger when their condition is met.
cough - Inserted into lines to represent coughing. Most dialogues use a list of various coughs like "-ack!"
interrupt - Inserted into lines when she's interrupted. Most dialogues use a list of various interrupts like "-ngh!"
swallow - Whenever she swallows.
drool - Whenever she drools.
head_grabbed - Whenever he grabs her head.
wake - If she passes out, this is what she says when waking up.
hand_job_stroke - Dialogue displayed only when jerking him off (I don't know the exact trigger mechanism)
lick_penis - She auto licks in proximity to his body, this is what she says when the penis is licked.
lick_balls - And this is what she says when the balls are licked (may also trigger when deepthroating balls deep)
pulled_up - When you pull her up by holding down the mouse button.
pulled_down - When you pull her down.

//These triggers set her mood, causing her AI to behave differently as well as changing her facial expression.
[NORMAL_MOOD]
[HAPPY_MOOD]
[ANGRY_MOOD]
[AHEGAO_MOOD]
//These triggers manage her hands.
[ARMS_BACK] - Positions her arms behind her back.
[ARMS_LEGS] - Positions her arms on her legs.
[ARMS_HIS_LEGS] - Positions her arms on his legs.
[ARMS_LOOSE] - Causes her arms to hang loose.
[ARMS_HAND_JOB] - Switches to hand job.
[TAP_HANDS] - She taps her hands on her/his legs, as she does when held down for too long.
NOTE: You can manage hands individually if you prefer through [LEFT_ARM_<ACTION>] and [RIGHT_ARM_<ACTION>]
[LEFT_ARM_BACK]
[LEFT_ARM_LEGS]
[LEFT_ARM_HIS_LEGS]
[LEFT_ARM_HAND_JOB]
[LEFT_ARM_LOOSE]
[RIGHT_ARM_BACK]
[RIGHT_ARM_LEGS]
[RIGHT_ARM_HIS_LEGS]
[RIGHT_ARM_HAND_JOB]
[RIGHT_ARM_LOOSE]
//These triggers manage other positioning.
[FACE_FUCK_STYLE] - Switches to Face Fuck style, a different base position
[NORMAL_STYLE] - Switches back to Normal style
[HOLD] - He grabs her head.
[RELEASE] - He releases her head.
//Facial expression triggers - use liberally!
[LOOK_UP] - She looks up at him and continues to do so.
[LOOK_DOWN] - She looks "down" and continues to do so (more forward than down).
[CLOSE_EYES] - She closes her eyes.
[OPEN_EYES] - She opens her eyes.
[BLINK] - She blinks.
[WINCE] - She briefly shuts her mouth and furrows her brow.
[SHOCK] - She briefly makes a wide-eyed, surprised expression.
//Other triggers
[SWALLOW] - She swallows, preventing speech and penetration until the animation finishes.
[CLENCH_TEETH] - She clenches her teeth for a while, preventing speech and penetration until the animation finishes.
[COUGH] - She coughs, and the game inserts cough text.
[ADD_TEARS] - She tears, though it takes a while to show typically.
[EJACULATE] - He cums immediately.
[DROOL] - She drools a cum-like substance whether she "actually" has it in her mouth or not.

{"next":"lineX"} - Plays lineX as the next line, if possible
{"style":"Him"} - The line comes out in Him style (in blue font and irrespective of her state).
{"style":"Thought"} - The line comes out in Thought style (with a white, foggy text background and even if her mouth is busy).
{"mood":"Normal"} - Plays this line only if her mood is Normal. Works the same with Happy, Angry and Ahegao of course.
{"held":"true"} - Plays this line only if he is holding her head.
{"held":"false"} - Plays this line only if he isn't holding her head.
{"check":{"var":"val"}} - Plays this line only if the variable var has value val.
{"check":{"chapter":2},"mood":"Happy","held":"false"} Plays this line only if the stars align so that the variable chapter has the value 2, her mood is happy, and he's not holding her head (just as an example).
{"set":{"var":"val"}} - Sets the variable var to value val (generic example)
{"set":{"chapter":"+1"}} - Increases the value of the numerical variable chapter by one (generic example)

YOU - The name of the Him model as entered through the options meny.
ME - The name of the Her model, such as Asuka.
YOUR - See above
MY - See above
FINISHES - a variable that calls up lines based on how many times he's finished.
finish0:"text0" - what FINISHES displays when he hasn't finished yet, in this case text0.
finish1:"text1" - what FINISHES displays, when called through asterisks, when he's cum once.
finishOther:"textOther" - what FINISHES displays when no specific finish line has been defined for the current number of finishes.

What to Use and How
The best way to write a good dialogue IS NOT to write several variations of every possible line, trigger or other nifty thing in the spoilers above. In fact, not only will it make writing your dialogue a chore, but the experience of running it will be bad, as many lines won't play, come in conflict with each other or execute poorly. This section will elaborate on how to use the dia system practically to make it all work smoothly.

The Intro
You will typically choose between a progressive or a discontinuous intro depending on what you have in mind. A progressive intro features a longer back-and-forth dialogue between Him and Her which is only repeated once. A discontinuous intro features several shorter lines that appear randomly, some of which may be repeated if the intro drags on long enough before he deepthroats her. Hybrid forms are certainly possible, for example using a progressive intro if she starts in one mood, and discontiunous lines conditioned to another mood - or by having several different shorter exchanges between Him and Her. Here's an example:

intro:"Hello there! [intro1]" {"style":"Him","check":{"chapter":0}}
intro1:"[LOOK_UP]Hi *YOU*! I'm gonna suck your cock! [ARMS_BACK][intro2]"
intro2:"[HOLD]Excellent, open wide! [SHOCK]" {"style":"Him","set":{"chapter":"+1"}}

In this example, we introduce the custom lines intro1 and intro2 and call them up through triggers. The first line that sets the snowball rolling so to speak will only come up when it's chapter 0, and as the intro finishes, the variable is increased to prevent repetition. Some appropriate facial expressions and hand positioning spice up the trivial text and makes it much more entertaining. This short progressive intro could be supplemented with additional intro lines that only play on higher chapter numbers if so desired. Or you could rely mostly on resistance lines until he deepthroats her.

Since the Her model spends a lot of her time with cock in her mouth, intro lines represent a good opportunity for her to actually talk, since they only trigger when she's idle anyway. On the other hand, resistance, first_throat and first_dt all trigger when her mouth is by definition occupied. To avoid losing dialogue lines in bouts of coughing and drooling, I really recommend making these style Thought or Him. Since it's difficult to control whether a first_throat or resistance line will trigger, I usually substitute these for a common custom line type. Putting this together, we get this:

first_throat:"[resH]" {"style":"Him"}
first_throat:"[resT]" {"style":"Thought"}
resistance:"[resH]" {"style":"Him"}
resistance:"[resT]" {"style":"Thought"}
resH:"A sample line, spoken by him" {"style":"Him"}
resT:"A sample reflection on having a cock pushed down her throat" {"style":"Thought"}

You will want to increase the number of resH and resT lines to avoid repetition of course. This saves space since you'll use the same lines for first_throat and resistance, and also get a nice alternation between Thought and Him lines to keep it more interesting. Unless you use extremely tough throat resistance settings, 5-10 lines total of this type should avoid repetition.

Dialogue Features
Of course, the same philosophy of having her mouth occupied applies to first_dt, however this line will never repeat so there's no need to have a high number of first_dt lines. For this reason, I like to use this as an opportunity for something unique and slightly more complex to happen. I like to call these things dialogue features. A dialogue feature is a combination of several triggers, lines and conditions that (whether taking up lots of coding or little space) gives the player the illusion of a more complex, coherent action or reaction. Examples include slapping her for being too eager, her flailing objections to being pushed down so far, or ejaculating instantly from the triumph of finally penetrating her throat fully.

You can find inspiration for many different such features scattered throughout many of the more elaborate dialogues on the forum - they are too numerous to cover in a guide and any listing could never be complete as you could always compose new features. However one particularly popular and useful feature is to use the pulled_up and pulled_down lines to accomplish crucial plot devices, since these actions are always under the player's direct control and do not affect the game state by themselves. Here's an example:

pulled_up:"[NORMAL_STYLE][RELEASE][ARMS_LEGS][HAPPY_MOOD][general]" {"held":true"}
pulled_up:"[FACE_FUCK_STYLE][HOLD][ARMS_BACK][AHEGAO_MOOD][vigorous]" {"held":false"}

This simple dialogue feature makes it so that the player can switch between one mode where she's happily going solo and another where he face fucks her with gusto, by pulling her up. In each case, there is appropriate dialogue (assuming of course you've written it with this dialogue feature in mind) without adding any more unneeded text.

General lines is another good opportunity for her to speak since they also trigger when idle. This is a good place to hide interesting features, which provides an incentive for the player to take a break from throating her occasionally. Alternately, if she's eager, you could use these lines to express impatience on her part. I also recommend pull_off lines to be in the default speech style only, or else they will be all you hear for the bulk of the dialogue. However, if they can't trigger when she has a cock in her mouth, you're golden. Conversely, vigorous lines need to be Thought or Him if you want a chance to hear them - they can be difficult to trigger at times even if you take these steps.

Using Delays and Line Breaks
Held lines are a mixed bag. If you make them Thought/Him they will trigger very frequently when she's actually held, so you'll need a lot of them (dozens) if you want to avoid repetition until you choke her out. On the other hand, if you make them speech style, it's quite possible that the line will be lost in excessive coughing once she is released. A solution is to use the cyrillic letter Б to introduce a pause. SDT doesn't know what to print for this character, so it prints nothing and pauses for a while instead. So fill those Thought/Him styled Held lines with as many Бs as seem appropriate and see how it plays out and fine tune from there to get the result you want. Also, you can combine these pauses with line breaks (the URL code is %0A to introduce a line break) to really go beyond the timing limitations of the dialogue system as coded in the game.

Simplify and Substitute
The various cum-related lines are an undependable bunch that often stack out each other. Therefore, I usually don't bother with pre_cum and restart lines at all, unless I'd want to use them instead of actual cum lines for some reason. She will have difficulties talking with cum over her face and obviously it will be impossible with cum in her mouth/throat/nose. It always made more sense to me that the guy is the expressive one during ejaculation, and he probably doesn't have time to reflect on exactly where he's cumming. To save lots of time and dia space, I therefore recommend making style Him substitutions for all cum lines, unless it's very important to you to discriminate between them.

cum_on_face:"[cumH]" {"style":"Him"}
cum_in_eye:"[cumH]" {"style":"Him"}
cum_in_mouth:"[cumH]" {"style":"Him"}
cum_in_throat:"[cumH]" {"style":"Him"}
cum_in_nose:"[cumH]" {"style":"Him"}
cumH:"Oh God how good it feels, yadayadayada. " {"style":"Him"}

Add several cumH lines, introduce cyrillic pauses, add a progressive exchange mixing it up with Thought lines or whatever. You know the drill.

Unless you need to, I also recommend AGAINST using head_grabbed, swallow or drool lines as these too are undependable and have a tendency to trigger when you don't want them to, override stuff or be overridden by other lines that want to trigger simultaneously, such as when or after ejaculating. Wake up lines are good to use but since she'll be coughing and choking for a while when waking up, you'll have a better chance of actually seeing them if you make them Thought/Him, or at least start them up like that and make it progress into speech to buy her time to finish coughing.

Troubleshooting
1) I can't get ANY dialogues to work in SDT - Did you enable dialogue in the Options menu check box? Are you loading them in the correct box in the Options menu? Are you using an extremely old version of SDT?
2) MY dialogue won't play at all, but others will - Did you work in a word processor? Then your quotation marks may be poorly formatted and you will need to replace them all manually in a proper text editor.
3) My dialogue plays except for this here LINE - Are you missing a quotation mark or is the formatting lacking in any other respect? If it's a custom line type, is it called properly in its parent line? Is a bad condition that will never be fulfilled preventing the line from being played?
4) All lines are played but this here TRIGGER doesn't do anything - If you're calling a custom line with a trigger, are the names identical? Is there an unfulfilled condition preventing the call? Are you trying to make her speak with a mouthful of cock? Is the trigger actually outside the line's quotation marks, making it useless?
 

T0mcat

Avid Affiliate
Joined
Feb 5, 2012
Great job, Slinger... +Karma

------------------------------------

Some small additions..

Although Kona has already tried to circumvent this problem, the [CLENCH_TEETH] trigger and her automatic teeth-clenching when she is in [ANGRY_MOOD] often break lines supposed to be said by her, so that they are not displayed completely or even not at all. So be carefull when using either and be sure to test the lines containing these triggers thoroughly.

By using * * You can define variables to be displayed in a line.
Example:

swallow:"Good girl. You really swallowed it all. [reply]" {"style":"Him", "set":{"reply":"bitch"}}
swallow:"Wow. You really swallowed it all. [reply]" {"style":"Him", "set":{"reply":"whore"}}
swallow:"Who would have thought. that You really swallow it all. [reply]" {"style":"Him", "set":{"reply":"cumslut"}}
swallow:"My, oh my. You really swallowed it all. [reply]" {"style":"Him", "set":{"reply":"wife"}}

reply:"Of course. I am Your *reply*!"

What does this do: When she swallows, a random "swallow" line will be displayed, calling up the "reply" line next and providing one of four variables to be used within that "reply" line. By using several different "reply" lines, which make sense when using the same varible, one can achieve a rather random display of answers with not too many lines used for it.
The basic version (as above) doesn't reduce the amount of lines much. Five written lines get You only four possible combinations. But each added "reply" line gets You another four possible combinations..

With a little trickery, one can even make the answers more random.

swallow:"Good girl. You really swallowed it all. [option]" {"style":"Him"}
swallow:"Wow. You really swallowed it all. [option]" {"style":"Him"}
swallow:"Who would have thought. that You really swallow it all. [option]" {"style":"Him"}
swallow:"My, oh my. You really swallowed it all. [option]" {"style":"Him"}

option:"[reply]" {"set":{"reply":"bitch"}}
option:"[reply]" {"set":{"reply":"whore"}}
option:"[reply]" {"set":{"reply":"cumslut"}}
option:"[reply]" {"set":{"reply":"wife"}}

reply:"Of course. I am Your *reply*!"

Here one of the four "swallow" lines will be called up randomly, then calls one of the four "option" lines randomly. The option line shows up blank on the screen for a very short time, which shouldn't be noticed by most people, because her next line is called up immediately. Total possible combinations = 16 / Lines written: 9

As soon as the variables are defined, one can go even a step further, as variables can also be used to call up lines by putting them within square brackets like this [*variable*]

example:
use the same "swallow" and "option" lines..

reply:"Of course. I am Your *reply* [*reply*]"

bitch:"bla..bla.."
whore:"bla.. bla.."
cumslut:"bla.. bla.."
wife:"bla.. bla.."

This will not only bring up all the randomness already mentioned above, but lead to another appropriate reply.

- Variables remain set, until they are set with a new value! So You can use them in a multitude of lines.

- As it seems, setting variables happens BEFORE displaying the line in which they are set.

So when You try to go for some kind of progressive dialogue, don't do stuff like this:

intro:"You are my little bitch. [bitch]" {"style":"Him","set":{"reply":"whore"}}
bitch:"Or even my little *reply*? [*reply*]" {"style":"Him","set":{"reply":"cumbucket"}}
whore:"No, I'm just Your *reply*"

looks nice, but doesn't do what it's supposed to do. It should display the lines like this:

HIM: You are my little bitch.
HIM: Or even my little whore?
HER: No, I'm just Your cumbucket

What it will display is this:

HIM: You are my little bitch.
HIM: Or even my little cumbucket?

.. and the "whore"-line won't be displayed at all..

New triggers in v1.21b:

[ARMS_HAND_JOB] / [LEFT_ARM_HAND_JOB] / [RIGHT_ARM_HAND_JOB] - moves both of her hands / her left hand / her right hand on to his cock. Changes mouse-control from head to handjob mode.

[LEFT_ARM_(position)] and [RIGHT_ARM_(position)] - sets the appropriate arm to the given position; see trigger [ARMS_BACK] etc for possible positions.
 

T0mcat

Avid Affiliate
Joined
Feb 5, 2012
Another tidbit about using variables:

A variable can not only be used to call up a certain line - [*variable*] - it can also function as a PART of a line's name.. [trigger*variable*] see example in the Spoiler..

//testing variables

DEFAULT:
all:"CLEAR"

initial_settings:{"count":0}

intro:"Checking linking options.. [intro*count*]" {"style":"Him"}

intro0:"Count is 0 [counter]" {"style":"Him"}
intro1:"Count is 1 [counter]" {"style":"Him"}
intro2:"Count is 2 [counter]" {"style":"Him"}
intro3:"Count is 3 [counter]" {"style":"Him"}
intro4:"Count is 4 [counter]" {"style":"Him"}

counter:"" {"set":{"count":"+1"},"style":"Him"}

Doesn't look like much, but it helps to avoid the "check" lines, which still use a lot of processing power.

Using this it gets easy to call up a certain line depending on how often the trigger action has been done before. See example2 in the next spoiler:

This one won't work as a standalone dialogue - it's just to show how the stuff stated above could be used.

wake:"[wake*count*]" {"style":"Thought"}

wake0:"He made me pass out.." {"style":"Thought", "set":{"count":1}}
wake1:"He made me pass out.. again?" {"style":"Thought", "set":{"count":2}}
wake2:"Again? Really? Is he trying to kill me?" {"style":"Thought", "set":{"count":3}}

And don't forget the fact, that the same variable can be used not only in one type of trigger lines ;)

so.. add to the above "wake" lines some other stuff like:


held:"[held*count*]" {"style":"Thought"}

held0:"Oh god.. I need to breathe.." {"style":"Thought"}
held1:"If he goes on like that, I'll pass out again" {"style":"Thought"}
held2:"He really tries to kill me by suffocating me with his cock I guess" {"style":"Thought"}

I bet, people better than me will find even more interesting uses for this ^^

Edit:

found something more.. it even works with more than one variable - like: [trigger*variable1**variable2*]
Again, a short - non fully self functional - example in the spoiler..

initial_settings:{"throated":"false","count":0}

held:"Checking linking options.. [held*throated**count*]" {"style":"Him"}

heldfalse0:"Count is *count* [count]" {"style":"Him"}
heldfalse1:"Count is *count* [count]" {"style":"Him"}
heldfalse2:"Count is *count* [count]" {"style":"Him"}
heldfalse3:"Count is *count* [count]" {"style":"Him"}
heldfalse4:"Count is *count* [count]" {"style":"Him"}

first_dt:"Down it goes.. " {"style":"Him","set":{"throated":"true"}}

heldtrue5:"Count is *count* and it's *throated* You've been throated [count]" {"style":"Him"}
heldtrue6:"Count is *count* and it's *throated* You've been throated [count]" {"style":"Him"}
heldtrue7:"Count is *count* and it's *throated* You've been throated [count]" {"style":"Him"}

count:"" {"set":{"count":"+1"},"style":"Him"}

possible uses:

- different lines for each trigger depending on different things that already happend to her.. like waking up, swallowing, getting her face creamed etc.. etc.. etc..

... and all that without a single "check" ^^
 

Slingerbult

Content Creator
Joined
Sep 15, 2012
A variable can not only be used to call up a certain line - [*variable*] - it can also function as a PART of a line's name.. [trigger*variable*] see example in the Spoiler..

[...]

found something more.. it even works with more than one variable - like: [trigger*variable1**variable2*]

T0mcat, this is GREAT stuff!!! With this we have completely dynamic lines. You could just select how long a string of numbers you care to have after a line and what each number represents and just go bonkers with it. I will think about dialogue trees in entirely new ways after reading this. Are you sure this doesn't really slow the game?

Although Kona has already tried to circumvent this problem, the [CLENCH_TEETH] trigger and her automatic teeth-clenching when she is in [ANGRY_MOOD] often break lines supposed to be said by her, so that they are not displayed completely or even not at all. So be carefull when using either and be sure to test the lines containing these triggers thoroughly.

Yup, this is already in the guide - at least the clench_teeth part but it's worth noting that the angry mood has some random hard coded teeth clenching in its AI. (Using Thought and Him a lot seems entirely appropriate when Angry).

By using * * You can define variables to be displayed in a line.

This is also in the guide, but your example is an excellent instruction of how to put it to good use.

- As it seems, setting variables happens BEFORE displaying the line in which they are set.

Good to know. The guide instructs not to set and check a variable in the same line.

New triggers in v1.21b:

These are in the guide too :)

I'll probably update the guide with the info on using (multiple) variables in triggers to call lines once I wrap my head around what this will really mean for advanced dialogue building. Pretty fantastic stuff TBH. 8)
 

AaRL

Vivacious Visitor
Joined
Feb 17, 2011
Also a note you should add to the "Б" characters. When using notepad to edit the dialogue, you must change the encoding of the file to Unicode for the БББ characters to be retained in the file. If not, they will not be saved with in the file. Go to File, Save As, and next to the Save button, use the drop down menu to select Unicode.

Also, the "Б" will not display with in the in game editor.

Edit: Just had an idea/thought: Why isn't their a dialogue trigger/command for her to stick out her tongue? I dont know why this hasn't dawned on me before...

Something like [TONGUE_IN] [TONGUE_OUT]

(and yes, I tried that command and it doesnt work lol)
 

Slingerbult

Content Creator
Joined
Sep 15, 2012
Thanks AarL, I'll include that when I edit the guide.

Btw, has anybody tried manually setting the game's "hard coded" variables like FINISHES or YOU? I reckon it would be possibly to set them just like any other variable. Once you call on them in a line with asterisks, I assume the latest setting would override the "normal" setting (via options menu or through cumming etc).

I've tried to wrap my head around how *FINISHES* really work. T0mcat's findings lead me to believe there some hidden variable (let's call it CUM) that increases with +1 each time he cums, so as to create the finish*CUM* lines (finish0, finish1 etc.). However, how is this string in turn "loaded" into the FINISHES variable? As in, how is FINISHES "set" to finish0, finish1 etc?

Could it be that you can set the value of a variable to the contents of a line? For example:

value:"This is a line and the value of a variable."
intro:"This is an intro line." {"set":{"variable":"value"}}
intro:"*variable* Neat huh?"

If the first intro line has been displayed, will the second intro line then read: "This is a line and the value of a variable. Neat huh?" Or will it simply read "value. Neat huh?"

I'm "Away From Smut" right now so I can't verify this, but the FINISHES variable must work by some mechanic and I think T0mcat "decoded" half of it and maybe it's possible to unveil the other half...
 

AaRL

Vivacious Visitor
Joined
Feb 17, 2011
You could also add another way or progressive dialogue instead of the advanced technique.

intro:"This the first line which in turn...[intro1]"
intro1:"Well lead to this line which in turn...[intro2]"
intro2:"Leads to this...[intro3]"
intro3:"And so on and so forth.[intro4]"

Another idea I came up with, but sadly hasn't/cant/wont be done. "Color Coded dialogue" to indicate others in the room/dialogue. Could use the already existing RGB sliders and could be imputed something like [R100_B000_G000] to make the color a dark red. No idea how to implement it other than manually placing it in with Notepad.
 

T0mcat

Avid Affiliate
Joined
Feb 5, 2012
Slingerbult said:
Could it be that you can set the value of a variable to the contents of a line? For example:

value:"This is a line and the value of a variable."
intro:"This is an intro line." {"set":{"variable":"value"}}
intro:"*variable* Neat huh?"

If the first intro line has been displayed, will the second intro line then read: "This is a line and the value of a variable. Neat huh?" Or will it simply read "value. Neat huh?"

Here's the log that comes up when You put that idea into a dialogue:

0: Loading custom dialogue.
------------------------------
1: Adding custom line: "This is a line and the value of a variable."
2: Adding custom line: "This is an intro line."
3: Adding custom line: "*variable* Neat huh?"
4: Done.
------------------------------

Easy to see {"set":{"variable":"value"}} doesn't lead to the content of "value" to be set as the value of "variable"

Concerning "FINISHES"

As can be seen when using the Loader - with the *INIT* mods - SDT has an internal cum counter. As well as internal (and therefore usually hidden) counter for breath level, vigourous throating, male pleasure level and a load of other things, I guess.

So finish1 to finishother just use that hard coded, built in counter.

Short test:

Dialogue

DEFAULT:
all:"CLEAR"

intro:"test" {"style":"Him","set":{"*FINISHES*":3}}

restart:"*FINISHES*"

pre_cum:"I just came *FINISHES*" {"style":"Him"}

cum_on_face:"I came on Your face *FINISHES*" {"style":"Him"}

finish1:"Once"
finish2:"Twice"
finishother:"often"

Log:

0: Loading custom dialogue.
------------------------------
1: Adding custom line: "test"
2: Adding custom line: "*FINISHES*"
3: Adding custom line: "I just came *FINISHES*"
4: Adding custom line: "I came on Your face *FINISHES*"
5: Done.
------------------------------
6: Playing line "test"
7: Storing *FINISHES* = 3
8: Playing line "I just came *FINISHES*"
9: Playing line "I came on Your face *FINISHES*"

Displayed in game:

I just came once
I came on Yor face once

Conclusion:

Although we set *FINISHES* to a value of 3 - and it even was stored, as can be seen by the log - finish1 displays the string given to it.

Test Two: *ME*

Now a test for the *ME* variable.

Code

DEFAULT:
all:"CLEAR"

intro:"test" {"style":"Him","set":{"*ME*":"Anna"}}

pre_cum:"I am going to shoot on Your face, *ME*" {"style":"Him"}

cum_on_face:"I came on Your face *FINISHES*" {"style":"Him"}

finish1:"Once"
finish2:"Twice"
finishother:"often"

Log

0: Loading custom dialogue.
------------------------------
1: Adding custom line: "test"
2: Adding custom line: "I am going to shoot on Your face, *ME*"
3: Adding custom line: "I came on Your face *FINISHES*"
4: Done.
------------------------------
5: Playing line "test"
6: Storing *ME* = Anna
7: Playing line "I am going to shoot on Your face, *ME*"
8: Playing line "I came on Your face *FINISHES*"

Displayed in game:

I am going to shoot on Your face, Susan - which is the name under which the character is stored
I came on Your face Once

Conclusion:

Same as with *FINISHES*: the hard coded check for the variable - in this case the name under which the character is stored (or the one given in the char code) - supercedes the variable set in the dialogue.

I didn't check for *YOU* but I guess the result will be the same ^^

Test was done by loading a new SDT session, then loading the dialogue. The girl was set to do a wanking job. As soon as the intro line was displayed, I engaged auto-wank-mode and waited 'til he shot his load over her face..

So, sorry Slinger.. nothing to be seen here it seems.. nothing decoded or to be unveiled. Unless You dig deep into the flash code itself, I guess..
 

Slingerbult

Content Creator
Joined
Sep 15, 2012
Good work TC! It all seems up to snuff except your were setting *YOU* rather than YOU etc. Shouldn't matter for FINISHES but could you repeat the test and remove the asterisks within the wavy brackets? I'm on the road all day today too but will test it tomorrow if you haven't already.
 

T0mcat

Avid Affiliate
Joined
Feb 5, 2012
Slingerbult said:
Good work TC! It all seems up to snuff except your were setting *YOU* rather than YOU etc. Shouldn't matter for FINISHES but could you repeat the test and remove the asterisks within the wavy brackets? I'm on the road all day today too but will test it tomorrow if you haven't already.

Tested with ME instead of *ME* - same result...
 

sby

Content Creator
Coder
Joined
Sep 11, 2012
just noticed it in konashion's dialog post, thought it might be worth mentioning in this one since it covers a lot:

checking for greater,less than (not just equal):
{"check":{"count":">=2"}

through example that i needed this for:
held:"not sure how much longer i can hold it in. ."{"style":"Thought","check":{"breathLevel":"<30"},"check":{"breathLevel":">15"},"check":{"passOutFactor":"<=0"}}

~ breathLevel and passOutFactor were added to the dialog variable dictionary and updated by a mod

edit - it seems the multi- checks don't work as expected, that last check is the only one that seems to matter :(
 

Slingerbult

Content Creator
Joined
Sep 15, 2012
"edit - it seems the multi- checks don't work as expected, that last check is the only one that seems to matter"

Yeah, you need to put all checks/sets within the same wavy brackets. I think there were issues doing this with checks though (sets work fine, like so: "set":{"variable1":1,"variable2":"false"}). To check intervals or other series of checks, you can just make several checks, like check the first line for value X while calling the second line that only displays if yet another condition is met. Anyway, check lines are a thing of the past with T0mcats new tech - IF I can get it to work (still working on that).
 

cookiemonste

Potential Patron
Joined
May 9, 2013
I'm sorry I don't get the part with the next.
I'm trying to create a "introchain". But I'm not succesfull.
I typed: .{"next":"intro1"}
I created some introlines from 1-9
Can you help me?
 

Rusty66

Content Creator
Joined
Nov 1, 2012
Note: "Him" & "Thought" style lines will not load into SDT if the word "finish" is within the line of dialogue (or any word containing those letters in that order, i.e. finished, finishing, etc.). An easy workaround is to create a variable and define it as "finish". Then, call out that variable within the dialogue line. Example:

initial settings:{"FIN":"finish"}

pre_cum:"*FIN* me off bitch!"{"style":"him"}

output:"finish me off bitch!"

EDIT: If the first letter is capitalized, then SDT will load the line (i.e. Finish). So, the above example would work without a substitution when the first letter is capitalized. Example

pre_cum:"Finish me off bitch!"{"style":"him"}

output:"Finish me off bitch!"
 

cookiemonste

Potential Patron
Joined
May 9, 2013
I want to trigger a new line. But I don't get it working.
It's not abou basic lines now. just the Intro.
If I'm nota ble to get it working I will post the dialogue without the trigger, hoping that someone can fix that.

cookie :)
 

LordAardvark

Potential Patron
Joined
May 17, 2013
Hey all, I have a question.

I am building a framework for a bunch of dialogues I intend to write. This framework implements a simple variable-driven "arousal" system, which uses different ranges of "arousal" to dictate what kind of dialogue is spoken, and different actions affect the arousal in different ways. (I am a hobbyist programmer, if one couldn't guess :D).

However, I am new to this syntax that the dialogue system in SDT uses, and what I am trying t implement is a big more comprehensive than what this tutorial covers, so I am not sure if I am doing this right.

Namely, I want to know how my settings for arousal are working, and how quickly different phases are entering. To do so, I added a debug line to print what the current arousal integer is, so I can compare it to the lines that are being played. However, when my "debug" line calls, it just prints white-space! Here is the basic structure of my frame:

Code:
all:"CLEAR"
dialogue_name:"Generic-Shy"

initial-settings:{"arousal":250} // She starts in the middle of arousal.

debug:"Arousal: *arousal*" {"style":"Him"}

general:"Are you enjoying yourself*, YOU*?[debug]" {"check":{"arousal":">=200","arousal":"<300"}},{"set":{"arousal":"-2"}}

The "Are you enjoying yourself" line is calling, and the Debug line is printing "Arousal: ". No number or anything.

Any idea what I am doing wrong? Thanks a lot in advance, guys. :).
 

Users who are viewing this thread

Top


Are you 18 or older?

This website requires you to be 18 years of age or older. Please verify your age to view the content, or click Exit to leave.