* -Added Crayons + CrayonBox
-Can set any crayon state and color
-Added CrayonDecals

* Allows to cycle through decals (not the final thing)

* ItemStatus

* -UI (WIP)
-Selection thing works
-Changed some shitty state names

* -Icons
-Changed decal name

* Pure Texture Grid

* Charges

* -Reach check
-Toggle interface on use

* Can't draw on windows anymore

* UI now shows selected decal and color

* -UseSound
-Nullable

* Remove unused imports

* -Rotation
-Made decal abstract

* Remove some duplicate images

* Space Cleaner cleans

* Loc Title

Co-authored-by: Pieter-Jan Briers <pieterjan.briers@gmail.com>

* Review adressed

Co-authored-by: Pieter-Jan Briers <pieterjan.briers@gmail.com>
This commit is contained in:
Exp
2020-10-13 13:40:05 +02:00
committed by GitHub
parent cb29db60d1
commit 47ba7fc690
187 changed files with 2393 additions and 1 deletions

View File

@@ -0,0 +1,25 @@
using Content.Shared.GameObjects.Components;
using Robust.Client.GameObjects;
using Robust.Client.Interfaces.GameObjects.Components;
using Robust.Shared.Maths;
namespace Content.Client.GameObjects.Components.Crayon
{
public class CrayonDecalVisualizer : AppearanceVisualizer
{
public override void OnChangeData(AppearanceComponent component)
{
base.OnChangeData(component);
var sprite = component.Owner.GetComponent<SpriteComponent>();
var state = component.GetData<string>(CrayonVisuals.State);
var color = component.GetData<Color>(CrayonVisuals.Color);
var rotation = component.GetData<Angle>(CrayonVisuals.Rotation);
sprite.LayerSetState(0, state);
sprite.LayerSetColor(0, color);
sprite.Rotation = rotation;
}
}
}