mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-16 05:34:16 +01:00
feat: warn if texture changes size between reloads
This commit is contained in:
parent
1df2ccfb1a
commit
e6ef219b80
1 changed files with 6 additions and 1 deletions
|
|
@ -294,7 +294,12 @@ internal class TextureManager : IDisposable, IServiceType, ITextureSubstitutionP
|
||||||
if (wrap == null)
|
if (wrap == null)
|
||||||
throw new Exception("Could not create texture");
|
throw new Exception("Could not create texture");
|
||||||
|
|
||||||
info.Extents = new Vector2(wrap.Width, wrap.Height);
|
// TODO: We could support this, but I don't think it's worth it at the moment.
|
||||||
|
var extents = new Vector2(wrap.Width, wrap.Height);
|
||||||
|
if (info.Extents != Vector2.Zero && info.Extents != extents)
|
||||||
|
Log.Warning("Texture at {Path} changed size between reloads, this is currently not supported.", path);
|
||||||
|
|
||||||
|
info.Extents = extents;
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue