Looks like you're not logged in

Login or Register to continue

Lesson Q&A

Use this space for questions related to what you're learning. For any other type of support (website, learning platform, payments, etc...) please get in touch using the contact form.

  • Trying to assign a value of type 'String' to a variable of type 'Dictionary'willywilsonI've double checked that my code for Main.gd and ScenePlayer.gd match the example shown here, but I'm received an error message when I try to compile that states "Trying to assign a value of type 'String' to a variable of type 'Dictionary' " Whilst citing the str2var line in the load_scene function. Does anyone know what might be causing this? 1 0 Mar. 21, 2023
  • Suggestions for the Next VersionalandoveI decided to start the 2D course with this chapter, because I'm a writer by trade and certainly want to understand dialogue systems as I begin developing games. This was an excellent tutorial that taught me a lot. If you decide to revise this course in the future, I have two suggestions. First, viewed solely as a teaching tool, this tutorial is doing a great job as it is. However, if people come into it expecting to get a good start on building their own full-fledged visual novels, they may end up disappointed or overwhelmed by the amount of additional work they'll need to do to get there. Looking at previous comments, I think you've already seen some of those reactions. While you've done a great job keeping concerns separated and structuring the code for scalability, any visual novel longer than a few lines is going to be excruciating to write in your current data format. Writers just don't work that way. That means aspiring visual novelists will need to first rework the format, in turn recoding the Scene Player, and pretty soon they'll be reinventing Ren'Py from scratch. I realize you may be reluctant to introduce plugins you don't control in these tutorials, but it seems like they're an important part of game development, and this chapter could be an excellent place to teach best practices for working with and extending them. You mention Dialogic, but I also recommend looking into Ink, a fully developed dialogue middleware system capable of handling huge, highly-branched choice-based stories. Ink already powers several well-regarded indie games on the market, and there are two well-supported Godot plugins for parsing Ink files, one in C# and the other mainly in GDScript. Both are under permissive open source licenses. Ink files are also very writer-friendly, and keep the story text separate from the presentation. Please give it some thought. My second suggestion is to change the terminology in this chapter. Referring to dialogue "scenes" and "nodes" that are in no way related to Godot Scenes and Nodes is confusing. How about "acts" or "beats" and "lines?" Despite my criticisms, I want to emphasize that this was a great learning experience. I'm looking forward to working my way through the rest of this course in the coming weeks. Thanks! 2 0 Dec. 30, 2021
  • Exported version of the game can't runLeafHello! I went through the course and made a game based off its codebase. Everything went fine and the game is fully functional in-engine but when I try to export it to an .exe application, launching it results in a crash (or a black screen if it's the Debug version) - I never had this problem before and I made several small games in Godot. This is what the Debug console tells me : ERROR: File must be opened before use. At: core/bind/core_bind.cpp:2127 SCRIPT ERROR: ScenePlayer.load_scene: Trying to assign value of type 'String' to a variable of type 'Dictionary'. At: res://ScenePlayer.gdc:178 SCRIPT ERROR: ScenePlayer.run_scene: Invalid get index '0' (on base: 'Array'). At: <res://ScenePlayer.gdc:56> I don't understand where things could've gone wrong, as my load_scene(), _store_scene_data() and overall "scene creation" system are identical to yours. Thanks in advance for your help! 5 0 Sep. 26, 2021
  • RE: Closing ThoughtsjbsoumThanks for a great tutorial! I feel like I've learned a lot since I started this one. Here's a question. In terms of story editors, I've seen both Twine and Dialogic mentioned as options for drafting scenes. What's the latest recommended path forward there? Is it Twine? Dialogic? Something completely different like a spreadsheet or SQL? I'm just curious. I downloaded Twine and started playing around with it, but if there are any recommended paths and / or associated guides, I'd appreciate it! 1 0 Aug. 18, 2021
  • Error at the _store_scene_data functionMathieu01In this function: ```gdscript func _store_scene_data(data: Dictionary, path: String) -> void: #... file.store_string(var2str(_scene_data)) #... ``` The variable used in var2str() should be data instead of _scene_data, right ? Otherwise, the data parameter is useless. 1 0 Feb. 27, 2021
  • Error in this sentenceMathieu01I think there is an error in this sentence: > We use the GDScript built-in function `str2var()` to convert a file’s content into a dictionary. Shouldn't be var2str() instead of str2var() ? 3 0 Feb. 27, 2021
Site is in BETA!found a bug?