NokiMo
yekkusu
yekkusu

patreon


Development Update #30 - The JSON/DayScript Editor - 1

 

Hello there!

How are you all doing? I'm fine and working a lot in those last weeks.

After some time trying to deal with the QT Creator which has the best documentation I've ever seen in my life but the worst visual editor for a software in the planet, I decided to talk a little with the lead artist of my game, he's an amazing programmer too so he said: "Why not check if it's possible on Godot?" and I remembered, Godot does have a part specifically made for Software.

Lemme explain: Godot has three types of nodes.

The first type of node is the first they developed, the Spatial node. It's a special type of node to work with 3D projects. 

The second one is the Node2D types, it's the type of nodes I use for Just Friends.

And the third type is the Control node. This node is used for user interfaces, and it's the node I use to make the Gallery for you guys on the game.

If this node can create a User Interface then, I decided to check all the children of a Control node on Godot. I discovered that it has everything I need, from an Open File Window to pop-ups, select buttons, menu buttons, etc. 

So, after five days getting really angry with the UI system on Qt Creator, I decided to try to make the Day Editor on Godot itself. To be more precise, inside the game itself. This would mean some good things: First, I'm already familiarized with Godot, even if Godot doesn't have good documentation, I already know how to Open and Save files on Godot, I do it for the Gallery, Save, etc. And I already have a good experience with User Interfaces when I created the Gallery. The best part is that I won't need to make something specific like the Gallery because it's something aside from the game. Even if it uses the same project, the Day Editor won't be packed on any Alpha, because it's not necessary for the game to run.

So I started the project, and as much as I wanted the UI system to be fast and simple, there's a ton of conditions for the system to work. 

First, I decided what type of nodes I would use. I don't want to create anything from scratch, because I need to finish this by a month at most. 


So I decided to use some Line edits each one with one button for Edition and Deletion of the node. It was a pain to make the delete work because of some shenanigans, but thankfully the lead artist also had some similar issue months ago and he explained a quick way to make sure everything would work. 


After that, I decided to make the Delete to work only when the edit was pressed. This way I would never delete something I shouldn't. However soon this approach made me see some problems. I would have to click Edit on every line Edit button to be able to Delete something. But I would also need to click on Edit to be able to edit the Dialogs, then the same on the dialogs and so on. That would not be fast.

So after trying to mess with the Dialog nodes using buttons, I decided to study how the Line Edit node was useable, and after checking how the old Editor made on Electron (It wasn't done for me, nor by me), I noticed that the Line Edit does have a lot of similarities to the ones made on Electron. I had to mess with the files for a while, read the documentation and of course, check all the signals the node has (GODOT has an issue on its documentation - It does never shows the functions of a father node. It means that if a node comes from another node, for example, Canvas Item, it does inherit all the functions of Canvas Item for example. But this is not listed on the documentation, making it difficult to discover if I can use a function that already exists just by looking at the documentation).

After some time I was able to make the Line Edit behave the way I needed, and then I was able to set all the conditions to that. Every single node on the Editor will be Line Edits but, the Line Edits does behave a little like a button now too. When I click on it, I need to click Edit to edit the text on it but only for the routes. And every route I add will be enabled for edition right away. 

If I press Enter without a name, an error will display. If I try to name the route the same name as any other route, an error will be displayed. If I try to click outside of the route on another route (this will make the current route un-editable again) and there's not a name on the route or the name is the same as the other route, the error will be displayed again. 

The same happens for Dialogs and so on.


Now I'm working on the Dialogs. They are a little more tricky to work with but I'm thinking a lot to make everything works right before I start coding the JSON data itself.

One of the best things I was able to make right now was the Dialog window. Since I'm using Godot and specifically using assets from my game to make it, I can make a Dialog edit with the exact same size and font of the main game. This means an overflow issue will never


I still need to make all the programming on this new Edit Dialog Window.

And after that, I need to make every dialog to open this window with the correct information I've put before. And I need to make sure every "route" has a set of dialogs of its own.

After that I will need only to do the last two parts of the editor to work, then I will start coding the "open" file and "Save" file for the editor. I need to do it as fast as possible, but let's hope I finish this as soon as possible.

Next month, day 1 I start working on the Karnal's next day, with or without this editor done. Don't worry about it. This game won't stop, and I will make it the best game ever, I promise you guys. 

So, I tried to explain what I'm doing this month, and I hope you guys understand that this is a necessary step for the game. Right now, if I keep using the current Day Editor, as much beautiful as it is right now, I won't be able to do a lot of stuff I need with it in the future, and of course, after the Day 3 fiasco with Wagner's route, I don't want to cry because the editor hates me.

Anyway guys, have a nice week and don't forget to share this patreon on your social media if possible, to help more people know about this project and maybe even help by becoming new patrons.

Thank you all for your time, and have a nice week!

Development Update #30 - The JSON/DayScript Editor - 1

Related Creators