Add new "OptionsVisualizer" (#25128)

This is a visualizer somewhat similar to the Generic. It allows configuring appearance info based on specific CVars the user has set. This allows YAML to easily configure alternatives for accessibility CVars like reduced motion.
This commit is contained in:
Pieter-Jan Briers
2024-02-17 21:52:11 +01:00
committed by GitHub
parent cb32a8470f
commit 1ce2155315
10 changed files with 217 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
- type: entity
id: OptionsVisualizerTest
suffix: DEBUG
components:
- type: Tag
tags:
- Debug
- type: Sprite
sprite: Effects/optionsvisualizertest.rsi
layers:
- state: none
map: [ "layer" ]
- type: OptionsVisualizer
visuals:
layer:
- options: Default
data: { state: none }
- options: Test
data: { state: test }
- options: ReducedMotion
data: { state: motion }
- options: [Test, ReducedMotion]
data: { state: both }

Binary file not shown.

After

Width:  |  Height:  |  Size: 316 B

View File

@@ -0,0 +1 @@
{"version":1,"size":{"x":32,"y":32},"license":"CC-BY-SA-4.0","copyright":"Discord pjb","states":[{"name":"none"},{"name":"both"},{"name":"motion"},{"name":"test"}]}

Binary file not shown.

After

Width:  |  Height:  |  Size: 336 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 251 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 317 B