Assets in Megamix are divided into categories for easy reference (see the folder structure in the sidebar of the main GMS window). Note that these categories have no effect on how anything functions; they simply make it easier for you to find what you're looking for.
A few categories are subdivided by the game in which the assets first appeared; these include the first ten main games in the series (MM1 [which includes Powered Up
to MM10), Mega Man & Bass
(MM&B), the five Game Boy games (GBI-IV and GBV), Mega Man: The Wily Wars
(WW), the two DOS games (DOS), and Rockman & Forte: Challenger From the Future
Rooms (asset prefixes: lvl, rm) are where everything in the game takes place. The title screen is a Room. The credits screen is a room. Each hub in the MaGMML
games is its own Room. Levels are often one Room, but they may be made up of several Rooms; for example, MaGMML2
's "A Mega Man For All Seasons" uses a different Room for each season, and teleporters take the player from one Room to the next.
Megamix includes two premade rooms worth mentioning here. "lvlCopyThisRoom" is a template for creating your own levels and hubs. "rmInit" is a special Room that is required for the game to run; don't mess with it!
Because the default screen size is 256 pixels wide by 224 pixels high, Room width and height should be divisible by 256 and 224, respectively. This can be adjusted in the "settings" tab of the Room Properties window. Ideally, Rooms should be slightly larger than you actually need for your level (usually 1-2 screens of empty buffer space along the edges of the Room), in case you need to expand or reshape the level later on.
Objects (asset prefixes: prt, obj) are everything visible and invisible that make the game work and give the player things to interact with. Spikes, icy floors, conveyor belts, Metalls, the hippo miniboss, E-Tanks, Mega Buster bullets, Guts Man, the boulders Guts Man throws, the shrapnel from the boulders Guts Man throws, boss explosions, NPCs, NPC dialogue boxes, checkpoints, the autoscrolling gimmick, the invisible dividers that keep your screen from scrolling too far, the pause menu, and Mega Man himself are all examples of Objects.
There are several "Don't Use" subfolders, which contain Objects that work behind the scenes to make the engine function correctly. One example is "prtEntity", a parent Object that acts as a template for most of the things the player can interact with in a level. Unless you're designing your own game or investigating how the engine is coded, everything under "Don't Use" should be left alone.
Some Objects require helper Objects (such as "objGenericStopper" and "objFallingTowerStop") or customized Creation Code to operate correctly. If you're unsure how to use an object, either consult the documentation wiki
or open the Object's code. Many Objects have comments in their Create Event describing their function. If you see "@cc" in a comment, it means that information is included in a table on the documentation wiki.
It also helps if you've played or watched a playthrough of the Mega Man games represented in the engine; the Mega Man Knowledge Base
is a great resource if you want to learn more about how these Objects are used in the official games.
Sprites (asset prefix: spr) are graphics that represent Objects. A Sprite may have multiple frames (for example, "sprSplash", which is used to create the splash effect when certain Objects enter and exit water), and an Object may use multiple Sprites (for example, "objCrashMan" uses one Sprite for walking and another Sprite for jumping). You probably don't need to worry about Sprites unless you are modifying existing Objects or creating new ones.
TILESETS / BACKGROUNDS
Tilesets (asset prefix: tst) and Backgrounds (asset prefix: bg) are graphics used to decorate Rooms. Whereas Tilesets are broken into individual tiles that can be pieced together as you see fit, Backgrounds are intended to be used in their entirety, often with a scrolling or parallax effect (see the "backgrounds" tab in the Room Properties window and "objParallax"). Tilesets and Backgrounds are both found in the "Backgrounds" asset folder.
Note that Tilesets and Backgrounds are purely aesthetic; floor tiles aren't solid and spikes aren't hazardous unless you place the appropriate Objects.
It's good practice to place foreground and background graphics on different Tile Layers; you're less likely to tile over something by mistake that way. Also, some Objects interact with the tiles on a specific layer (for example, "objTileAnimation" and "objRevealingTiles").
Remember that Tile Layer is essentially the same thing as Depth (for Objects), and that graphics with lower numbers are displayed in front of graphics with higher numbers. Because most Objects have a Depth of 100 or less, the default Tile Layer is 1000000 to ensure that tiles never block the player's view. However, there are situations where you might want to place tiles in front of objects (for example, a secret passageway or a translucent fog effect covering the screen); a Tile Layer of -5 is usually ideal.
SOUNDS / MUSIC
Sounds (asset prefix: sfx) are sound effects intended to be played once or looped indefinitely. Sound assets are loaded directly into GMS. You probably don't need to worry about Sounds unless you are modifying existing Objects/Scripts or creating new ones.
Music (file types: .gbs, .nsf, .ogg, .spc, .vgm, .vgz) is saved externally in the datafiles/Music subfolder. Music is implemented by adding the "playMusic" script to a Room's Creation Code or by adding "objMusicChanger" to a Room.
Scripts (no prefix) are lines of code that perform special and often complicated functions. For example, "loopSFX" can be added to the code of an Object, Room, or Script to play a Sound on infinite repeat. Scripts are beneficial because they allow you to use a single line of code to run multiple lines of code.
For example, if you wanted an Object to instantly end the level, you could either use this complicated chunk of code...
assert(global.inGame, "Tried to end stage without being in a stage");
global.endStageOnRoomEnd = false;
global.timeStopped = false;
...or you could use the simpler "stageEnd" Script, which looks like this:
Both options perform the exact same function, but the Script is faster and easier to add, with less room for error. Another benefit of Scripts is being able to make changes to frequently used code without needing to manually update every single Object, Room, and Script that uses it.
Needless to say, you probably don't need to worry about Scripts unless your level or game uses a lot of custom code.