Advent of Ascension Wiki

This wiki is maintained for the current latest version of AoA. If you are playing on an older version of the mod, you may find some of the information for your version missing or incorrect. Use the page history feature to view older versions of pages instead.

Other questions may be answered on this page

READ MORE

Advent of Ascension Wiki
Advertisement

NOTE: This is for the 1.12.2 versions of Minecraft. If you are developing for 1.16.5, see Making an Addon/1.16.5

Adding it to your workspace[ | ]

To effectively create an add-on or integrate with AoA, you will need to add it to your development environment. To do this, you will need to edit the repositories section of your build.gradle file to add the CurseMaven repository.

CurseMaven allows you to get the files directly from CurseForge, saving any troublesome configuration. You can read more about it here.

If you do not already have a repositories section of your build.gradle, you'll need to create one.

Gradle1.12

build.gradle layout.

From there, add the below lines into the repositories section:

    maven {
        name = "Curseforge" // Curseforge Maven
        url = "https://www.cursemaven.com/"
    }

Then, in the dependencies section, add in the following line:

    implementation 'curse.maven:advent-of-ascension-nevermine-311054:<file_id>' // Follow the instructions on CurseMaven to see what values to put here

Replacing:

  • <file_id> with the Curseforge file id of the AoA version you're developing for - E.G. 3054253

Once the build.gradle has been edited, re-run the setupDecompWorkspace task in gradle, then refresh your gradle project via the gradle panel.

Key Classes[ | ]

Below are some key classes that developers may be interested in or find useful.

  • PlayerUtil - A utility class that contains various useful methods for interacting with AoA's player data, such as skills and resources.
  • EntityUtil - A utility class that contains various useful methods for interacting with AoA's entities. Contains helper methods for type-immunities, type-damage dealing, and more.
  • PlayerDataManager - The container that holds all the relevant information and methods for AoA's player data. You can get a player's container via PlayerUtil#getAdventPlayer(). Containers only exist on the server, not the client.
  • ConfigurationUtil - Contains all of the configuration options for AoA.
  • AoAMeleeMob, AoARangedMob, AoAFlyingMeleeMob, AoAFlyingRangedMob, AoAAnimal - The base classes for nearly all of AoA's creatures.
  • AoAAmbientNPC, AoATrader - The base classes for AoA's NPC entities.
  • Enums - The holder class for almost all of AoA's enum types. These enums are used in various methods throughout the mod.
  • ArmourRegister - Contains references to all of AoA's armour items after item registration.
  • BlockRegister - Contains references to all of AoA's blocks after block registration.
  • ItemRegister - Contains references to all of AoA's items after item registration.
  • CreativeTabsRegister - Contains references to all of AoA's creative tabs, for placing items in the creative menu.
  • EnchantmentsRegister - Contains references to all of AoA's enchantments.
  • MaterialsRegister - Contains references to all of AoA's tool, sword, and armour materials after item registration.
  • SoundsRegister - Contains references to all of AoA's sounds after sound registration.
  • ToolRegister - Contains references to all of AoA's tools after item registration.
  • WeaponRegister - Contains references to all of AoA's weapons after item registration.
  • SpecialHarvestTool - An interface that passes HarvestDropsEvents to any class that implements it, for custom interactions.
  • BaseArchergun - The base class for all AoA Archerguns. Contains all of the reference methods used for item stats and effects.
  • BaseBlaster - The base class for all AoA Blasters. Contains all of the reference methods used for item stats and effects.
  • BaseBow - The base class for all AoA Bows. Contains all of the reference methods used for item stats and effects.
  • BaseCannon - The base class for all AoA Cannons. Contains all of the reference methods used for item stats and effects.
  • BaseGreatblade - The base class for all AoA Greatblades. Contains all of the reference methods used for item stats and effects.
  • BaseGun - The base class for all AoA Guns. Contains all of the reference methods used for item stats and effects.
  • BaseMaul - The base class for all AoA Mauls. Contains all of the reference methods used for item stats and effects.
  • BaseShotgun - The base class for all AoA Shotguns. Contains all of the reference methods used for item stats and effects.
  • BaseSniper - The base class for all AoA Snipers. Contains all of the reference methods used for item stats and effects.
  • BaseStaff - The base class for all AoA Staves. Contains all of the reference methods used for item stats and effects.
  • BaseSword - The base class for all AoA Swords. Contains all of the reference methods used for item stats and effects.
  • BaseThrownWeapon - The base class for all AoA Thrown Weapons. Contains all of the reference methods used for item stats and effects.
  • BaseVulcane - The base class for all AoA Vulcanes. Contains all of the reference methods used for item stats and effects.

Inter-Mod Comms (IMC)[ | ]

Advent of Ascension offers several IMC functions for quick optional integration. See below for the available functions and their uses.

Adding Custom Guides[ | ]

IMC Key: mod_provides_guides

Message Type: Any

Usage:

Takes the Mod ID of the sending mod and registers it as a guides provider. Guides txt files should be placed in the assets/<modid>/lang/aoa3/guides/ directory of your mod.

Handling Bestiary Entries[ | ]

IMC Key: mod_handles_bestiaries

Message Type: Function

Usage:

Takes a Function<EntityLivingBase, Tuple<List<String>, String>> argument from the message and uses that when opening a bestiary entry for any entity from your Mod ID.

The expected format for the Tuple is that the first is a list of stat lines in String format, and the second is an optional bestiary lore/description entry.

Handling Bestiary Info[ | ]

IMC Key: mod_has_bestiary_entries

Message Type: Any

Usage:

Takes the Mod ID of the sending mod and registers it as a bestiary info provider. Bestiary txt files should be placed in the assets/<modid>/lang/aoa3/bestiary/ directory of your mod.

Adding Custom Advent Gui Themes[ | ]

IMC Key: add_advent_gui_theme

Message Type: Function

Usage:

Takes a Function<String, String> argument from the message and grabs several optional data pieces from it to register a new Advent Gui theme.

Function arguments:

  • "name" - Return the formatted name of your theme, to be displayed on the button selector for themes.
  • "background" - (Optional) The filepath to your theme background texture. E.G. "textures/gui/maingui/themes/default/background.png"
  • "buttons" - (Optional) The filepath to your theme buttons texture. E.G. "textures/gui/maingui/themes/default/buttons.png"
  • "overlay" - (Optional) The filepath to your theme overlay texture. E.G. "textures/gui/maingui/themes/default/overlay.png"

Registering a Hunter Entity[ | ]

IMC Key: register_hunter_entity

Message Type: String

Usage:

Takes a String argument from the message and parses it to register an entity as a hunter entity.

The expected format of the string is: "<EntityID> lvl:<HunterLevel> xp:<XP>" - E.G. "aoa3:cyclops lvl:10 xp:50.5"

Block Heartstone Drops From Entity[ | ]

IMC Key: blacklist_heartstone_entity

Message Type: String

Usage:

Takes a String argument from the message and parses it to blacklist an entity ID from spawning Heartstones.

The expected format of the string is "<EntityID>" - E.G. "aoa3:cyclops"

Block Bloodlust Spawns From Entity[ | ]

IMC Key: blacklist_bloodlust_entity

Message Type: String

Usage:

Takes a String argument from the message and parses it to blacklist an entity ID from spawning Bloodlusts.

The expected format of the string is "<EntityID>" - E.G. "aoa3:cyclops"

Advertisement