Wakeman-ArtifactOfEgo icon

ArtifactOfEgo

Egocentrism converts faster the more you stack it, gives bonus stacks for rarer items and can keep the original item. Adds the Artifact of Ego, a Beads of Fealty blacklist and luck-affected Cleansing Pools.

By Wakeman
Last updated 3 days ago
Total downloads 64
Total rating 0 
Categories Tweaks Items Artifacts AI Generated
Dependency string Wakeman-ArtifactOfEgo-1.0.0
Dependants 0 other packages depend on this package

This mod requires the following mods to function

RiskofThunder-R2API_Language-1.1.0 icon
RiskofThunder-R2API_Language

API for modifying the language localisation of the game

Preferred version: 1.1.0
RiskofThunder-R2API_Core-5.3.0 icon
RiskofThunder-R2API_Core

Core R2API module

Preferred version: 5.3.0
bbepis-BepInExPack-5.4.2122 icon
bbepis-BepInExPack

Unified BepInEx all-in-one modding pack - plugin framework, detour library

Preferred version: 5.4.2122
RiskofThunder-R2API_ContentManagement-1.1.0 icon
RiskofThunder-R2API_ContentManagement

API for adding content to the game

Preferred version: 1.1.0

README

ArtifactOfEgo

A set of changes built around the Lunar item Egocentrism, plus luck for the Cleansing Pool.

  • Faster conversion as you stack it. Vanilla Egocentrism converts one item every 60 seconds no matter how many stacks you hold. Here the speed is multiplied by stacks ^ P: more stacks means faster conversion, with diminishing returns so it takes a very long time to spiral out of control.
  • Bonus stacks for rarer items. Each conversion gives more Egocentrism stacks the rarer the converted item is (see the table below).
  • A chance to keep the item. Each conversion has a 1% chance (configurable, luck-affected) to leave the original item alone and still give the stacks.
  • Used/broken and temporary items. Egocentrism can pick used/broken items (Dio's Best Friend once used, and so on). Temporary items turn into temporary Egocentrisms, and bonus stacks follow the same rule.
  • Artifact of Ego. Selected in the lobby, every player starts with one Egocentrism and cannot drop below one.
  • Beads of Fealty blacklist. While you hold Beads of Fealty, Egocentrism ignores keys, Irradiant Pearls, items that give items, cerebellums, Eulogy Zero, Benthic Bloom, every Hex and every N'tormat page, and more.
  • Luck for Cleansing Pools. Buying from a Cleansing Pool redoes the Pearl / Irradiant Pearl roll using the buyer's luck.

Everything is applied as small patches rather than replacing item code or text, to keep conflicts with other mods to a minimum. Egocentrism gets a short note added to its tooltip for each feature that is switched on. Beads of Fealty only gains the vague line "Tempers the ego.", to keep with its original wording.

Configuration

Run the game once with the mod installed to generate BepInEx/config/com.taran.artifactofego.cfg.

Setting Default What it does
Artifact Of Ego Available true Whether the artifact appears in the lobby. Needs a restart. Everyone in a lobby must use the same value.
Conversion Scaling Exponent (P) 0.3 0 = vanilla. 1 = fully linear. In between: faster with each stack, with diminishing returns. Range 0 to 1.
Stacks Per Conversion section 1 to 50 each One setting per item rarity: how many Egocentrism stacks a conversion gives (vanilla is always 1).
Convert Used And Broken Items true Lets Egocentrism pick used/broken items. Hidden gameplay items stay excluded.
Keep Original Item Chance (%) 1 Chance per conversion that the item is not destroyed and you still gain the stack. 0 turns it off. Luck applies.
Enable Egocentrism Blacklist true While you hold Beads of Fealty, Egocentrism ignores the built-in list.
Extra Blacklisted Items empty Extra internal item names for that list, separated by commas.
Luck Affects Irradiant Pearl true Cleansing Pools redo their Pearl / Irradiant Pearl roll with the buyer's luck. Needs a restart.
Irradiant Pearl Chance (%) 20 Base Irradiant chance for that roll (the game's value is 20%).

Stacks per conversion (defaults)

Converted item Stacks
Common 1
Uncommon 2
Legendary 3
Boss 3
Pearl (normal) 1
Hallowed 3
Void common 2
Void uncommon 3
Void legendary 4
Void boss 3
Hex 2
Lunar 2
Used / broken 1
Anything else 1

What different P values mean

Time for one Egocentrism, with unlimited other items to convert (each conversion adds a stack), to reach one conversion every 3 seconds:

P Stacks needed Time
0.3 (default) ~21,700 ~26 hours (effectively never)
0.35 ~5,200 ~6.6 hours
0.4 ~1,800 ~2.5 hours
0.5 400 ~38 minutes
0.6 ~150 ~16 minutes
0.7 72 ~9 minutes
0.8 42 ~6 minutes
1.0 20 ~3 minutes

In a real run you are limited by how many items you own, so the lower values never actually reach 3 seconds. The bonus stacks above are not counted in this table.

How luck affects the chances

Both rolls use the game's own luck-aware roll: Clover and similar items help, Purity hurts.

Luck Keep original item (base 1%) Irradiant Pearl (base 20%)
0 1.0% 20%
1 2.0% 36%
2 3.0% 48.8%
3 3.9% 59%
5 5.9% 73.8%
10 10.5% 91.4%

The "item transformed" pop-up still appears when an item is kept; that part is cosmetic.

Multiplayer

Everyone needs the mod (it adds an artifact). Conversion speed, keep chance, bonus stacks and the pool roll are decided on the host, so the host's config is the one that counts. Each buyer's own luck is used for the pool roll.

Compatibility

  • Only patches the timer inside Egocentrism's own behaviour, its item-picking filter, and appends sentences to two item descriptions. Other mods that change the same Egocentrism timer will fight over it; use one or the other.
  • The Cleansing Pool change only touches pools that give Pearls. If another mod changes what a pool gives (for example BazaarIsMyHaven with its Lunar Coin option), that reward is left alone.
  • The Artifact of Ego tops players back up to one Egocentrism whenever something removes their last stack.

Troubleshooting

Check BepInEx/LogOutput.log for lines starting with [ArtifactOfEgo]. A healthy start looks like:

  • Artifact of Ego registered.
  • Egocentrism scaling active: patched 1 read(s) of secondsPerTransform.
  • Conversion rules active: ...
  • Cleansing Pool luck active: ...

If a game update changes the code a feature patches, that feature logs an error and switches itself off, and everything else keeps working. Please report it.

The mod also writes BepInEx/ArtifactOfEgo_dump.txt on each launch (a diagnostic list of item tiers and the Beads blacklist). It is safe to delete.

Credits

Made with AI assistance (Claude). Built on BepInEx and R2API.