A downloadable asset pack

Download NowName your own price
This is a dialogue system for GameMaker Studio (1 & 2). It features:
  • Text effects (colours, waves)
  • Words spell out like typewriter
  • Animated character portraits
  • Character voices
  • Dialogue choices
  • Character emotes

Click here to view/download the asset listing in the GameMaker marketplace. You can use this to download the project contents into your own project, rather than simply downloading my demo project. (Note: only for GMS2. Unfortunately I don't have a license to upload the GMS1 version!)

INSTRUCTIONS

Click here to view the documentation/instructions for this asset.

 CREDITS

The character sprites and portraits in the project/previews were made by Buch. The emotes were by Tomcat94. Also, some of the text effects (wave, colour shift) as well as the code logic I'm using for the effects is from this tutorial by diestware. 

Importing into Existing Project 

For GMS2, you can import the asset from the Marketplace directly into your project. As I said above, I don't have a license to list the GMS1 version. So, here's another method:

Download

Download NowName your own price

Click download now to get access to the following files:

DialogueSystem_v121.yyz 153 kB
DialogueSystem_v120_GMS1.gmz 96 kB

Development log

Comments

Log in with itch.io to leave a comment.

Viewing most recent comments 1 to 40 of 60 · Next page · Last page
(1 edit)

OK, I have an issue.

In my project I made an option for players to choose their game target FPS (for different monitors and performance setups) and I adjusted all my object animations and move speeds using delta_time dependent global variable, just a simple multiplier that adjusts all speeds to the selected FPS. So in 144 FPS everything moves and animates at the same relative speed than in 60 or any other FPS (just more smoothly) . It works perfectly. But I can't find how I can adjust character drawing speed in the FC's textbox object. So at high FPS my dialogues are typing too fast.

Is there somewhere a variable or a forgotten magic number in the code that sets up a global typewriter speed or maybe somebody has another idea in mind how to adjust the typewriter's speed?

Edit: Also, how to set up a long dialogue text on multiple pages without breaking it in lots of "Lines"?

OK, I figured it out. I made a kind of step manager that counts steps and authorizes the typewriter to go when necessary delta_time relative value is reached. It is not perfect, because it can work with whole numbers only, but it's overall OK at least for 60-144 FPS setups. For lower framerate it slows down, hélas. Now I need something similar to adapt portrait and mouth animations and I'm kinda stuck with it. Whatever I do, the animation is too fast like if it is not related to my delta_time multipliers at all T_T

Kinda solved the animation problem. The solution was to not link talking mouth animation to vowels and to not link talking animation with typewriter's delta at all. The problem was relative to typewriter's delta-relative counter that works perfectly with characters, but switched on and off too fast for any chosen sprite speed.

Could someone…..anyone…. do a step by step tutorial of implementing this into your project. As a noob I’m having lots of trouble trying to understand this. Also does anyone know of a video tutorial? I’m simply too dumb for the written instructions 

If FC won't do it herself the best thing you can do is to follow her Farming RPG series. You will not get the very same result, but you can learn the logic she uses.

Has anyone successfully managed to add gamepad inputs to the dialogue system? Every time I try and use a gamepad input (either via gamepad_button_check_pressed or a similar script value) I either get nothing at all or it instantly triggers all the text at super speed!

Deleted 1 day ago
(1 edit)

There should be  a variable somewhere that controls when its day and night. I haven't watched this tutorial but in my game I have a variable called value_ and it goes from 0.0 to 1.0.    0.5 is noon and 1.0 is midnight. I'm sure it's something similar and all you do is update that variable when the game starts.

Deleted 1 day ago

Darkness variable should be it. I'm guessing 0.7 is the darkest, try changing it to 0.4 or something.

Deleted 1 day ago

hey the font is too big for my text box, how do i make it smaller?

i fixed it, no worries. got another font, edited it a bit and changed the spacing added borders and everything looks sweet

(4 edits)

anybody encounter this error here and know what's up?

likely a 2.3 issue.

EDIT: oh I see someone below posted a solution to this already my bad: 


In GMS v2.3.2, there's been a bugfix where array_length returns undefined instead of 0 when you pass in non-array values. 

Replace line 16 in Alarm 0 with effects_al = effects[page] != -1 ? array_length(effects[page])/2 : -infinity;


thx toronto!

EDIT2: Looks like I finally get to view the demo project, but some of the text is showing up 'black' instead of with its appropriate style. unless that's just how that portion is supposed to draw :D 

Thank you so much! I was stymied by this. Now I can poke around properly!

(+1)

This was really cool until I broke it and don't know what this error means

(1 edit)

This error seems to be related to the 2.3 update. Also can't figure out how to fix it. Did you fix it?

Try to put brackets like this



    create_textevent(

    [                                                                                              //myText

        load_string_json(global.LANGUAGE, "forest0"),

        load_string_json(global.LANGUAGE, "forest1"),

        load_string_json(global.LANGUAGE, "forest2"),

        load_string_json(global.LANGUAGE, "forest3"),

        [load_string_json(global.LANGUAGE, "forest4"), load_string_json(global.LANGUAGE, "forest5")],

        load_string_json(global.LANGUAGE, "forest6"),

        load_string_json(global.LANGUAGE, "forest7"),

        load_string_json(global.LANGUAGE, "forest8"),

        load_string_json(global.LANGUAGE, "forest9")

    ],

    [ob, og, og, ob, op, ob, og, og, ob],                                                          //mySpeakers

    [ [28,4, 42,0], [7,1, 11,0], [21,1, 29,0], [-1], [-1], [1,5, 5,0], [-1], [1,6, 3,0], [-1] ],   //myEffects

    -1,                                                                                            //myTextSpeed

    [0, 0, 0, 0, 1, 0, 0, 0, 0],                                                                   //myTypes

    [0, 0, 0, 0, [5, 7], 0, -1 ,0, -1],                                                            //myNextLine

    -1,                                                                                            //myScripts

    -1,                                                                                            //myTextCol

    [0, 3, 2, 1, 0, 5, 3, 1, 2],                                                                   //myEmotion

    -1                                                                                             //myEmote

    );

hello man I love you unfortunately I don't have the money to reward you for creating this tool, so I ask you to come into my house and eat the ass of my whole family as payment =)

(1 edit) (+3)

In GMS v2.3.2, there's been a bugfix where array_length returns undefined instead of 0 when you pass in non-array values. 

Replace line 16 in Alarm 0 with effects_al = effects[page] != -1 ? array_length(effects[page])/2 : -infinity; as a stopgap solution

A good tool for gms2

This has been working very well for me except when it comes to choices/branching dialogue. I get the following error after making a choice (selecting Red, Blue or Green) and I can't figure out why:

___________________________________________
############################################################################################
ERROR in
action number 1
of Alarm Event for alarm 2
for object obj_textbox: trying to index a variable which is not an array
 at gml_Object_obj_textbox_Alarm_2 (line 20) -               case -1: instance_destroy();       exit;
############################################################################################
gml_Object_obj_textbox_Alarm_2 (line 20)

Any help would be appreciated! This is what I have in the User Event0 of my custom speaker object.

reset_dialogue_defaults();
// Line 0
myText[0] = "Hey, what's your favourite colour?";
myTypes[0] = 0;
myEmote[0] = 1;
mySpeaker = -1;  // Line 1
myText[1] = ["Red", "Blue", "Green"];
myTypes[1] = 1;
mySpeaker = -1; 
myNextline[1] = [2, 3, 4]; // Line 2
myText[2] = "Red's pretty hot.";
myTypes[2] = 0;
mySpeaker = -1;  // Line 3
myText[3] = "Blue's pretty cool.";
myTypes[3] = 0;
mySpeaker = -1;  // Line 4
myText[4] = "Green, like the grass.";
myTypes[4] = 0;
mySpeaker = -1; 

This looks very cool. I was wondering if you have any advice for how to store dialogue and call it up at the appropriate time. I've heard that using csv or json files is good, but I'm not clear on how to use them in GML.

Thanks!

(+1)(-1)

Made a similar Dialogue System for UNITY: https://narrenschlag.itch.io/better-dialogue

(+1)

Hello Friendly.C! I'm trying to see if the dialogue can replace the player's sprite for a different one... I have not been able to find a way, could you help??

(+1)(-1)

Hi ! I have a problem with the full screen mode : text boxes are not visible ! Can you help me please

(2 edits)

Switching out the font the text always "kin d a l o ok s l i ke th i s" with spaces between some letters. I've tried different fonts but it always looks off. The "CharSize" variable does change the kerning, but it changes nothing about the character spaces being off in the first place, so you can't fix it by changing that. The random spaces remain.

Does anyone know what this could be about? Is there a way to fix this? 


Edit: 
To reproduce this, just change the default font to literally anything else. Whatever else I try has the kerning/letter spacing thrown off. Is there any way to fix this, or are you effectively locked to using the font it comes with?

(2 edits) (+1)

I found the solution, this stuff is only compatible with "monospaced fonts".

This is literally the most helpful thing I've seen in the history of GMS things.

Thanks so much for this, best of luck to you in your future projects btw!

I'm having a really weird bug importing this into my game. The camera instance works perfectly, when using the player monologue, it draws the textbox about halfway hidden. Specifically, it clips to the bottom of the screen and to the right. I think it could do with something with the gui because my room and camera dimensions are the same (I only plan on playing the game myself, so I set both to 1600x900) I don't mind manually adjusting the positioning, in fact, I would be happy to even just left align everything. I messed around with the xpos and ypos variables and while adjusting the ypos changes the height, the xpos only seems to affect the name box. Can anyone advise me?

I am also having the same issue, any luck?

(1 edit) (-1)

Uuuuggghh! When I try to import your engine in my GameMaker 1.4, it gives me a bunch of errors. Can you help me just a bit or at least give some clues what I should do?





(+2)

As stated in the description this is "only for GMS2" and the functions highlighted do not exist. But the good new's is that's your "clue" as to what needs to happen! Break it down line by line and find an alternative method for producing the same result. So for instance if we look at the official documentation for create_array(); [https://docs.yoyogames.com/source/dadiospice/002_reference/001_gml%20language%20overview/array_create.html] it states that it just instantiates (prepares) the array before its used by writing "0" there for as many entries as needed. Could hypothetically use something like this to do it:  for (i=0; i < arrLength; i++) { arr[i] = 0; } where arrLength is the numeric value for how many entries you need in the array. put that into a script called "create_array" expecting 1 argument. You may need to play around with this though as i have not had 1.4 loaded onto my pc for a while now but thats the general idea. 

(+1)

Thanks, Leonidus1989!

Did you get it work? Im struggling with it too

nnah actually...

same i just took that part out of my game

yo, I'm super new to itch.io, but you are the only other person I know who has played 'a strange disease' I can't find it on youtube or anything, and I do be stuck 0.0 ... I don't know how to get salt or anything - I appreciate and understand if you wish not to help me (and I'm sorry i didn't direct message you as I don't know how to yet)

(+2)

Oh my god this is the best thing ever. Thank you so much! I cannot believe it's so robust and especially the fact that its free! This is the best Christmas gift I could've asked for. One thing, I've probably already figured it out by the time you see this, but where is the code that makes the player stop moving? Thank you so much again, this is beyond useful.

(2 edits)

hi I ,why is giving me this errors?

Looks like you are using GMS 1.x and its trying to call GMS 2.x functions, but (naturally) they don't exist. 

Very cool dialog system! Can't wait to see people transforming this into other dialog system like Undertale or other.  Over all best dialog system so far! 

Hey there. Does GMS use a version of JS to code? I was wondering if you knew of a similar plugin for RPGMaker MV to do the animated dialogue in text boxes?

GMS uses its own language called "Game Maker Language" which shares similarities to C based languages (and JS by extension). Though it's not a 1 to 1 deal. For RPGMaker i know that yanfly is typically the way to go for that kind of pre-made stuff.

(+1)

this is so incredibly cool, thank you so much!

(1 edit)

gms version doesn't work with html5 =\

This is incredibly helpful (even if I am late to the party). Thank you so much for your tutorials and I will definitely credit and notify you when my game is far enough along. I've learned so much from you so keep up the incredible tutorials and assets! :)

I know you've briefly mentioned how to get a proportional font, and I think it may be easier to fiddle around in obj_textbox draw_gui event.  Maybe replacing the charSize variable with something like string_width(ch).


I dunno.  Would I absolutely HAVE to make a ds map?

(+1)

This is a pretty neat system, as it'll help people get past the tedious things like scripting talking systems (though they should still understand what's going on under the hood) and get right back to making games. However, I am having an issue where my text boxes seem to be spacing oddly. Is there something I'm missing to get the dialogue to space properly? Thanks.

