GORGON-EGG

GORGON-EGG

Download v1.0.0


GORGON-EGG is a replacement for GBAFE’s Panel setting unit window. With it, you can create windows like:

GORGON-EGG allows for windows of all shapes, sizes, and contents. Want a quarter-screen comprehensive panel of stats? Something more condensed than the vanilla window? How about something that isn’t a window at all? GORGON-EGG has you covered.

Most users will not have to do any programming in order to customize the window, but GORGON-EGG is designed such that it is easy for advanced users to add their own functionality.

How do I use GORGON-EGG in a project?

Most users should download GORGON-EGG from the releases page. The provided .zip file contains pre-built versions of GORGON-EGG’s internal tools.

GORGON-EGG is designed for use within an Event Assembler buildfile. It requires a few common tools (and a few bespoke ones) to be installed or placed into its tools folder before it can be used. See the README for more information.

After initial set-up, users can configure the window to their liking (see the section below!) before building GORGON-EGG. After building, simply #include the output/Installer.event file in your buildfile.

GORGON-EGG supports multiple games, and a config can have different variations of the window depending on the game.

Notes on supported games

GORGON-EGG supports the following games: FE6J, FE7U, FE7J, FE8U, and FE8J. By default, GORGON-EGG will try to determine which game it is being built for by examining the game ID passed in by Event Assembler.

You should define the current game by passing it to EA via the command line or by defining it in your buildfile before including GORGON-EGG.

For example, you can add the following to your EA invocation to specify that the game is FE7J: -D:_FE7J_=1 or you can add the following line to your buildfile: #define _FE7J_.

When building GORGON-EGG, your target for make should be the target game (written as lowercase text), like: make fe7j.

How do I configure GORGON-EGG?

Customizing a GORGON-EGG window is as easy as editing a text file, called the config. This TOML-formatted file controls what kinds of elements appear on the window, as well as controlling their appearance and behavior.

GORGON-EGG ships with many prepackaged elements for users to pick from, such as a variety of window shapes and sizes, different extension/retraction styles, tools for drawing various graphics, statistics, and text.

Config content breakdown

Here’s an example config, which we’ll break down:

Example config

[[config.modules]]
  name = "DrawStandard"

[[config.modules]]
  name = "TilemapStandard"

[[config.modules]]
  name = "MinimugStandard"

  [[config.definitions]]
    name = "MINIMUG_X"
    value = 1

  [[config.definitions]]
    name = "MINIMUG_Y"
    value = 1

[[config.modules]]
  name = "NameStandard"

  [[config.definitions]]
    name = "NAME_ALIGNMENT"
    value = "NAME_SHIFTED_RIGHT"

  [[config.definitions]]
    name = "NAME_X"
    value = 5

  [[config.definitions]]
    name = "NAME_Y"
    value = 1

[[config.modules]]
  name = "Affinity"

  [[config.definitions]]
    name = "AFFINITY_X"
    value = "5 * 8"

  [[config.definitions]]
    name = "AFFINITY_Y"
    value = "1 * 8"

[[config.modules]]
  name = "DrawStandard"

Modules can be used to add new elements to the window. A module is a bundle of code, graphics, data, etc. that adds some kind of feature, such as drawing a stat number or to control how the window is drawn. A module has one required key/value pair: a name key and the module’s name as a string.

The DrawStandard module causes the window to extend/retract horizontally from the corner of the screen when redrawn. The -Standard part of the module name here denotes that the module behaves (by default) how some vanilla element does. In the case of this module, it mimics how the vanilla window extends and retracts.

GORGON-EGG comes prepackaged with many modules, found in the modules folder. Modules include a README.md file that gives the module’s name, features, and customization options.


Customizing the functionality of a module typically involves overriding the module’s default definitions.

[[config.modules]]
  name = "NameStandard"

  [[config.definitions]]
    name = "NAME_ALIGNMENT"
    value = "NAME_SHIFTED_RIGHT"

  [[config.definitions]]
    name = "NAME_X"
    value = 5

  [[config.definitions]]
    name = "NAME_Y"
    value = 1

