mirror of
https://github.com/rh-hideout/pokeemerald-expansion.git
synced 2026-04-28 11:17:13 -05:00
Fix RS Brendan/May trainer sprites not displaying in editor
The getTrainerPicUrl() conversion produced rs_brendan.png and rs_may.png, but the actual files are brendan_rs.png and may_rs.png. Added a name override map for these two special cases. https://claude.ai/code/session_01PnpVQ3UkymCVghfdigCJV9
This commit is contained in:
parent
62e05588e9
commit
4a39d0acd8
|
|
@ -2142,7 +2142,12 @@ function getSpriteHtml(graphicsId, size = 32) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function getTrainerPicUrl(pic) {
|
function getTrainerPicUrl(pic) {
|
||||||
const name = (pic || '').toLowerCase().replace(/\s+/g, '_');
|
const picNameOverrides = {
|
||||||
|
'rs brendan': 'brendan_rs',
|
||||||
|
'rs may': 'may_rs',
|
||||||
|
};
|
||||||
|
const lower = (pic || '').toLowerCase();
|
||||||
|
const name = picNameOverrides[lower] || lower.replace(/\s+/g, '_');
|
||||||
return `../graphics/trainers/front_pics/${name}.png`;
|
return `../graphics/trainers/front_pics/${name}.png`;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user