Hi! The sounds of this package can be used for another game engine(Rpg Maker)?

No, this is basically a game maker studio pre-created project for a dialogue system. But fear not! As RPG maker has one built in already! If you want something outside of the base for that though then i recommend looking up yanfly plugins. 

(+1)

Thanks! 

This will definitely be helpful for my project that I'm doing.

One question though, how do i make it so that the dialog can advance on its own without player input. For example: Cut scenes.

Oh my god, this is such a helpful resource!
As a complete novice, does anybody know how you'd go about feeding through a randomised selection of voice sounds, instead of only a single one?

Deleted 2 years ago

Hey sorry for the slow reply - it wouldn't be the EASIEST thing to tweak, but you could save an array of voices instead of just one entry. So for example, voice = [snd_voice1, snd_voice2, snd_voice3].

Then track down the part where it plays audio, I'd just use CTRL + SHIFT + F and put "audio_play_sound", and it should take you to the function that plays it. Instead of just putting in the "voice" variable as an argument, you could do irandom_range(0,array_length_1d(voice)).

Hope that helps!

Hi, would you know how to connect the code in this tutorial to the quests video you did on Youtube? The way I want this to work is when I go up to talk to someone and choose to do something through the dialogue, a quest will start. Thanks.

in theory you could easily have an "if" statement so...... if (questActive = true) { quest_code} and use the script in the dialogue tutorial to trigger... im a pretty new to GMS2 language though.. 

