SweptForums
Official Media Thread - Printable Version

+- SweptForums (https://forums.sweptthr.one)
+-- Forum: Tale of Flocksworth Zone (https://forums.sweptthr.one/forum-38.html)
+--- Forum: Discussion (https://forums.sweptthr.one/forum-40.html)
+--- Thread: Official Media Thread (/thread-76.html)



Official Media Thread - SweptThrone - 07-03-2023

Week of June 25, 2023

Movement Test



This week I put together a super basic movement test.  The sprite animates based on the direction the player is moving.  The player's current movement speed is controlled by a variable that can be changed mid-game.

This would've been done sooner if I were a lot less lazy.  It's not really engaging to do the absolute basics and I'd rather be working on the fun parts of the game, but obviously this has to be done before all of that.  I'm also learning a whole new language to work with the engine I've decided to use - Godot - so that's taking a good amount of effort as well.  Furthermore, I'm trying to do things in a way that will make it easier to work with in the future so that I don't have to rewrite the entire player class once the game's in its further stages, for example.


RE: Official Media Thread - SweptThrone - 07-16-2023

Week of July 9, 2023

Tile Test

[Image: tofmedia2.png]

This week I made a simple random terrain generator with three terrain types. It's currently fully random with no regard to anything around it nor any weighted chances.

This came with the side effect of me needing to learn how to programmatically add tiles to the world, or in Godot terms, add scenes to a scene. I don't really like the whole idea of calling everything a scene. In my mind, the world would be my scene and a tile would be an object, but oh well! Anyway, the player "scene" in the movement test was about ten times larger than it should've been, meaning any time the player was on screen, it would always be that large unless scaled down. This was clearly just an inconvenience, so I reset the scale. Also for some reason, Godot decides that your nodes should be centered in the scene, meaning the position (0, 0) for any object was its center. Thankfully there's a checkbox to change this, but being centered is default behavior. You can see the player demonstrating a very basic pass of Z-indexing, where you'll be occluded by trees in front of you. This doesn't work quite right yet, but I'm getting there. The trees are also just another tile object located 96 pixels above the tile it's on. I don't know if this is a bad idea yet or not, but for now it's what I'm doing.


RE: Official Media Thread - SweptThrone - 07-23-2023

Week of July 16, 2023

Z-Indexing and Directional Idle

[Image: tofmedia3.png]

This week I made the player appear "behind" trees that are "in front of" the player and gave the player directional idle animations. The attached image shows the player partially occluded by one tree and in front of another. The triangle also represents the direction in which the player is idle.

Truthfully I'm not moving at a pace that I'm terribly happy with, but right now it's all kind of boring to work on. It's also incredibly overwhelming when I think of the length of and amount of content in other similar-ish games, how I'm going to implement a story into mine that I'll be happy with, how to make it fun, and how to keep you the player entertained enough to play it. I feel like the type of game I want to make is a bit strange and not something that's usually done, but maybe I should use that as motivation to prove that it can be done. The fun factor is a really big one, because I've learned over the years that what I find fun isn't usually fun to most other people. We'll see where this goes, but it will go somewhere.


RE: Official Media Thread - SweptThrone - 09-10-2023

Week of September 3, 2023

Collision Test



The past few weeks have been dedicated to setting up basic collision between the player and "props," of which there are currently only two:  rocks and trees.  The video shows the player unable to walk through rocks and the bases of trees.

Originally, I had implemented my own movement system where the game would set the player's position by adding their velocity to their current position.  Turns out you need to use a special Godot function to move your entities if you want them to collide with things.  My fault for not following a tutorial all the way through!  I had some big issues with spawning props with their hitboxes because I didn't have a solid grasp on the parent/child relationships when it comes to positions.  Furthermore, I'm trying to figure out the optimal way to store data about props so that I don't have to set every value every time I spawn one.  I'm not quite Down With OOP yet so I'm kinda just winging it for now.
Also, I've been working on Garry's Mod stuff as well as Tale of Flocksworth because I want to.  Read more about that here.


RE: Official Media Thread - SweptThrone - 11-12-2023

Week of November 5, 2023

Path Generation Test



This week, I spent a lot of time optimizing what little code I had so far and creating a path generation function.  This video shows paths that are generated randomly and connected.  It also shows camera movement.

There's a lot wrong with the state of the game in the video right now.  Paths have a weird grass seam between them, the camera is always one frame behind the character, the whole game feels stuttery for some reason, and the image file for the path is a texture sheet of 256 textures, only 47 of which are actually used.  That's over 80% of an entire PNG image just being thrown away!  I tried getting smart with how I use the path texture, but I think I started trying to get too smart and now that's what I have.  As long as file sizes stay low enough, everything should be okay.  I also wrote a prototype for a gambling game that I want to appear in the game, which you can play here.  Money means nothing and is just a means to see how "balanced" the game is, even though the enemy player is very stupid.


RE: Official Media Thread - SweptThrone - 12-03-2023

Week of November 26, 2023

World Expansion Test



This week, I optimized a lot of my code and made a super primitive version of the infinite world generator.

Obviously you can see some pretty major problems with the game in that video. Paths don't connect between panels but more importantly, the game freezes every time a new panel is created. Panels also aren't unloaded when they're out of view, meaning the game continually chews up memory until something inevitably crashes. Besides that, there's a handful of behind-the-scenes problems that need to be looked at, such as a dump of red text that only happened one time. Other than that, however, progress has been pretty good. Keep in mind that this is only a media thread, so if you want more general progress on the game, go here.


RE: Official Media Thread - SweptThrone - 03-03-2024

Week of February 25, 2024

Panel Unloading Test



This week, I created a first pass at unloading panels to save on memory and increase performance.

It's been a while since the last media post mainly because I've been focusing on STRP and school. With STRP slowing down and spring break approaching, however, I'll probably be working more on ToF in the next few weeks. It should be obvious that this is not how the final game will unload panels. Right now I'm thinking about keeping the currently active panel and all adjacent panels in all eight directions loaded at once, but maybe I can make this a setting, like a render distance. Regardless of the small amount of work I've been putting into the game lately, I continue to add to my notes folder week after week.


RE: Official Media Thread - SweptThrone - 03-31-2024

Week of March 24, 2024

Quick Loading Prototype



A quick refresher on vocabulary:
  • Tile - One square of terrain.  Current types are grass and path.  Grass tiles can have a tree or a rock on them.
  • Panel - 1024 squares of terrain arranged in a 32x32 grid.  Worlds are saved panel-by-panel.

This week, I sped up the process of loading panels.  There is now no lag spike when entering a new panel.

This milestone has been a long time coming, and I'm overjoyed that I was finally able to reach it.  This took several days of research as to why there was even a lag spike in the first place.  My first bit of research seemed to imply that it had nothing to do with the number of things I was spawning per frame, as I read people mentioning that they could create hundreds of objects without any lag.  As I kept looking, I saw someone have a eureka moment about the AddChild method introducing performance issues, but I couldn't just get rid of it.  I tried multi-threading and using Godot's CallDeferred method, neither of which worked.  Eventually I resorted to writing my own delayed world loader and that's where we are currently.  As I kept thinking, I realized I was actually creating an average of 1'280 objects per frame which is a big difference from what others probably meant by "hundreds."
Obviously you can see that the rows load in like an image from the 90s.  Thankfully this is just the initial prototype and will be improved greatly as the game continues to progress. If you look closely, you can also notice that the seams between tiles are gone. This was a texture filtering setting within Godot that really shouldn't be enabled by default.