2using System.Reflection;
3using System.Runtime.CompilerServices;
4using System.Collections.Generic;
5using System.Collections.Immutable;
10using Microsoft.Xna.Framework;
11using Microsoft.Xna.Framework.Graphics;
17 public partial class RandomTest : FillMethods
23 if (Parent !=
null)
return;
37 public RevolverOverlay()
46 Property =
"BackgroundColor",
47 StartValue =
new Color(255, 0, 0, 0),
48 EndValue =
new Color(255, 0, 0, 64),
57 AddOnSelect = (item, c) => Open(),
58 AddOnDeselect = (item, c) => Remove(),
68 if (Parent !=
null)
return;
77 public PeriscopeOverlay()
80 Text =
"It's not wired you dummy";
90 AddOnSelect = (item, c) => Open(),
91 AddOnDeselect = (item, c) => Remove(),
98 AttachedItems.ConnectPrefabs(
"revolver", typeof(RevolverOverlay));
99 AttachedItems.ConnectPrefabs(
"periscope", typeof(PeriscopeOverlay));
100 CUITest.CloseTestChamber();
Link between Item and CUIComponent.
CUIAnchor is just a Vector2 This is a static class containing some helper methods.
WIP, can animate any property on any object Can run back and forth in [0..1] interval and interpolate...
void SetToStart()
Set Lambda to 0.
void Forward()
Set Direction to Straight and Start.
Base class for all components.
CUINullRect Relative
Relative to parent size and position, [0..1].
virtual CUIComponent Append(CUIComponent child, string name=null, [CallerMemberName] string memberName="")
Adds children to the end of the list.
Color BackgroundColor
Color of BackgroundSprite, default is black If you're using custom sprite and don't see it make sur...
bool IgnoreEvents
Won't react to mouse events.
CUISprite BackgroundSprite
Will be drawn in background with BackgroundColor Default is solid white 1x1 texture.
In fact a static class managing static things.
static CUITextureManager TextureManager
Safe texture manager </summary.
static CUIMainComponent Main
Orchestrates Drawing and updates, there could be only one CUI.Main is located under vanilla GUI.
Vector2 TextAlign
A Vector2 ([0..1],[0..1])
CUISprite GetCUISprite(int x, int y, CUISpriteDrawMode? drawMode=null, SpriteEffects? effects=null)
32x32 square on (x,y) position from CUI.png