Beispiel #1
0
 public DebugDrawItem(Rectangle rectangle, Color color, float duration)
 {
     this.rectangle = rectangle;
     this.color     = color;
     this.duration  = duration;
     _drawType      = DebugDrawType.HollowRectangle;
 }
Beispiel #2
0
 public DebugDrawItem(Rectangle rectangle, Color color, float duration)
 {
     Rectangle = rectangle;
     Color     = color;
     Duration  = duration;
     drawType  = DebugDrawType.HollowRectangle;
 }
Beispiel #3
0
		public DebugDrawItem( Rectangle rectangle, Color color, float duration )
		{
			this.rectangle = rectangle;
			this.color = color;
			this.duration = duration;
			drawType = DebugDrawType.HollowRectangle;
		}
Beispiel #4
0
    ///<summary>
    ///Sets the viewport's debug draw to the type specified by the button press id
    ///passed by the button connection signal.
    ///</summary>
    ///<param name = "id">The DebugDrawEmun value for the debugdraw type associated with the toolbar button</param>
    ///
    private void toolbarChangeRendTypePressed(int id)
    {
        currentDrawType = (DebugDrawType)id;
        switch (currentDrawType)
        {
        case DebugDrawType.Disable:
            GetNode <Viewport>("../Viewport").DebugDraw = Viewport.DebugDrawEnum.Disabled;
            GD.Print(currentDrawType);

            break;

        case DebugDrawType.Overdraw:
            GetNode <Viewport>("../Viewport").DebugDraw = Viewport.DebugDrawEnum.Overdraw;
            GD.Print(currentDrawType);

            break;

        case DebugDrawType.Unshaded:
            GetNode <Viewport>("../Viewport").DebugDraw = Viewport.DebugDrawEnum.Unshaded;
            GD.Print(currentDrawType);

            break;

        case DebugDrawType.Wireframe:
            GetNode <Viewport>("../Viewport").DebugDraw = Viewport.DebugDrawEnum.Wireframe;
            GD.Print(currentDrawType);

            break;

        default:
            GD.Print("Unrecognized Menu Item");
            break;
        }
    }
Beispiel #5
0
 public DebugDrawItem(Vector2 start, Vector2 end, Color color, float duration)
 {
     this.Start    = start;
     this.End      = end;
     this.Color    = color;
     this.Duration = duration;
     drawType      = DebugDrawType.Line;
 }
Beispiel #6
0
 public DebugDrawItem(Vector2 start, Vector2 end, Color color, float duration)
 {
     Start    = start;
     End      = end;
     Color    = color;
     Duration = duration;
     drawType = DebugDrawType.Line;
 }
Beispiel #7
0
		public DebugDrawItem( Vector2 start, Vector2 end, Color color, float duration )
		{
			this.start = start;
			this.end = end;
			this.color = color;
			this.duration = duration;
			drawType = DebugDrawType.Line;
		}
Beispiel #8
0
 public DebugDrawItem(float x, float y, int size, Color color, float duration)
 {
     this.x        = x;
     this.y        = y;
     this.size     = size;
     this.color    = color;
     this.duration = duration;
     drawType      = DebugDrawType.Pixel;
 }
Beispiel #9
0
 public DebugDrawItem(float x, float y, float radius, Color color, float duration)
 {
     X        = x;
     Y        = y;
     Radius   = radius;
     Color    = color;
     Duration = duration;
     drawType = DebugDrawType.Circle;
 }
Beispiel #10
0
		public DebugDrawItem( float x, float y, int size, Color color, float duration )
		{
			this.x = x;
			this.y = y;
			this.size = size;
			this.color = color;
			this.duration = duration;
			drawType = DebugDrawType.Pixel;
		}
Beispiel #11
0
 public DebugDrawItem( string text, Color color, float duration, float scale )
 {
     bitmapFont = Graphics.instance.bitmapFont;
     this.text = text;
     this.color = color;
     this.scale = scale;
     this.duration = duration;
     drawType = DebugDrawType.ConsoleText;
 }
