NokiMo
yekkusu
yekkusu

patreon


Development Update #27 - Gallery

Hey there guys, I'm here today tot alk about the gallery.

After a month and a half working tirelessly on the project, I'm not at a point where I only need to (probably, not sure yet), to copy-paste the code and change certain names and all the sections will "Work".


By work I mean: Animations work, buttons work, everything works.

However, there's still the 'Day' part of it. Where I should put the signals of when a Background is Unlocked? When you as a player should be able to see any portrait in the gallery? 

I do need to create the Save system for the gallery to save the correct data, so how should I do that?

So, just because you can see bellow a gif of the gallery "Working" that doesn't mean it's completed yet. By now, it's like 40% done. I still need to add the other two sections and this would be more 20%. Then it's all code.


I'm really satisfied with the system, however. It's like, 75% automatic by now. I only need to duplicate a certain node if I add more backgrounds and I do need to add the path for the backgrounds to the code manually. I tried doing it via code (Accessing the assets and all via Godot code) but when the game is compiled, all the assets got converted to a data that only Godot can interpret, and it loses the ability to navigate through folders, it's weird, but that's it. Not everything is flowers, right?


When I was checking the buttons, I wanted the backgrounds to be added automatically to the buttons, and I was able to do that. The second step would be when you clicked a button, the "Path" of the correct background should be returned to the system. I tried this a bunch of ways. Adding the Path to the label on the button, but it was impossible to get the label of the button back via code without some weird shenanigans, Then since all the paths are saved on a list, I tried to get the Id of the button, since the list would go from 0 to 14 right now, all I needed to do was to get the ID of the button and I could access the correct path right? Like AcessListofBackgrounds[idbutton]. Then I noticed when I finally was able to do that, that the second row was giving the same backgrounds as the first. After some coding, I found a small mistake and fixed it. I was being a silly tiger putting the ID index who was incrementing each loop inside the main loop.


To be technical here, the rows works like this:

Row1>Button1,Button2,Button3,Button4.

Then I need to duplicate Row1, this will make a copy named Row2.

To add the images correctly inside the buttons automatically via code, I need two loops.

One to navigate through the Rows, and another one to navigate through the buttons.

But, since the IDButton = 0 variable was inside the first loop, he was always being reset to 0 every time the second loop finished and we got back to the first one.


After I noticed this silly mistake and fixed it by moving the variable two lines above, the gallery behaves like down bellow.

And of course, you may have noticed that every Row has 4 buttons, but the last row on the gifs has only three buttons right? Well, by being a clever tiger, I added a condition inside the loop where the images are added to the buttons, that if the ID that adds the image is bigger than the size of the list with backgrounds, nothing should occur, and instead of trying to add an inexistent image, the code would delete the button instead. Since it's inside a loop, the core will try to add more images as long as there are Rows with Buttons remaining. So even if I do something dumb like adding seven more rows for no reason, the only issue you guys would find would be an empty scrollable area. I'm quite happy I was able to delete the buttons inside the loop that adds all the thumbnails (They are the actual backgrounds shrunk via code), instead of outside of it. The less extra code I have to do, the less "loading" the game will have when you open it. I want to avoid making the game too heavy because I'm not as good as I wanted to be when I write the code.


With every button working correctly and giving me the correct background path, now I just needed to make the full image to appear.

I will use the same node to show every image for you guys, I'll probably do some tweaks here and there, but that's it. I will start working tomorrow after I finish all my duties outside the game, to star the Characters gallery.


I pretend to create the new alpha with the new Gallery done if possible.

It will take a while but I'll add more gifs here and there to show you guys the news. 


Since the game doesn't have any new story content yet, I don't see a reason to make an alpha right away.




And I have a very special Credits done too!

While I was stuck on the gallery creation, I decided to make this update. It's all images now!

I'm pretty sure it's possible to create a font set on Godot instead of using images to do something like that, however, since Godot 3.1 doesn't have the best Rich Text coding, I prefer to make those images instead!


And there's one more thing: Wagner's an amazing person. He's helping me with this project receiving way less than he should for his help. So I can't bother him with issues on the Day Editor. That's why after I finish the gallery project, I'll upload an alpha for all Tier2+ Patrons and then I'll start making my own Day Editor with QtCreator.

I love how Wagner made the new editor so cool and good looking, but since that's a project who was dropped, it's now showing it's issued. I can't bother him with this so I will need to make a Day Creator and Editor by myself. I will continue with the Dev Updates so you all can see what's being made by myself. I'm just glad that QTCreator has the best documentation ever. So I will be able to do it with so many issues however this will take its time.

I really wish I could work every single day in this game, all the time. But as long as more patrons won't come to this project and help at least as a Tier 1, or, like you guys always hear me saying, as long as I don't get enough money to make a living off this game, I can't work only on it.



Now a very important message:

I'm sorry for not being able to make the Monthly thanks message guys. Since I'm so out of time and my life is a roller coaster those last months, I'm opening this post to every single patron and nonpatron. This way everyone who helps with the project, everyone who helped the project and everyone who maybe think about helping me can check about the visual upgrades and systems right now, and of course, they can see their names on the credits.


Well guys, thank you so much for your time, for your help every month and let's hope together that more people will start helping so I can have enough money to pay for music and sound effects for this game! 


Anyway guys, have a nice week and a good new year!  

Development Update #27 - Gallery

Related Creators