A definition has two key/value pairs: a name for the definition and either a value or body. For the definition

  [[config.definitions]]
    name = "NAME_ALIGNMENT"
    value = "NAME_SHIFTED_RIGHT"

the name key tells GORGON-EGG to override the definition for NAME_ALIGNMENT (which is set by the NameStandard module) if it already exists. The definition’s value is then updated to match the value key. Here, the value is NAME_SHIFTED_RIGHT (which is defined by the NameStandard module), telling the module to shift the text over to the right if a specific condition is set.

For the NameStandard module, the default course of action here is to shift the text right by 16 pixels if the selected unit has an affinity. Since this config wants to draw the affinity in that space, we keep the default behavior by simply not overriding these defaults. If we wanted to change the shift distance, we could add the following to our config:

[[config.definitions]]
  name = "NAME_STANDARD_SHIFT"
  value = 16 # Change me!

Some definitions have values that are simple integers, which do not need to be written with quotes around them.


Additionally, you can specify two kinds of requirements when adding a module or definition to your config: a version and/or a list of games.

A version is actually a SemVer version requirement, and looks something like

[[config.definitions]]
  name = "SOME_DEFINITION"
  value = 42
  # This definition will be used if the GORGON-EGG
  # version is exactly 1.0.0.
  version = "=1.0.0"

[[config.definitions]]
  name = "SOME_DEFINITION"
  value = 1337
  # This definition will be used if the GORGON-EGG
  # version is anything past 1.0.0.
  version = ">1.0.0"

This can be used to create configs that can work with older or newer version of GORGON-EGG.


A games list specifies all of the games that a module or definition is valid for. This can be used to ensure that function or graphics addresses are correct across different games, to add fixes that are only needed for specific games, or to support different languages.

For example, GORGON-EGG has a text system for displaying small 8-pixel-tall text, which supports both Latin and Japanese text. Someone working with an English game, however, probably does not want to waste space and time installing the Japanese font, so GORGON-EGG allows for something like

# Install just the Latin system for "U" games.
[[config.modules]]
  name = "NameSmall"
  games = [ "FE7U", "FE8U" ]

# Install the SJIS system for "J" games.
[[config.modules]]
  name = "NameSmallSJIS"
  games = [ "FE6J", "FE7J", "FE8J" ]

For more information, see the config doc.

GORGON-EGG is missing something that I need. Can I add it myself?

Yes! In addition to being easy to configure, GORGON-EGG is designed to be easy to edit.

Extending GORGON-EGG

GORGON-EGG includes a special folder for custom or edited modules. Modules in this folder will override GORGON-EGG’s prepackaged modules with the same name, allowing users to provide changes to GORGON-EGG’s functionality without writing over any existing files.

If you want to edit a prepackaged module, copy it from the source folder into the custom folder before making any changes. If you want to distribute a config that makes use of a custom or edited module, this makes it easier for recipients to use your changes without affecting existing modules.

GORGON-EGG modules are written in C, but GORGON-EGG provides tools for working with THUMB assembly, if users prefer. Modules are (nearly always) independent of one another and the underlying system, which allows users to drop in or remove modules without having to edit non-module files.

See the modules doc for more information about writing modules.

How can I share my GORGON-EGG window?

There are two options for sharing a GORGON-EGG window: sharing the config or sharing the output folder.

Sharing your config (along with any custom folder things used by the config) allows for users to easily make their own changes to your config and modules, making it the preferred way to share a GORGON-EGG window. This forces users to rebuild the GORGON-EGG window themselves, which may be annoying for some users.

Sharing the output folder is fast and convenient. Recipients need only to #include the output/Installer.event file in order to use the window, but are unable to make any further changes to the window. Additionally, this locks the window into being usable only for the game that it was built for.

Why should I use GORGON-EGG over other Unit Window replacements?

GORGON-EGG is an iteration on the Modular Minimug Box. It offers the following benefits:

  • Written in C (with built-in support for THUMB assembly)
  • Clean configuration files that contain only user choices
  • User-friendly shareable outputs
  • Adding/removing modules is drag-and-drop
  • Non-destructive editing and extension of the base system
  • Modules are version- and config-agnostic