Beispiel #12
0
 public DebugDrawItem(string text, Color color, float duration, float scale)
 {
     bitmapFont    = Graphics.instance.bitmapFont;
     this.text     = text;
     this.color    = color;
     this.scale    = scale;
     this.duration = duration;
     drawType      = DebugDrawType.ConsoleText;
 }
Beispiel #13
0
 public DebugDrawItem(string text, Color color, float duration, float scale)
 {
     BitmapFont = Graphics.Instance.BitmapFont;
     Text       = text;
     Color      = color;
     Scale      = scale;
     Duration   = duration;
     drawType   = DebugDrawType.ConsoleText;
 }
Beispiel #14
0
 public DebugDrawItem(float x, float y, int size, Color color, float duration)
 {
     X        = x;
     Y        = y;
     Size     = size;
     Color    = color;
     Duration = duration;
     drawType = DebugDrawType.Pixel;
 }
Beispiel #15
0
 public DebugDrawItem(float x, float y, int size, Color color, float duration)
 {
     this.X        = x;
     this.Y        = y;
     this.Size     = size;
     this.Color    = color;
     this.Duration = duration;
     drawType      = DebugDrawType.Pixel;
 }
Beispiel #16
0
 public DebugDrawItem( NezSpriteFont spriteFont, String text, Vector2 position, Color color, float duration, float scale )
 {
     this.spriteFont = spriteFont;
     this.text = text;
     this.position = position;
     this.color = color;
     this.scale = scale;
     this.duration = duration;
     drawType = DebugDrawType.SpriteFontText;
 }
Beispiel #17
0
		public DebugDrawItem( BitmapFont bitmapFont, String text, Vector2 position, Color color, float duration, float scale )
		{
			this.bitmapFont = bitmapFont;
			this.text = text;
			this.position = position;
			this.color = color;
			this.scale = scale;
			this.duration = duration;
			drawType = DebugDrawType.BitmapFontText;
		}
Beispiel #18
0
 public DebugDrawItem(SpriteFont spriteFont, String text, Vector2 position, Color color, float duration, float scale)
 {
     this.spriteFont = spriteFont;
     this.text       = text;
     this.position   = position;
     this.color      = color;
     this.scale      = scale;
     this.duration   = duration;
     _drawType       = DebugDrawType.SpriteFontText;
 }
Beispiel #19
0
 public DebugDrawItem(NezSpriteFont spriteFont, String text, Vector2 position, Color color, float duration, float scale)
 {
     this.SpriteFont = spriteFont;
     this.Text       = text;
     this.Position   = position;
     this.Color      = color;
     this.Scale      = scale;
     this.Duration   = duration;
     drawType        = DebugDrawType.SpriteFontText;
 }
Beispiel #20
0
 public DebugDrawItem(BitmapFont bitmapFont, String text, Vector2 position, Color color, float duration, float scale)
 {
     this.BitmapFont = bitmapFont;
     this.Text       = text;
     this.Position   = position;
     this.Color      = color;
     this.Scale      = scale;
     this.Duration   = duration;
     drawType        = DebugDrawType.BitmapFontText;
 }
Beispiel #21
0
 public DebugDrawItem(BitmapFont bitmapFont, String text, Vector2 position, Color color, float duration,
                      float scale)
 {
     BitmapFont = bitmapFont;
     Text       = text;
     Position   = position;
     Color      = color;
     Scale      = scale;
     Duration   = duration;
     drawType   = DebugDrawType.BitmapFontText;
 }
Beispiel #22
0
 public DebugDrawItem(NezSpriteFont spriteFont, String text, System.Numerics.Vector2 position, Color color, float duration,
                      float scale)
 {
     SpriteFont = spriteFont;
     Text       = text;
     Position   = position;
     Color      = color;
     Scale      = scale;
     Duration   = duration;
     drawType   = DebugDrawType.SpriteFontText;
 }
Beispiel #23
0
        public static void DebugDraw(DebugDrawType type, FVec3 v0, FVec3 v1, Fix64 f, Color4 color)
        {
            SyncEvent e = Get();

            e.type          = SyncEventType.DEBUG_DRAW;
            e.debugDrawType = type;
            e.dv1           = v0;
            e.dv2           = v1;
            e.df            = f;
            e.dc            = color;
            e.BeginInvoke();
        }