Skip to content

EmakiStrengthen ​

EmakiStrengthen (the strengthening module): what it does, which files you will touch, and what each page covers. EmakiStrengthen gives you star-based strengthening, temper state, protection materials, branch trees, attribute output, strengthen layer rebuilding, and a public API for taking equipment from +0 up to +N

NOTE

Some commands still use the historical crack naming (such as clearcrack); gameplay documentation refers to it consistently as "temper"

Module facts ​

ItemValue
Module version4.8.9
Main command/emakistrengthen
Alias/estrengthen
Hard dependencyEmakiCoreLib
Soft dependencyEmakiItem, EmakiAttribute, PlaceholderAPI
Main permissionsemakistrengthen.use, emakistrengthen.reload, emakistrengthen.debug, emakistrengthen.admin

Pages ​

PageContents
CommandsOpening the strengthen GUI, inspecting the held item, refreshing display, setting stars, and giving materials
RecipesSuccess rates, material costs, failure penalties, effects, and actions in recipes/*.yml
ProcessThe full strengthen flow from recipe matching to PDC writes and display refresh
Branch TreesStrengthen routes per star range and the attributes, skills, and display each route grants
BroadcastNotifying nearby or all players the first time a star tier is reached
PlaceholdersPlaceholderAPI output
CoreLib ActionsRebuilding and modifying the main-hand strengthen layer
APIReading state, previewing, and executing strengthening through EmakiStrengthenApi
Event APIBukkit events and interception points across the strengthen flow

Core concepts ​

ConceptDescription
Strengthen starCurrent strengthen tier of the item, such as +1, +2, or +10
Strengthen recipeDefines which items can be strengthened, required materials, success rate, and results
Material planChecks and consumes strengthen materials, protection materials, and temper materials
TemperA level accumulated on failure that raises later success rates by temper_chance_bonus_per_level
Failure downgradeWhen the target star is 6 or higher and no protection material is used, failure drops one star
Protection materialA material with protection: true that prevents a star drop on failure
Branch treeForks into different strengthen routes after a configured star
Strengthen layerWrites to the item's strengthen namespace layer and is rebuilt by CoreLib

Default runtime folder ​

text
plugins/EmakiStrengthen/
├── config.yml
├── recipes/
│   ├── example_recipe.yml
│   └── example_branch_recipe.yml
├── enhancement_recipes/
│   ├── example_enhancement_recipe.yml
│   ├── example_affix_recipe.yml
│   └── example_gem.yml
├── gui/
│   ├── strengthen_gui.yml
│   └── affix_strengthen_gui.yml
└── lang/
    ├── zh_CN.yml
    └── en_US.yml

recipes/*.yml holds the rules for whole-item star strengthening; the generic enhancement framework (equipment / affix / gem) keeps its recipes in enhancement_recipes/*.yml. You configure the interfaces in two files: gui/strengthen_gui.yml for star strengthening and gui/affix_strengthen_gui.yml for affix strengthening

Main config.yml ​

For success_rates, see Process; for local_broadcast_radius and broadcast.*, see Broadcast. The remaining fields are:

FieldTypeRequiredDefaultRangeDescription
versionstringNo4.8.9—Configuration-structure marker; the shipped resource version is maintained by the resource sync flow. Two distinct internal constants exist: a blank key falls back to 4.5.9, and with no config file at all AppConfig.defaults() uses 4.2.9. Neither is a release coordinate
languagestringNozh_CN—Uses lang/<language>.yml
release_default_databooleanNotruetrue / falseReleases the bundled default recipes, GUI, and language resources when missing
affix.max_levelintegerNo10≥ 0 (negatives become 0)Maximum strengthen level per affix; 0 means no cap
affix.capacity_maxintegerNo100≥ 0 (negatives become 0)Total capacity assignable to affixes on one item
affix.capacity_cost_per_levelintegerNo10≥ 0 (negatives become 0)Capacity consumed per affix level; insufficient capacity blocks that attempt
affix.bonus_per_leveldoubleNo1.0finite (non-finite becomes 0)Attribute value added per affix level
enhancement.reject_container_targetbooleanNofalsetrue / falseWhen enabled, rejects targets inside external containers so they cannot be taken between preview and confirm
enhancement.reject_container_materialbooleanNofalsetrue / falseWhen enabled, rejects materials inside external containers so confirm cannot charge an old amount it can no longer take
enhancement.min_success_ratedoubleNo0.00.0~1.0 ratio (≤0/non-finite becomes 0, >1 becomes 1)Lower bound on success rate; only raises a rate that reductions pushed too low, never lowers a higher one, and does not affect pity force-success. 0.0 disables the floor
enhancement.diminishing_returns.per_leveldoubleNo0.00.0~1.0Fraction of the base success rate removed per level above start_level. 0.0 disables it
enhancement.diminishing_returns.start_levelintegerNo1≥ 1First level at which diminishing returns apply; lower levels are unaffected
enhancement.cost_growth.per_leveldoubleNo0.0≥ 0Cost multiplier added per level. 0.0 disables it
enhancement.cost_growth.max_multiplierdoubleNo0.0≥ 0 (0 means no cap)Upper bound on the cost multiplier
enhancement.failure_demotion.levelsintegerNo0≥ 0 (0 means no demotion)Levels lost per failure
enhancement.failure_demotion.floor_levelintegerNo0≥ 0Failure demotion never drops below this level
enhancement.pity_retry.interval_ticksintegerNo0≥ 0 (0 starts no retry task)Retry interval in ticks after a pity-counter persistence failure
enhancement.pity_retry.max_attemptsintegerNo0≥ 0 (0 starts no retry task)Consecutive retries before retrying stops and a warning is logged
enhancement.mastery.exp_per_attemptdoubleNo0.0≥ 0Mastery experience granted per attempt (success or failure); recorded only after cost, materials, and target all commit
enhancement.mastery.exp_per_successdoubleNo0.0≥ 0Additional mastery experience granted per success
enhancement.mastery.soft_capintegerNo0≥ 0 (0 means unlimited)Mastery level soft cap; every 100 accumulated experience is one level. With both experience values at 0, no mastery data is written at all

Below are the shipped defaults (excerpt; success_rates, local_broadcast_radius, and broadcast.* are covered on their own pages):

yaml
version: "4.8.9"
language: "zh_CN"
release_default_data: true
affix:
  max_level: 10
  capacity_max: 100
  capacity_cost_per_level: 10
  bonus_per_level: 1.0
enhancement:
  reject_container_target: false
  reject_container_material: false
  min_success_rate: 0.0
  diminishing_returns:
    per_level: 0.0
    start_level: 1
  cost_growth:
    per_level: 0.0
    max_multiplier: 0.0
  failure_demotion:
    levels: 0
    floor_level: 0
  pity_retry:
    interval_ticks: 0
    max_attempts: 0
  mastery:
    exp_per_attempt: 0.0
    exp_per_success: 0.0
    soft_cap: 0

Example: cut 8% of the base success rate per level from +6 onward, and floor the rate at 5%:

yaml
enhancement:
  min_success_rate: 0.05
  diminishing_returns:
    per_level: 0.08
    start_level: 6

Typical strengthen flow ​

  1. Open the strengthen GUI with /estrengthen open
  2. Insert target equipment, strengthen materials, and optional protection materials
  3. Match an available recipe through the recipe's top-level matcher and slot_groups fields
  4. Check conditions, materials, economy costs, and the current star limit
  5. Calculate the success rate: target-star base rate plus temper bonus, clamped to success_chance_cap
  6. Fire StrengthenPreAttemptEvent, allowing external code to adjust the rate or cancel
  7. Roll the outcome and charge materials and costs
  8. On success, raise the star by one, write the strengthen layer, and run that star's actions.success
  9. On failure, accumulate temper and possibly drop a star, then run actions.failure
  10. CoreLib rebuilds the item presentation; reaching a broadcast star for the first time sends a local or global broadcast

Relation with Attribute ​

Strengthen can also serve as a display-and-progression system only. Install EmakiAttribute and configure ea_attribute effects, and each star contributes real stats: attributes are written through the EmakiAttribute authoritative API into a structured PDC layer and participate in real combat calculation

Without EmakiAttribute the module takes a no-op path: strengthening still completes but no attributes are written

Relation with Item ​

With EmakiItem installed, Strengthen registers an item layer preview provider through EmakiItemApi from its conditionally loaded integration package, so EmakiItem can preview strengthen layer content. When EmakiItem is absent or disabled, that registration is skipped or released automatically without affecting strengthening