48 Likes

Dope stuff as always. Will give this a look :eyes:

petition to rename it Hover Box

2 Likes

counterpoint: “GORGON-EGG” with no further explanation of the title is funnier and scarier

9 Likes

people in febuilder_help gonna be telling people “use gorgon egg patch but don’t edit the gorgon egg class” and it’s going to get old pretty quickly for the regulars

7 Likes

This is a terrible idea on many levels, stop suggesting it.

no‎ ‎ ‎

1 Like

we should have more out of context-titled UI patches

yes you should install the gorgon-egg patch in conjunction with desert-treasure to complement battle windows as well

but make sure to not use it in tandem with 25-speed-myrmidon, it leads the game to crash when the player plays with no animations

2 Likes

Please stop doing this.

“but don’t edit the gorgon egg class”
You think so lowly of your fellow help channel users that you believe they’d make assumptions so insulting?

3 Likes

Have you seen the names people give techs in Pizza Tower speedrunning?

Let this thing be named Gorgon-Egg. It’s a catchy name.

I last suggested this on your old mmb thread in 2020 the one time. It’s not as if I’m bumping your thread every few months suggesting it again, but sorry :man_shrugging:

It’s not that I think lowly of them, it’s that telling people to go install GORGON EGG sounds confusing and people will ask for further explanation most of time. I wish you had chosen a name that isn’t completely arbitrary that at least described what it is a bit, but it sounds like you’re set on it, so whatever.

7 Likes

Couldnt that be solved by literally linking to this thread

I think most people know how to click blue highlighted text

Also, considering other similar patches that grant different unit tooltips, wouldnt it run into an issue of everything loosely being named the same?

I sure do want to choose between Unit Tooltip, Unit Tooltip, Better Tooltips, Tooltip+, and Unit Tooltip

This isn’t Community @Vesly; let it go and move on.

1 Like

I trust that people on the Internet have at least the brains to read, Vesly.
Besides, by having this name, it’s gonna be easier to remember and the joke can also ease the vibe sometimes, no? If you don’t like fun, then I don’t know what to tell you. And please, stop making up reasons when it’s basically a “you” problem.

It is actually catchy. Something something about branding, idk.

Stop pestering people for naming conventions and instead critique the actual contents. You’re diverting the masses away from the actual product by complaining and whining about something unimportant. Be a man and just let the creator do his own thing. I’m sure Zane will take constructive criticisms if GORGON-EGG has any problems to look at.

Exactly this. Like why do you have to fuss over the name, exactly?

Anyways! I’m so looking forward to try this, Zane!

4 Likes

If this gets added to builder it may be good to have a metadata tag for “mmb” or “modular mini mug box” so someone looking for that can be directed to an upgraded version when searching patches.

10 Likes

Apologies to anyone that I upset - this was not my intention.

This was meant to sound comical, as it’s common advice to not edit the gorgon egg classes. Sorry.

6 Likes

Yeah…

5 Likes

A few miscellaneous updates:

  • Added a console message for building successfully
  • Added the ability to prevent the window from retracting automatically during cursor screen quadrant changes

I’ve been working on a new module:

NO$GBA_9FDqccSu2n

GORGON-EGG doesn’t require users to create traditional box-shaped windows. This module draws a ring around the selected unit and displays their HP (as a Diablo-style globe) and inventory on it. There are variant layouts for when units are close to the screen edges, to avoid drawing anything outside of the game window.

It still needs a lot of polish before I can release it. As a note, this module takes up a considerable amount of space for its graphics and data.

17 Likes

Finally, people can just skip the minimug :face_with_hand_over_mouth:

3 Likes

Minor update!

Bugfix:

  • Fixed InvalidPosition tags being overlooked during module reading

I’m calling the Ring module complete, for now. Future plans may include changing the HP globe color based on the unit’s status and displaying more thing on the ring.

3 Likes