Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
clipSpace : mathDevice.v4BuildZero(),
alphaRef : 0.01,
color : mathDevice.v4BuildOne()
});
draw2D = Draw2D.create({
graphicsDevice : graphicsDevice
});
draw2D.configure({
viewportRectangle : [0, 0, stageWidth, stageHeight],
scaleMode : 'scale'
});
boardSprite = Draw2DSprite.create({
texture : textures['textures/tictactoeboard.png'],
x: boardOffsetX,
y: boardOffsetY,
width : boardSizeX,
height: boardSizeY,
origin: [0, 0]
});
pieceTextures.O = textures['textures/nought.png'];
pieceTextures.X = textures['textures/cross.png'];
var x, y;
var pieceWidth = boardSizeX / 3;
var pieceHeight = boardSizeY / 3;
for (x = 0; x < 3; x += 1)
{
for (y = 0; y < 3; y += 1)
});
this.draw2D.configure({
viewportRectangle : [0, 0, this.stageWidth, this.stageHeight],
scaleMode : 'scale'
});
var textures = this.textures;
var pieceTextures = this.pieceTextures;
var boardOffsetX = this.boardOffsetX;
var boardOffsetY = this.boardOffsetY;
var boardSizeX = this.boardSizeX;
var boardSizeY = this.boardSizeY;
this.boardSprite = Draw2DSprite.create({
texture : textures['textures/tictactoeboard.png'],
x: boardOffsetX,
y: boardOffsetY,
width : boardSizeX,
height: boardSizeY,
origin: [0, 0]
});
pieceTextures.O = textures['textures/nought.png'];
pieceTextures.X = textures['textures/cross.png'];
var pieceWidth = boardSizeX / 3;
var pieceHeight = boardSizeY / 3;
var pieceSprites = this.pieceSprites;
var x, y;
for (x = 0; x < 3; x += 1)
{