From 4221fecff6c2d979743b8d6787c970bc34b4639d Mon Sep 17 00:00:00 2001 From: Pieter-Jan Briers Date: Sat, 6 Jul 2019 19:20:20 +0200 Subject: [PATCH] Update content repo for CLYDE 2.0. --- .../Graphics/Overlays/CircleMaskOverlay.cs | 2 +- .../Graphics/Overlays/GradientCircleMask.cs | 2 +- Content.Client/Parallax/ParallaxOverlay.cs | 12 +++++++----- Content.Client/UserInterface/HandsGui.cs | 4 ++-- Resources/Prototypes/Entities/Construction.yml | 2 -- RobustToolbox | 2 +- 6 files changed, 12 insertions(+), 12 deletions(-) diff --git a/Content.Client/Graphics/Overlays/CircleMaskOverlay.cs b/Content.Client/Graphics/Overlays/CircleMaskOverlay.cs index 81dfff8b5d..1f9afb34ea 100644 --- a/Content.Client/Graphics/Overlays/CircleMaskOverlay.cs +++ b/Content.Client/Graphics/Overlays/CircleMaskOverlay.cs @@ -24,7 +24,7 @@ namespace Content.Client.Graphics.Overlays Shader = _prototypeManager.Index("circlemask").Instance(); } - protected override void Draw(DrawingHandle handle) + protected override void Draw(DrawingHandleBase handle) { var worldHandle = (DrawingHandleWorld)handle; var viewport = _eyeManager.GetWorldViewport(); diff --git a/Content.Client/Graphics/Overlays/GradientCircleMask.cs b/Content.Client/Graphics/Overlays/GradientCircleMask.cs index 8637878cf9..ffb4ce8695 100644 --- a/Content.Client/Graphics/Overlays/GradientCircleMask.cs +++ b/Content.Client/Graphics/Overlays/GradientCircleMask.cs @@ -23,7 +23,7 @@ namespace Content.Client.Graphics.Overlays Shader = _prototypeManager.Index("gradientcirclemask").Instance(); } - protected override void Draw(DrawingHandle handle) + protected override void Draw(DrawingHandleBase handle) { var worldHandle = (DrawingHandleWorld)handle; var viewport = _eyeManager.GetWorldViewport(); diff --git a/Content.Client/Parallax/ParallaxOverlay.cs b/Content.Client/Parallax/ParallaxOverlay.cs index 4e961b1151..11fd6c419b 100644 --- a/Content.Client/Parallax/ParallaxOverlay.cs +++ b/Content.Client/Parallax/ParallaxOverlay.cs @@ -43,23 +43,25 @@ namespace Content.Client.Parallax } } - protected override void Draw(DrawingHandle handle) + protected override void Draw(DrawingHandleBase handle) { if (_parallaxTexture == null) { return; } + var screenHandle = (DrawingHandleScreen) handle; + var (sizeX, sizeY) = _parallaxTexture.Size; var (posX, posY) = _eyeManager.ScreenToWorld(Vector2.Zero).ToWorld(_mapManager).Position; var (ox, oy) = (Vector2i) new Vector2(-posX / Slowness, posY / Slowness); ox = MathHelper.Mod(ox, sizeX); oy = MathHelper.Mod(oy, sizeY); - handle.DrawTexture(_parallaxTexture, new Vector2(ox, oy)); - handle.DrawTexture(_parallaxTexture, new Vector2(ox - sizeX, oy)); - handle.DrawTexture(_parallaxTexture, new Vector2(ox, oy - sizeY)); - handle.DrawTexture(_parallaxTexture, new Vector2(ox - sizeX, oy - sizeY)); + screenHandle.DrawTexture(_parallaxTexture, new Vector2(ox, oy)); + screenHandle.DrawTexture(_parallaxTexture, new Vector2(ox - sizeX, oy)); + screenHandle.DrawTexture(_parallaxTexture, new Vector2(ox, oy - sizeY)); + screenHandle.DrawTexture(_parallaxTexture, new Vector2(ox - sizeX, oy - sizeY)); } } } diff --git a/Content.Client/UserInterface/HandsGui.cs b/Content.Client/UserInterface/HandsGui.cs index be4f8678bb..366f04eedc 100644 --- a/Content.Client/UserInterface/HandsGui.cs +++ b/Content.Client/UserInterface/HandsGui.cs @@ -90,8 +90,8 @@ namespace Content.Client.UserInterface var handL = new UIBox2(_handL.TopLeft * UIScale, _handL.BottomRight * UIScale); var handR = new UIBox2(_handR.TopLeft * UIScale, _handR.BottomRight * UIScale); - handle.DrawStyleBox(handBox, leftActive ? handL : handR); - handle.DrawStyleBox(inactiveHandBox, leftActive ? handR : handL); + handBox.Draw(handle, leftActive ? handL : handR); + inactiveHandBox.Draw(handle, leftActive ? handR : handL); } /// diff --git a/Resources/Prototypes/Entities/Construction.yml b/Resources/Prototypes/Entities/Construction.yml index 568dbe84ea..e6748c67a5 100644 --- a/Resources/Prototypes/Entities/Construction.yml +++ b/Resources/Prototypes/Entities/Construction.yml @@ -9,8 +9,6 @@ - type: ConstructionGhost - type: BoundingBox - type: Clickable - baseshader: unshaded - selectionshader: selection_outline_unshaded - type: entity name: somebody-messed-up frame diff --git a/RobustToolbox b/RobustToolbox index 4ae2f6b667..78c393aac5 160000 --- a/RobustToolbox +++ b/RobustToolbox @@ -1 +1 @@ -Subproject commit 4ae2f6b667e21ca35bf667869c70b50e7e66ba9e +Subproject commit 78c393aac54b30b2da34821a4da41487ea5ecc91