Where would you write this? How would I set this up?

Thank you so much for this system, i’ve implemented it into my game, the only thing i’ve been trying to figure out is how to save the dialogue using ini, do you know how i would go about doing this?

FC, this tool is amazing!

Is there a way to have it so both Keyboard and Gamepad controls can work with this script?

As it is set up now, the variables for the controls are simply set to key constants and and Ord function. Which is connected to keyboard checks.

A gamepad button check works a bit differently as it also needs the controller device. So it basically needs two variables instead of one. Simply have, say, interact_key = gp_face2 will make the game crash if a gamepad is no connected. So changing the script works for either Keyboard or Gamepad, but not both.

I've been trying to mess around with the code to find the best possible solution. Is there something that can be done here?

Cheers

I know this is probably 2 years too late, but I recently discovered this dialogue engine and wanted to do the exact same thing - and after some messing around I've managed to come up with a solution! If it's of any benefit to you (or anyone else) I can explain how I did it?

Never a thing such as too late! I hope :)

Would love to hear your solution

No problem :)

Firstly I have a simple script for collecting inputs - it covers all the standard gamepad inputs etc. but for this the only ones that matter are :

scr_getinput()

KeyUp = keyboard_check_pressed(vk_up)or gamepad_axis_value(0, gp_axislv) < -0.40;

