Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/geode-sdk/geode into main
Browse files Browse the repository at this point in the history
  • Loading branch information
HJfod committed Dec 10, 2024
2 parents 28380f8 + 1f50390 commit e11e789
Showing 1 changed file with 59 additions and 0 deletions.
59 changes: 59 additions & 0 deletions loader/include/Geode/modify/Modify.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -107,29 +107,88 @@
namespace geode {
class Priority {
public:
/// @brief First priority, used for running hooks before all others
/// @note Should be used with caution, consider using VeryEarly instead
static inline constexpr int32_t First = -3000;

/// @brief Very early priority, used for running hooks very early
/// @note Recommended over First
static inline constexpr int32_t VeryEarly = -2000;

/// @brief Early priority, used for running hooks early
static inline constexpr int32_t Early = -1000;

/// @brief Normal priority, used for running hooks at the normal time
static inline constexpr int32_t Normal = 0;

/// @brief Late priority, used for running hooks late
static inline constexpr int32_t Late = 1000;

/// @brief Very late priority, used for running hooks very late
/// @note Recommended over Last
static inline constexpr int32_t VeryLate = 2000;

/// @brief Last priority, used for running hooks after all others
/// @note Should be used with caution, consider using VeryLate instead
static inline constexpr int32_t Last = 3000;

/// @brief First pre priority, used for running hooks before all others
/// @note Should be used with caution, consider using VeryEarlyPre instead
static inline constexpr int32_t FirstPre = First;

/// @brief Very early pre priority, used for running hooks very early
/// @note Recommended over FirstPre
static inline constexpr int32_t VeryEarlyPre = VeryEarly;

/// @brief Early pre priority, used for running hooks early
static inline constexpr int32_t EarlyPre = Early;

/// @brief Normal pre priority, used for running hooks at the normal time
static inline constexpr int32_t NormalPre = Normal;

/// @brief Late pre priority, used for running hooks late
static inline constexpr int32_t LatePre = Late;

/// @brief Very late pre priority, used for running hooks very late
/// @note Recommended over LastPre
static inline constexpr int32_t VeryLatePre = VeryLate;

/// @brief Last pre priority, used for running hooks after all others
/// @note Should be used with caution, consider using VeryLatePre instead
static inline constexpr int32_t LastPre = Last;

/// @brief First post priority, used for running hooks before all others
/// @note Should be used with caution, consider using VeryEarlyPost instead
static inline constexpr int32_t FirstPost = Last;

/// @brief Very early post priority, used for running hooks very early
/// @note Recommended over FirstPost
static inline constexpr int32_t VeryEarlyPost = VeryLate;

/// @brief Early post priority, used for running hooks early
static inline constexpr int32_t EarlyPost = Late;

/// @brief Normal post priority, used for running hooks at the normal time
static inline constexpr int32_t NormalPost = Normal;

/// @brief Late post priority, used for running hooks late
static inline constexpr int32_t LatePost = Early;

/// @brief Very late post priority, used for running hooks very late
/// @note Recommended over LastPost
static inline constexpr int32_t VeryLatePost = VeryEarly;

/// @brief Last post priority, used for running hooks after all others
/// @note Should be used with caution, consider using VeryLatePost instead
static inline constexpr int32_t LastPost = First;

/// @brief Stub priority, used for stubbing out functions & editing parameters
/// @note Should be used with extreme caution, may cause mod incompatibilities
static inline constexpr int32_t Stub = -4000;

/// @brief Replace priority, used for replacing original functions
/// @note Should be used with extreme caution, may cause mod incompatibilities
static inline constexpr int32_t Replace = 4000;
};
}

Expand Down

0 comments on commit e11e789

Please sign in to comment.