Temporary spritesheets aren't intercepted by content API
tstaples opened this issue ยท 2 comments
The Characters\Farmer\farmer_base.png
asset isn't being intercepted by the content API. I both logged everything passed to my mod's CanEdit
as well as everything passed to LoadImpl
in SMAPI itself and that asset was never found.
@tstaples That's because the player has a separate content manager constructed via CreateTemporary()
, which SMAPI can't currently intercept:
public Farmer()
{
this.farmerTextureManager = Game1.content.CreateTemporary();
this.farmerRenderer = new FarmerRenderer(this.farmerTextureManager.Load<Texture2D>("Characters\\Farmer\\farmer_" + (this.isMale ? "" : "girl_") + "base"));
// [...]
}
That's something I'm hoping to address with Chucklefish during the SDV 1.3 alpha, so I'll put this ticket in the backlog for now.