Esempio n. 1
0
        public ArrayGameObject(int arraySize, string value, Texture2DRectangle valueTexture, SpriteFont font)
        {
            this.arraySize    = arraySize;
            this.valueTexture = valueTexture;
            values            = new Text[arraySize];

            for (int i = 0; i < arraySize; i++)
            {
                values[i] = new Text(value, valueTexture, font)
                {
                    Position = Position + new Vector2((ArrayItemSize + SpaceBetweenItems) * i, 0),
                    Size     = new Vector2(ArrayItemSize, ArrayItemSize)
                };
                AddChild(values[i]);
            }
        }
Esempio n. 2
0
 public Text(string value, Texture2DRectangle texture, SpriteFont font)
 {
     Value        = value;
     this.texture = texture;
     this.font    = font;
 }
Esempio n. 3
0
 public CodeRenderer(Texture2DRectangle texture, SpriteFont font)
 {
     this.texture = texture;
     this.font    = font;
 }