i've been playing too much Triforce Heroes lately. Let's pretend Red forgot that handy Fire Rod or else this would not be happening lol. I dunno man they're on vacation or something he probably forgot it. Why are they vacationing in Hytopia??? Why did Vio stay behind??? I dunno man. Reasons. On an ENTIRELY unrelated-actually-kinda-related note, READ THIS FIC! Its a four swords x Triforce Heroes crossover (You don't need to know TH to understand it) Its good!
This idea came to me one fine morning (1am....) and i hastily sketched the entire thing out, slept, and finished it two days later. I'm not super happy with some of the panels here but imma leave it be cause the purpose of this isn't to be the greatest work i've ever made lol. Until next time y'all!
Anya is live and ready to show you everything. Watch her strip, dance, and perform exclusive shows just for you. Interact in real-time and make your fantasies come true.
✓ Live Streaming✓ Interactive Chat✓ Private Shows✓ HD Quality
Anya is LIVE right now
FREE
Free to watch • No registration required • HD streaming
If only you knew the pain I've been going through with cameras in Game Maker Studio for the past few weeks! But it's fine, I've got it all figured out now. This post is going to be a pretty long one. To be honest, there are a lot of little things I've done since the last post that I'm just going to either gloss over or save for a different post (maybe?) Primarily trying to standardize my code, resizing my sprites again, and hitbox thingzzz.
Anyways let's get into CAMERAS!
So game cameras were a little bit of an enigma for me going into this. From application surfaces to resolution, to window size... Quite frankly, they're very powerful tools when it comes to building a game, and all the stuff you can control with GameMaker's camera was frankly-
a massive headache.
Come down the rabbit hole with me-
TRIGGER ZONES
First things first, I had to get the camera set up. There are a lot of tutorials on this, all of which are slightly different. My code ended up somewhere in the middle of all of them. Here was the first tutorial I followed:
How to make a Camera for any GameMaker game in 4 minutes
by Shaun Spalding
So Shaun Spaulding's video helped me get the camera set up in the first place, although frankly, this method didn't last very long in my project. It was good and simple but for whatever reason, people really don't recommend you use GameMaker Studio's Room Builder's camera settings, but rather code them yourself. I'm not sure why else other than the fact you get a lot more control over your game's in-game camera, resolution, and window size, plus you can create cutscenes and stuff with it. Next was-
Smooth Camera Tutorial + Pan/Zoom [GameMaker Studio 2]
by Matharoo
Matharoo's code was more complicated at first but it gives you that level of control that I was just talking about, and it sets it up in mostly the same way. Although, my code now is definitely a mash-up of the two tutorials.
With those two tutorials, now our camera looks like this:
This is great! Now we have an actual camera instead of looking at the whole room! But if we look at our camera's view, we can see that the camera is seeing out of bounds. Matharoo's video may have actually covered this (you can watch it yourself) but where I found my solution was-
Camera Modes | GameMaker Studio 2
by FriendlyCosmonaut (this one starts at 14:33)
I did not watch this entire video but it looks like it has a lot of useful information in it. Even though she isn't making the same type of game in the video, she does cover the topic I needed, which the provided link will actually jump straight to that section of the video
This is solid! Now that we have one problem solved, it's time for another-
Unless you're going for something more old-school like Super Metroid, we're likely going to have big open rooms that twist in multiple directions. I had a pretty clear vision of how I wanted the camera to operate. My trajectory is in the direction of Hollow Knight, which has a simple yet complex camera system that is very well explained in this YouTube video:
This video sort of became my "mission statement" with all this. Unfortunately, I don't have a tutorial I can point to for how I coded all the stuff in this video, but I did realize Shaun Spalding briefly touched on his own solution to this kind of problem with what he called "trigger zones". This is a good way to describe my own solution. Essentially we're going to create an array of overlay objects, or "trigger zones" that will restrict the camera's movement to only being able to move where they say. This is more or less the setup we're looking at:
This is how Hollow Knight's cameras appear to be working in the video, and how we'll set them up too. I won't dive too deep into the nitty-gritty coding on this one, but basically, each of these trigger zones is an object in GameMaker that will bind the camera by their respective dimensions.
This gets very inter-relational with all these objects since each object needs to be able to apply its own unique dimensions to the camera boundaries. It did become a little bit of a headache managing what turned into 5 or 6 different camera-related objects which were all modifying each other.
Here are some pictures of how this looks in practice. Keep in mind that these would all be turned on at once to function properly:
Vertical Trigger Zones
(the camera won't move above or below the zone the player is in)
Horizontal Trigger Zones
(the camera won't move too far left or right in these zones)
Zoom-In (or Zoom-Out) Zone
(the camera will zoom in/out as far/close as the width of this zone)
These are just a few examples but hopefully, the concept makes some sense to you! So finally, with these systems in place, our cameras will finally move like this:
And that is (mostly) the end of that. Scope creep has kept me coming back and adding incremental changes to all these features (specifically the zoom one). Fundamentally they will continue to work the same but it's easy to keep tuning things like camera speed and zoom speed.
Anyways, with this stuff done it's time to get to the next thing:
PARALLAX HELL
So the actual solution to this was straightforward--use a 3D camera and follow this tutorial:
From 2D to 2.5D: GameMaker Studio 2 TUTORIAL (Using 3D Camera) | Easy Parallax
by Matharoo
It's what Hallow Knight does, it creates a natural parallax effect, and it makes a lot of the artistic work pretty easy. But, the reason it took me so long to get here is a story that brings me great pain...
To start, I wasn't originally going to use a 3D camera because they sounded somewhat complicated. Even Shaun Spaulding sounded like he didn't recommend them in his tutorial that I shared above (although maybe that's just for beginners). What I was going to do could be called "interpolated parallax," where we are basically moving a bunch of image layers around relative to the position of the camera.
You can learn more about this in this video by Pixelated Pope.
That doesn't really need to make sense to you, but that's what I was doing. Now, this method could have totally worked theoretically if it weren't for the fact that GameMaker Studio 2 has actually removed certain coding properties from GameMaker 1.4, which makes this method kinda unreasonably difficult? At least from what I tested. It works great if your only intention is to have an endless runner game or if you want to accommodate for open space by drawing individual sections of background together in a giant 4k+ canvas.
It sounded messy and I didn't really want to deal with it. Eventually, I learned more and more about GameMaker Studio's 3D camera, which was easy to set up for my specific needs.
It did take a while to fine-tune it all but I did get there in the end. It did, however, break my zooming trigger zone. This post is already long enough but basically, I thought the solution would be needing to change the camera's field of view with trigonometry when it was actually just changing the camera's distance with a basic ratio...
Not my brightest moment there and it took a painful couple of hours of staring at the same code and Desmos to figure that out.
ANYWAYS...
The camera system is finished! Or at least, finished enough that I can move on to designing backgrounds, and just fine-tune this bit by bit later down the line.
Honestly, this was all very time-consuming, and the struggles with the zooming trigger zone were a bit demoralizing, so I'm ready to get back into the art generation side of things!
I also plan to spend some time beating Hallow Knight and maybe a few other platformers I can take reference from for backgrounds 😎
One of my classes is so damn hot, but not in an oven way, or even in a muggy misery fest. Its just evil. I can barely sense the heat, but I feel it, emotionally. Its like a demonic curse or smth. fml.
Anya is live and ready to show you everything. Watch her strip, dance, and perform exclusive shows just for you. Interact in real-time and make your fantasies come true.
✓ Live Streaming✓ Interactive Chat✓ Private Shows✓ HD Quality
Anya is LIVE right now
FREE
Free to watch • No registration required • HD streaming