Spielerando

Keep a saved character's look when the art files get renamed

After an update, old saves show an empty frame where a hero's face used to be, because the picture was renamed, merged or removed. Here is how to follow the renames, spot loops, and pick a sensible substitute when the old look is gone.

Why this works

A save is a promise that must outlive today's file names. Storing what a thing is rather than where it lives, and keeping a trail from old names to new ones, lets art change freely without breaking anyone's hero.

When not to use it

Skip it in a game that will never be updated, or when old saves are deliberately dropped at each release, as in a seasonal game. Then a clean start is simpler than keeping a long trail of renames.

In the full entry

  • What to build, step by step
  • Starting values and the reason for each
  • 3 common mistakes and the fix
  • A diagram of every state
  • 39 lines of example code with 6 checks that pass
  • How your AI shows you that it works

Say this to your AI

Use the Spielerando entry "Keep a saved character's look when the art files get renamed" (read_entry portrait-id-survives-asset-rename) in my game. Build it step by step, and show me how you checked that it works.

Or skip this and connect the MCP: your AI then finds all of this by itself.Connect the MCP