1
0
Fork 0
mirror of https://github.com/Ellpeck/MLEM.git synced 2024-06-06 14:53:37 +02:00

fixed what I just did

This commit is contained in:
Ellpeck 2019-12-24 17:52:16 +01:00
parent fff25c6c12
commit d70e89aff6

View file

@ -135,9 +135,9 @@ namespace MLEM.Ui.Elements {
if (this.Texture.Value != null)
batch.Draw(this.Texture, this.DisplayArea, Color.White * alpha, this.Scale);
// if we handle overflow, draw using the render target in DrawUnbound
if (!this.scrollOverflow) {
if (!this.scrollOverflow || this.renderTarget == null) {
base.Draw(time, batch, alpha, blendState, samplerState, matrix);
} else if (this.renderTarget != null) {
} else {
// draw the actual render target (don't apply the alpha here because it's already drawn onto with alpha)
batch.Draw(this.renderTarget, this.GetRenderTargetArea(), Color.White);
}