KeyDown = keyboard_check_pressed(vk_down)or gamepad_axis_value(0, gp_axislv) >  0.40;

KeySQButton = gamepad_button_check_pressed(0, gp_face3) or keyboard_check_pressed(ord('Z'));


Next I changed the create event for obj_textbox and par_speaker as follows:

obj_textbox (create)

if(instance_number(obj_textevent)>1 or instance_number(obj_textbox)>1){ instance_destroy(); exit; }

scr_getinput();

//-----------Customise (FOR USER)

interact_key        = false;       

up_key              = KeyUp;        //for dialogue choices

down_key            = KeyDown;      //for dialogue choices

par_speaker (create)

//-----------Customise (FOR USER)

scr_getinput();

playerobject = obj_player;

interact_key = false;


Then I altered the step events like so - I added this at the beginning:

scr_getinput();

if (KeySQButton !=0)

    interact_key = true;

else

    interact_key = false;


Then I changed each instance of "keyboard_check_pressed(interact_key)" to "interact_key == true" and replaced "var change_choice = keyboard_check_pressed(down_key) - keyboard_check_pressed(up_key);" with "var change_choice = KeyDown - KeyUp;"


There are probably better ways of doing it - but it works! :)

This is amazing. The devs should pin this to their FAQ or something. Great work and thank you

(1 edit)

The sytem is fantastic, but I noticed some strange issue that may cause a lot of problem.
In fact, whenever I switch the game to full screen mode any dialogue that should trigger will not show up, but still will be going ( I hear the voice of the dialogue and can even interact with choiche type dialogues). I think it is only a graphical issue. I am working on GMS2.
Hope that you can solve this problem, I would be really gratefull to you.
P.S. I don't speak english that well, so please forgive me if I wrote something wrong :)

Deleted 2 years ago

Found out how to fix this, have a general global game object.

At the create event put this code: (This will get the width and height of you camera, here the camera is 0)

var _view_width = camera_get_view_width(view_camera[0]);
var _view_height = camera_get_view_height(view_camera[0]);
display_set_gui_size(_view_width, _view_height);

Then at obj_textbox, go to create event and change the scale variable to something that will fit your size, according to your viewport settings.

You will also need to change the fnt_dialogue size to make it fit as well.

could be her code for gui height and width doesnt like your code for resolution scaling.. without an error code or visibly seeing your structure.. my thoughts are you have two codes to get gui scale in different places

(1 edit)

When I go to talk to the object it says, "Just a little monologue" and not the actual dialogue from obj_examplchar. Please let me know what is wrong, thank you! Also what do you mean by "the correct input key", isn't there only one you use?

I have the same problem too

hello?

The asset works well for me, are you using the correct input key to interact with the obj_examplchar? 

ohhh yes I have... I have looked over everything countless times and it still doesn't work!

(1 edit)

do you have any error codes to paste?

Deleted 2 years ago
Deleted 2 years ago
Viewing most recent comments 1 to 40 of 60 · Next page · Last page