Code edit (20 edits merged)
Please save this source code
User prompt
add a shadow to the candy canes
User prompt
Fix Bug: 'ReferenceError: filters is not defined' in this line: 'candyCaneGraphics.filters = [new filters.DropShadowFilter({' Line Number: 14
User prompt
Fix Bug: 'ReferenceError: filters is not defined' in this line: 'candyCaneGraphics.filters = [new filters.DropShadowFilter({' Line Number: 14
Code edit (1 edits merged)
Please save this source code
User prompt
Fix Bug: 'ReferenceError: filters is not defined' in this line: 'console.log("filters", filters);' Line Number: 14
User prompt
add a console.log of available filters
Code edit (1 edits merged)
Please save this source code
User prompt
add a drop shadow to candy canes without using filters
Code edit (16 edits merged)
Please save this source code
User prompt
add a border radius to the shadows
Code edit (4 edits merged)
Please save this source code
User prompt
stretch the shadow horizontally
Code edit (1 edits merged)
Please save this source code
User prompt
truncate the shadow horizontally
Code edit (23 edits merged)
Please save this source code
Code edit (25 edits merged)
Please save this source code
Code edit (20 edits merged)
Please save this source code
User prompt
make the player follow the mouse y position
User prompt
clamp player's y move between the first and last candy y
Code edit (3 edits merged)
Please save this source code
Code edit (3 edits merged)
Please save this source code
User prompt
add a computer player
User prompt
handle player's candy selection
User prompt
the player can click anywhere, the selected candy is the closest to the player's y pos
var Board = Container.expand(function () {
var self = Container.call(this);
var boardGraphics = self.createAsset('board', 'Board', 0.5, 0);
self.width = 1024;
self.height = 2680;
boardGraphics.width = self.width;
boardGraphics.height = 190 * 13;
boardGraphics.y = (self.height - boardGraphics.height) / 2;
boardGraphics.visible = false;
});
var CandyCane = Container.expand(function () {
var self = Container.call(this);
var candyCaneGraphics = self.createAsset('candyCane', 'Candy Cane', .5, .5);
self.pick = function () {};
});
var Player = Container.expand(function () {
var self = Container.call(this);
var playerGraphics = self.createAsset('player', 'Player', .5, .5);
self.pickCandyCane = function () {};
});
var Game = Container.expand(function () {
var self = Container.call(this);
var background = self.createAsset('background', 'Game Background', 0.2545, 0.215);
self.addChild(background);
var candyCanes = [];
var players = [];
var currentPlayerIndex = 0;
var board = new Board();
board.x = 2048 / 2;
board.y = 0;
self.addChild(board);
for (var i = 0; i < 13; i++) {
var candyCane = new CandyCane();
candyCane.x = 2048 / 2;
candyCane.y = 250 + i * 190;
candyCanes.push(candyCane);
self.addChild(candyCane);
}
var player = new Player();
player.x = 400;
player.y = 1324;
players.push(player);
self.addChild(player);
LK.on('tick', function () {});
stage.on('down', function (obj) {});
stage.on('up', function (obj) {});
});
a christmas wooden board Background image. High contrast. No shadows.
a vertical christmas wooden board with snow, and decorations on its sides Background image. High contrast. No shadows.
a photo-realistic white and red vertical candy stick slice Single Game Texture. No background. High contrast. No shadows.
a horizontal santa's arm with a white glove and the index pointing to the right Single Game Texture. No background. High contrast. No shadows.
an green hairy grinch's arm, pointing in the horizontal direction, the index finger pointing to the left Single Game Texture. No background. High contrast. No shadows.
a photo-realistic white and red twisted candy stick slice in vertical position and with an extinguished wick. At its center, a simple white rectangular "TNT" sticker in the same direction as the stick Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a top view of a TNT explosion fire Background image. High contrast. No shadows.
A funny Santa Claus disheveled and covered by black soot after an explosion. stary night. High contrast.
a futuristic white robot arm. horizontal direction. the index finger pointing to the left. Single Game Texture. No background. High contrast. No shadows.
A old super hero Santa Claus holding a candy cane in his hand High contrast.
frame of an empty christmas themed popup with a decorated border User interface
a single mat rounded empty button User interface