Game
Rogue Cadet
9 years ago

Day 84


Day 84: Today I thought I would finish the tutorial. I didn’t even start it… BUT that doesn’t mean I didn’t do anything today. It’s just that there were unplanned stuff. Oh this morning a friend of mine posted a stuff telling people to not die. So I learned about the crude death rate and used it to calculate the approximate number of people that died since the time he posted that tweet. That’s 6837 death per hour FYI. I have weird hobbies (and I might be a terrible friend).

Daily interesting stuff:

Tasks done:

  • Implemented an introduction. It took a lot of time. But it’s not that great. It’s just some text on a black screen. The text has a letter by letter anim though. And there’s fadeout between sentences. I tried to keep it as short as possible. It’s just a placeholder to talk a bit about the story. One thing that was super annoying is the problem I had with responsive text and animations. See, in Unity to have adaptive text, you just have to check a “best fit” bool and the text will be as big as possible within its box. And it works great, really. But the catch is that is when you change the text letter by letter like I do, the size change as the string length do… And I didn’t find how to do a custom best fit. There was no information what so ever on how it’s calculated. Oh there’s an access to the calculated value. So I thought I just had to get it at start then set manually the font size to that, then disable the best fit. WRONG. Because the calculated value is only available two frames after start. So if I want to get the size I need to leave the text for two frames and so it looks like it’s flashing… In the end I did an ugly component that takes a default font size and scale it based on the width of the screen. So I give it it the font size found by testing values in the editor in 1080p and it adapts it at start for any resolution. I just hope I won’t have to handle a resolution change while I’m in the middle of the introduction…

  • Put the FileSaveLoad class to its own file. I don’t know why I put it on the SaveData file until now. Seriously this makes no sense and I spent time searching for it three time already! So I changed it. It took like one minute.
    Saved the current scene index. In the main menu, the play button would always launch the game scene. That’s not what I want. I want that the first time it launches the introduction for example. So I did a simple script that saves the current scene in the save file at start. If I don’t want to save the scene (like for the main menu) I just don’t attach the script to any object.

  • Implemented the new save creation. Now if there’s no save at the start of the game, it will create one with the appropriate initial values. This is important, because until now, I was using my debug tool to create and modify the save. Now it’ll also work for the player.



0 comments

Loading...

Next up

So

i may or may not make an full art of some person or i may just leave this like that-

Bandana Dee the Dream Friend

Protege el conocimiento, salva la historia. Guardian of Lore es un platformer 2D en el que debes luchar para mantener viva la memoria de la mitología latinoamericana. El juego llegará a Steam el 18 de mayo: https://steam.pm/app/1211740 #ScreenshotSaturday

Terraria

Call it 'wrong turn'!🚫 The feeling of running into a house with only one exit🚪, and being doomed to die. #pixelart #pixelartist #pixelartwork #art #pixel #indiegame #IndieGameDev #indieartist

I made a small jungle house.

Respect (Only TLOZ Players Will Understand)

This is my first post so be gentle!

Hoplegs is an unconventional and entertaining platformer where the gamepad buttons are your legs! Create and share your own levels, challenge your friends, and have fun!

Wishlist on Steam

https://store.steampowered.com/app/1395830/Hoplegs/

Where is Spider-man?