diff --git a/2.5DHero/2.5DHero/Screens/Inventory/NewInventoryScreen.vb b/2.5DHero/2.5DHero/Screens/Inventory/NewInventoryScreen.vb index cf0fcc15f..8c54a2c9c 100644 --- a/2.5DHero/2.5DHero/Screens/Inventory/NewInventoryScreen.vb +++ b/2.5DHero/2.5DHero/Screens/Inventory/NewInventoryScreen.vb @@ -436,17 +436,22 @@ Public Class NewInventoryScreen 'Bring back when Monogame begins supporting this stuff ' Dim target As New RenderTarget2D(GraphicsDevice, _infoSize, 368, False, GraphicsDevice.PresentationParameters.BackBufferFormat, DepthFormat.Depth24Stencil8, 0, RenderTargetUsage.PreserveContents) GraphicsDevice.SetRenderTarget(target_2) + GraphicsDevice.Clear(Color.Transparent) 'Render background: infoBatch.BeginBatch() + Dim alpha = CInt(CSng(_infoSize) / 500 * 255) + For y = 0 To 368 Step 16 For x = 0 To _infoSize + 16 Step 16 - infoBatch.Draw(_menuTexture, New Rectangle(x, y, 16, 16), New Rectangle(0, 0, 4, 4), New Color(128, 128, 128)) + If x < _infoSize - 16 Then + infoBatch.Draw(_menuTexture, New Rectangle(x, y, 16, 16), New Rectangle(0, 0, 4, 4), New Color(128, 128, 128, alpha)) + End If Next Next - Canvas.DrawGradient(infoBatch, New Rectangle(0, 0, 100, 368), New Color(0, 0, 0, 255), New Color(0, 0, 0, 0), True, -1) - Canvas.DrawGradient(infoBatch, New Rectangle(_infoSize - 100, 0, 100, 368), New Color(0, 0, 0, 0), New Color(0, 0, 0, 255), True, -1) + Canvas.DrawGradient(infoBatch, New Rectangle(0, 0, 100, 368), New Color(0, 0, 0, alpha), New Color(0, 0, 0, 0), True, -1) + Canvas.DrawGradient(infoBatch, New Rectangle(_infoSize - 100, 0, 100, 368), New Color(0, 0, 0, 0), New Color(0, 0, 0, alpha), True, -1) 'Get item and gets its display texts based on the item category: Dim cItem As Item = Item.GetItemByID(_items(ItemIndex + PageIndex * 10).ItemID) @@ -510,7 +515,7 @@ Public Class NewInventoryScreen 'Set the target that was previously active and render the new target on top of that: GraphicsDevice.SetRenderTarget(preTarget) - preBatch.Draw(target_2, New Rectangle(_infoPosition + 80, 0, target_2.Width, target_2.Height), Color.White) + preBatch.Draw(target_2, New Rectangle(_infoPosition + 80, 0, target_2.Width, target_2.Height), New Color(255, 255, 255, alpha)) End Sub '''