Depth according to the GMS 2’s manual is slower than using layers. In fact, if we assign an object a depth, GMS 2 will automatically create a layer and manage it for us, giving one no access to this said layer. GMS 2 will not let us mix depths and layers. Though we can use a depth variable in GMS 2, the engine prefers to use layers instead. If we want that illusion of fake 3D in a 2D game, we can take an object’s y position, which is larger the farther the object is from the origin, and negate the y value, thus, being closer to the camera. Using an inverted y axis (like most game engines do), the farther down an object is in a room, the larger its y variable will be. An easy way to give this illusion in Game Maker was to set an object’s depth to -y. Objects drawn at a smaller depth will be drawn closer to the camera versus objects with a higher depth. In GMS 1.4, every object has a depth variable. To give an illusion of a 3D perspective in a 2D game, objects need to have some kind of depth to them. I think my biggest issue is how layers work with objects and the rendering order. It also solves the problem with tiles as that we can have multiple tiles on multiple layers. On one hand, it solved my problem of these assets as when we say “asset group”, we mean a layer. I have mixed feelings about this new function. The final big feature that GMS 2 added was a new concept called layers. Thus, we can toggle an asset group called assets_2_1 and turn that layer on. For example, if our camera’s position is in location (2000, 1000), i would be 2 and j would be 1. To do this, a zone name can be defined as assets_i_j, where i is the camera’s left position over 960, rounded down, and j is the camera’s top position over 960, rounded down. We will always load the zone the camera is in, plus a few surrounding zones. These grids are loaded into the game based on the camera’s position. We defined a zone as a 960 x 960 pixel grid. The way we solved loading all the assets at once is to break up the entire open world into zones. But, loading an entire open world of these assets would surely cause any game to crawl to a screeching halt. Computers are pretty fast now compared to what they used to be. With the open world, we needed a way to turn these assets on and off. However, GMS 2 solves this by having what is known as assets, which are graphics with no other interactions. When coming up with the idea of the decor tiles out with GMS 1.4, they were taking a performance hit due to how GMS 1.4 handled tiles. Decor tiles are pretty similar to standard tiles, except these tiles can be scaled and animated, unlike traditional tiles that are on a standard grid. This is really useful for the game as I can start using tiles for backgrounds, and not take a performance hit, which was happening in GMS 1.4.Īlong the lines of tiles, I had created a concept called decor tiles. The tile engine in GMS 2 is much faster now, supporting tile maps too. Tiles are exactly what they sound like, squares in a game that represent some graphic. Violet the Game is using a tile grid, much like many games in this genre. GMS 2 completely redid the way they handled tiles, and for the better. Finally, there were a few new core features that GMS 2 has that I was really needing. Being very ambitious, GMS 2 supports the Nintendo Switch - and I would love for Mario to play my game someday. Secondly, GMS 2’s device support is much better than GMS 1.4. I figured it would be a good time to start using GMS 2 and learning the new interface. For one, my leave of absence is coming up soon. I decided about a month ago that it would be a good time to start porting. Thus, I started making the game originally in GMS 1.4. The last thing I wanted to do was learn a new interface while building out game ideas. When I was first coming up with the initial ideas of the game, I wanted to quickly get my ideas in code, much like how writers gets their thoughts down on paper. I did this because of how similar GMS 1.4’s interface was to what I used to use when I was a kid. In my about page, I mentioned that I started building the game in Game Maker Studio (GMS) 1.4. However, it’s been a little over a month since my first post, and I wanted to give an update on what I have been doing. I was leery to make my second post be a more technical one.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |