Code edit (4 edits merged)
Please save this source code
Code edit (10 edits merged)
Please save this source code
User prompt
else if (self.tickCount > 15) { self.moveSpeed *= 0.95; self.y += Math.cos(self.angle) * self.moveSpeed + (self.tickCount - 30) * 0.5; } else { self.y += Math.cos(self.angle) * self.moveSpeed + self.tickCount * 0.1; } make sure, this naughty snowball fall after 15 ticks
Code edit (1 edits merged)
Please save this source code
var CollectableBell = Container.expand(function () { var self = Container.call(this); var bellGraphics = self.createAsset('collectableBell', 'Collectable Bell Graphics', 0.5, 0.5); self.speed = -3 - Math.random() * 2; self.move = function () { self.x += self.speed; }; }); var TimerBar = Container.expand(function () { var self = Container.call(this); self.width = 2048; self.height = 20; self.x = 1024; self.y = 2732 - self.height; self.timerGraphics = self.createAsset('timerBar', 'Timer Bar Graphics', 0.5, 0.5); self.timerGraphics.width = 0; self.timerGraphics.height = self.height; self.updateWidth = function (percentage) { self.timerGraphics.width = 2048 * percentage; }; }); var TornUpgrade = Container.expand(function (upgradeType, x, y) { var self = Container.call(this); var leftPart = self.createAsset(upgradeType + 'Left', 'Left part of ' + upgradeType, 1, 0); var rightPart = self.createAsset(upgradeType + 'Right', 'Right part of ' + upgradeType, 0, 0); self.x = x; self.y = y - 300; self.addChild(leftPart); self.addChild(rightPart); var fadeAndFall = function () { leftPart.x -= 1; rightPart.x += 1; self.y += 3; self.alpha -= 0.01; if (self.alpha <= 0) { LK.off('tick', self.tickReference); self.destroy(); } }; self.tickReference = fadeAndFall.bind(self); LK.on('tick', self.tickReference); }); var DestroyedBrat = Container.expand(function (bratType, startX, startY, moveSpeed, angle) { var self = Container.call(this); var bratGraphics = self.createAsset(bratType, 'Brat Graphics', .5, .5); self.x = startX; self.y = startY; self.speedX = moveSpeed * Math.cos(angle); self.speedY = moveSpeed * Math.sin(angle); self.alpha = 1; self.fadeOut = function () { self.x += self.speedX; self.y += self.speedY; self.alpha -= 0.02; if (self.alpha < 0) { LK.off('tick', self.fadeOutReference); self.destroy(); } }; self.fadeOutReference = self.fadeOut.bind(self); LK.on('tick', self.fadeOutReference); }); var DestroyedPresentByStorm = Container.expand(function (startX, startY, moveSpeed) { var self = Container.call(this); var destroyedPresentGraphics = self.createAsset('presentDestroyedByStorm', 'Present destroyed by Storm Graphics', .5, .5); self.x = startX; self.y = startY; self.speed = moveSpeed; self.alpha = 1; self.moveAndFade = function () { self.x += self.speed; self.y += 10; self.rotation += 0.1; self.alpha -= 0.005; if (self.alpha <= 0) { LK.off('tick', self.fadeOutReference); self.destroy(); } }; self.fadeOutReference = self.moveAndFade.bind(self); LK.on('tick', self.moveAndFade); }); var DestroyedRaven = Container.expand(function (startX, startY, moveSpeed, angle) { var self = Container.call(this); var ravenGraphics = self.createAsset('ravenDestroyedBySnowball', 'Raven destroyed by Snowball', .5, .5); self.x = startX; self.y = startY; self.speedX = moveSpeed * Math.cos(angle); self.speedY = moveSpeed * Math.sin(angle); self.alpha = 1; self.fadeOut = function () { self.x += self.speedX; self.y += self.speedY; self.alpha -= 0.02; if (self.alpha < 0) { LK.off('tick', self.fadeOutReference); self.destroy(); } }; self.fadeOutReference = self.fadeOut.bind(self); LK.on('tick', self.fadeOutReference); }); var MagicTrail = Container.expand(function (x, y) { var self = Container.call(this); var trailGraphics = self.createAsset('magicTrail', 'Magic Trail Graphics', 0.5, 0.5); self.x = x; self.y = y; self.fadeOut = function () { self.alpha -= 0.01; if (self.alpha <= 0) { LK.off('tick', self.fadeOutReference); self.destroy(); } }; self.fadeOutReference = self.fadeOut.bind(self); LK.on('tick', self.fadeOutReference); }); var FloatingText = Container.expand(function (text, x, y, color) { var self = Container.call(this); LK.on('tick', function () { self.moveUp(); }); var textGraphics = new Text2(text, { size: 100, fill: color, align: 'center' }); textGraphics.anchor.set(0.5, 0.5); self.addChild(textGraphics); self.x = x; self.y = y; self.moveUp = function () { self.y -= 3; }; self.fadeOut = function () { self.alpha -= 0.01; if (self.alpha <= 0) { self.destroy(); } }; self.fadeOutReference = self.fadeOut.bind(self); LK.on('tick', self.fadeOutReference); }); var Santa = Container.expand(function () { var self = Container.call(this); Santa.prototype.customIntersects = function (other) { var hitboxOffset = this.width * 0.1; var hitboxWidth = this.width - 2 * hitboxOffset - 275; var hitboxHeight = this.height - 2 * hitboxOffset - 215; var hitboxX = this.x + hitboxOffset - 175; var hitboxY = this.y + hitboxOffset - 145; var otherX = other.x - other.width / 2; var otherY = other.y - other.height / 2; var otherWidth = other.width; var otherHeight = other.height; return hitboxX < otherX + otherWidth && hitboxX + hitboxWidth > otherX && hitboxY < otherY + otherHeight && hitboxY + hitboxHeight > otherY; }; Santa.prototype.sledgeIntersects = function (other) { var hitboxOffset = this.width * 0.1; var hitboxWidth = this.width - 2 * hitboxOffset - 120; var hitboxHeight = this.height - 2 * hitboxOffset - 140; var hitboxX = this.x + hitboxOffset - 150; var hitboxY = this.y + hitboxOffset - 50; var otherX = other.x - other.width / 2; var otherY = other.y - other.height / 2; var otherWidth = other.width; var otherHeight = other.height; return hitboxX < otherX + otherWidth && hitboxX + hitboxWidth > otherX && hitboxY < otherY + otherHeight && hitboxY + hitboxHeight > otherY; }; Santa.prototype.keeperModeIntersects = function (other) { var hitboxOffset = this.width * 0.1; var hitboxWidth = this.width - 2 * hitboxOffset - 80; var hitboxHeight = this.height - 2 * hitboxOffset - 160; var hitboxX = this.x + hitboxOffset - 150; var hitboxY = this.y + hitboxOffset - 50; var otherX = other.x - other.width / 2; var otherY = other.y - other.height / 2; var otherWidth = other.width; var otherHeight = other.height; return hitboxX < otherX + otherWidth && hitboxX + hitboxWidth > otherX && hitboxY < otherY + otherHeight && hitboxY + hitboxHeight > otherY; }; var santaGraphics = self.createAsset('santa', 'Santa Graphics', 0.5, .5); self.bellLives = 2; self.bells = []; for (var i = 0; i < self.bellLives; i++) { var bell = self.createAsset('bell', 'Bell Graphics', 0.5, 0.5); bell.x = self.x - 200 - i * bell.width / 3; bell.y = self.y - 50 + i * bell.height; bell.rotation = 30 * (Math.PI / 180); bell.pendulumAngle = 30; bell.pendulumDirection = 1; bell.pendulumSpeed = 0.5; bell.updatePendulum = function () { this.rotation = this.pendulumAngle * (Math.PI / 180); if (this.pendulumAngle > 30 || this.pendulumAngle < -30) { this.pendulumDirection *= -1; } this.pendulumAngle += this.pendulumSpeed * this.pendulumDirection; }; self.addChild(bell); LK.on('tick', function () { bell.updatePendulum(); }); self.bells.push(bell); self.addChild(bell); } self.isStationary = false; self.baseSpeed = 8.75; self.currentSpeed = self.baseSpeed; self.slowDownTimer = 0; self.goldenBeard = false; self.move = function (touchPosition) { if (!self.isStationary) { if (self.slowDownTimer > 0) { self.currentSpeed = self.goldenBeard ? self.baseSpeed * 2 : self.baseSpeed * (kindUpgrades.coldResistance ? 0.75 : 0.5); self.slowDownTimer--; } else { self.currentSpeed = self.baseSpeed; if (self.frozenBeard) { self.removeChild(self.frozenBeard); self.frozenBeard = null; self.goldenBeard = false; } if (self.parent.frozenEffect) { self.parent.removeChild(self.parent.frozenEffect); self.parent.frozenEffect = null; } } var newX = self.x + (touchPosition.x - self.x) * (self.currentSpeed / self.baseSpeed) * 0.02; var newY = self.y + (touchPosition.y - self.y) * (self.currentSpeed / self.baseSpeed) * 0.02; if (!self.isStationary) { var magicTrail = new MagicTrail(Math.max(0, self.x - 150), Math.max(0, self.y + 100)); self.parent.addChild(magicTrail, 0); var magicTrail2 = new MagicTrail(Math.max(0, self.x - 150), Math.max(0, self.y)); self.parent.addChild(magicTrail2, 0); } self.x = Math.max(0, Math.min(2048, newX)); self.y = Math.max(0, Math.min(2732, newY)); } }; self.throwPresent = function () { if (this.canThrowPresent) { this.canThrowPresent = false; LK.setTimeout(function () { self.canThrowPresent = true; }, kindUpgrades.premiumDelivery ? 250 : 500); } }; self.throwSnowball = function () { if (this.canThrowSnowball) { this.canThrowSnowball = false; LK.setTimeout(function () { self.canThrowSnowball = true; }, 250); } }; self.toggleMovement = function () { self.isStationary = !self.isStationary; if (self.isStationary) { self.stationarySantaGraphics = self.createAsset('stationarySanta', 'Stationary Santa Graphics', 0.5, 0.5); self.addChild(self.stationarySantaGraphics); if (kindUpgrades["transcendence"]) { self.alpha = 0.8; } } else if (self.stationarySantaGraphics) { self.removeChild(self.stationarySantaGraphics); self.stationarySantaGraphics = null; self.alpha = 1; } }; self.canThrowPresent = true; self.canThrowSnowball = true; }); var Present = Container.expand(function () { var self = Container.call(this); var presentType = Math.random() < 0.5 ? 'present1' : 'present2'; var presentGraphics = self.createAsset(presentType, 'Present Graphics', .5, .5); self.scoreValue = 1; self.tickCount = 0; self.moveSpeed = 20; self.fall = function () { if (!self.frontThrow) { var gravity = 14; self.y += gravity; } else { if (self.tickCount < 30) { self.moveSpeed *= 0.98; self.x += Math.cos(self.angle) * self.moveSpeed; self.y += Math.sin(self.angle) * self.moveSpeed - (30 - self.tickCount) * 0.5; } else { self.x += Math.cos(self.angle) * self.moveSpeed; self.y += Math.sin(self.angle) * self.moveSpeed + self.tickCount * 0.1; } self.rotation += 0.02; self.tickCount++; } }; }); var CurvedSnowball = Container.expand(function () { var self = Container.call(this); var snowballGraphics; snowballGraphics = self.createAsset('snowball', 'Snowball Graphics', 0.5, 0.5); self.moveSpeed = 20; self.tickCount = 0; self.move = function () { if (self.tickCount > 30) { self.moveSpeed *= 0.98; self.x += Math.cos(self.angle) * self.moveSpeed; self.y += Math.sin(self.angle) * self.moveSpeed + (self.tickCount - 30) * 0.5; } else { self.x += Math.cos(self.angle) * self.moveSpeed; self.y += Math.sin(self.angle) * self.moveSpeed + self.tickCount * 0.1; } self.rotation += 0.1; self.tickCount++; }; }); var Chimney = Container.expand(function () { var self = Container.call(this); self.satisfied = false; var chimneyGraphics = self.createAsset('chimney', 'Chimney Graphics', .5, .5); var randomScaleFactor = 1 + Math.random() * 3; chimneyGraphics.scale.y *= randomScaleFactor; chimneyGraphics.scale.x = randomScaleFactor * 0.5; self.speed = -5; self.moveAndCheckBounds = function () { if (!self.satisfied) { self.x += self.speed; } else { self.y += 15; } }; }); var KindPresent = Container.expand(function () { var self = Container.call(this); var presentGraphics = self.createAsset('kindPresent', 'Kind Present Graphics', .5, .5); self.fall = function () { var gravity = 7; self.y += gravity; if (self.y > 2732) { self.destroy(); } }; }); var SuperPresent = Container.expand(function () { var self = Container.call(this); var presentGraphics = self.createAsset('superPresent', 'Super Present Graphics', .5, .5); self.fall = function () { var gravity = 7; self.y += gravity; if (self.y > 2732) { self.destroy(); } }; }); var NaughtyPresent = Container.expand(function () { var self = Container.call(this); var presentGraphics = self.createAsset('naughtyPresent', 'Naughty Present Graphics', .5, .5); self.fall = function () { var gravity = 7; self.y += gravity; if (self.y > 2732) { self.destroy(); } }; }); var UpgradeIcon = Container.expand(function (upgradeType, x, y) { var self = Container.call(this); var iconGraphics = self.createAsset(upgradeType, 'Upgrade Icon', 0, 0); self.x = x; self.y = y; LK.setTimeout(function () { self.destroy(); }, 5000); }); var Cloud = Container.expand(function () { var self = Container.call(this); var cloudGraphics = self.createAsset('cloud', 'Cloud Graphics', 0.5, 0.5); if (enemyGoodUpgrades['biggerClouds']) { cloudGraphics.scale.x *= 1.25; cloudGraphics.scale.y *= 1.25; } cloudGraphics.alpha = 1; var stormGraphics = null; self.speed = -3 - Math.random() * 2; self.revealed = false; self.revealing = function () { if (!self.revealed) { self.revealed = true; cloudGraphics.alpha = 0.55; } }; self.move = function () { self.x += self.speed; self.y += Math.sin(LK.ticks / 60) * 2; if (self.blinkTimer > 0) { if (!self.stormCreated) { self.stormCreated = true; stormGraphics = self.createAsset('storm', 'Storm Graphics', 0.5, 0.5); if (enemyGoodUpgrades['biggerClouds']) { stormGraphics.scale.x *= 1.5; stormGraphics.scale.y *= 1.5; stormGraphics.y += 35; } self.addChildAt(stormGraphics, 0); } self.blinkTimer--; if (self.blinkTimer <= 0) { self.storm = true; stormGraphics.scale.y = 1.50; stormGraphics.scale.x = 1.50; stormGraphics.y += 60; } } if (self.storm && !self.blinkInterval) { var blinkCount = 0; self.blinkInterval = LK.setInterval(function () { cloudGraphics.alpha = cloudGraphics.alpha === 0.25 ? 0.55 : 0.25; if (stormGraphics) { stormGraphics.alpha = stormGraphics.alpha === 1 ? 0.75 : 1; } if (++blinkCount >= 6) { LK.clearInterval(self.blinkInterval); self.blinkInterval = null; self.storm = false; stormGraphics.alpha = 1; stormGraphics.scale.y = 1; stormGraphics.y -= 60; stormGraphics.scale.x = 1; self.revealing(); self.blinkTimer = 120; } }, 250); } if (self.x < -self.width) { self.destroy(); } }; }); var FlyingEnvelope = Container.expand(function (santa) { var self = Container.call(this); var windGraphics = self.createAsset('flyingEnvelope', 'Flying Envelope Graphics', 0.5, 0.5); self.speed = 4; self.rotationRight = true; self.move = function () { self.x -= self.speed; self.rotation += self.rotationRight ? 0.01 : -0.01; if (self.rotation > 0.5 && self.rotationRight) { self.rotationRight = false; } else if (self.rotation < -0.5) { self.rotationRight = true; } }; }); var Snowflake = Container.expand(function () { var self = Container.call(this); var snowflakeType = Math.random() < 0.1 && enemyBadUpgrades["deadlySnowfall"] ? 'deadlySnowflake' : kindUpgrades["goldenSnowflakes"] && Math.random() < 0.01 ? 'goldenSnowflake' : 'snowflake'; var snowflakeGraphics = self.createAsset(snowflakeType, snowflakeType + ' Graphics', 0.5, 0.5); self.deadlySnowflake = snowflakeType === 'deadlySnowflake'; self.goldenSnowflake = snowflakeType === 'goldenSnowflake'; var randomScale = 0.5 + Math.random() * 0.5; snowflakeGraphics.scale.set(randomScale); self.rotationDirection = (Math.random() < 0.5 ? -1 : 1) * 0.05; self.speed = (Math.random() - 0.5) * 5; self.fallSpeed = 2 + Math.random() * 3; self.move = function () { self.y += self.fallSpeed; if (self.x <= 0 || self.x >= 2048) { self.speed *= -1; } self.x += self.speed; self.rotation += self.rotationDirection * 0.25; if (self.y > 2732) { self.destroy(); } }; }); var DeadlyPresent = Container.expand(function () { var self = Container.call(this); var presentGraphics = self.createAsset('deadlyPresent', 'Deadly Present Graphics', .5, .5); self.fall = function () { var gravity = 14; self.y += gravity; }; }); var Raven = Container.expand(function (santa, ravenAnger) { var self = Container.call(this); var ravenGraphics = self.createAsset('raven', 'Raven Graphics', 0.5, 0.5); self.flySpeed = -8 - Math.random() * 4; self.hitByPresent = false; self.carryingPresent = null; self.move = function () { if (!self.hitByPresent || self.carryingPresent) { self.x += self.flySpeed * (self.carryingPresent ? 0.75 : 1); if (ravenAnger > 0 && !santa.hidden) { var verticalMovement = santa.y > self.y ? -1 : santa.y < self.y ? 1 : 0; self.y += verticalMovement * (self.flySpeed / 100) * ravenAnger; } } if (self.carryingPresent) { self.carryingPresent.x = self.x; self.carryingPresent.y = self.y + 100; self.carryingPresent.abducted = true; } }; }); var Brat = Container.expand(function (santa, naughtySnowballs) { var self = Container.call(this); self.bratType = Math.random() < 0.5 && enemyBadUpgrades["badGirls"] ? 'badGirl' : 'brat'; var bratGraphics = self.createAsset(self.bratType, 'Brat Graphics', 0.5, 0.5); var highPosition = false; var movementSpeed = 8 + Math.random() * 4; var movementSpeedVertical = self.bratType === 'badGirl' ? 4 : 0; var ballType = self.bratType === 'badGirl' ? 'badNut' : 'random'; highPosition = self.y < 1366 ? true : false; self.throwTimer = 120; self.throwNaughtySnowball = function () { if (!santa.hidden) { var naughtySnowball = new NaughtySnowball(naughtySnowballs, ballType); naughtySnowball.x = self.x; naughtySnowball.y = self.y; var dx = santa.x - self.x; var dy = santa.y - self.y; naughtySnowball.angle = Math.atan2(dy, dx); if (self.parent) { self.parent.addChild(naughtySnowball); naughtySnowballs.push(naughtySnowball); } } }; LK.on('tick', function () { if (self.throwTimer === 120) { highPosition = self.y < 1366 ? true : false; if (!highPosition && self.bratType === 'badGirl') { bratGraphics.rotation = 330 * (Math.PI / 180); } } if (self.throwTimer <= 0) { self.throwNaughtySnowball(santa); self.throwTimer = 200; } else { self.throwTimer--; } }); self.move = function () { self.x += movementSpeed; if (highPosition) { self.y += movementSpeedVertical; } else { self.y -= movementSpeedVertical; } }; }); var NaughtySnowball = Container.expand(function (naughtySnowballs, ballType) { var self = Container.call(this); var snowballType = ''; if (ballType === 'random') { snowballType = Math.random() < 0.5 ? 'naughtySnowball' : 'glueSnowball'; } else { snowballType = ballType; } var snowballGraphics = self.createAsset(snowballType, snowballType + ' Graphics', 0.5, 0.5); self.glueSnowball = snowballType === 'glueSnowball' ? true : false; self.badNut = snowballType === 'badNut' ? true : false; self.moveSpeed = snowballType === 'glueSnowball' || snowballType === 'badNut' ? 20 : 10; self.tickCount = 0; self.angle = 0; self.move = function () { if (!self.glueSnowball && !self.badNut) { self.y += Math.sin(self.angle) * self.moveSpeed; } else if (self.tickCount > 30) { self.moveSpeed *= 0.98; self.y += Math.sin(self.angle) * self.moveSpeed + (self.tickCount - 30) * 0.5; } else { self.y += Math.sin(self.angle) * self.moveSpeed + self.tickCount * 0.1; } self.x += Math.cos(self.angle) * self.moveSpeed; self.rotation += 0.1; self.tickCount++; }; }); var Title = Container.expand(function () { var self = Container.call(this); var titleGraphics = self.createAsset('title', 'Title Graphics', 0.5, 0.5); self.x = 1024; self.y = 2732 / 2; }); var PC = Container.expand(function () { var self = Container.call(this); var pcGraphics = self.createAsset('pc', 'PC Graphics', 0.5, 0.5); self.x = 1024; self.y = 2732 / 3; }); var SmartPhone = Container.expand(function () { var self = Container.call(this); var smartphoneGraphics = self.createAsset('smartphone', 'SmartPhone Graphics', 0.5, 0.5); self.x = 1024; self.y = 2732 / 3 * 2; }); var zuErledigen = "-stats hinzufügen-Glocken sammelbar machen-Sturmspielrahmeneffekt hinzufügen-bad girls Nüsse als wurfgeschoss geben"; var presentNumber = 10; var presentNumberNext = 15; var naughtyUpgrades = { snowballMaster: false, snowballCanon: false, assimilatingSnow: false, masterfulThrowingArm: false, electroBall: true, housedestroyer: true, icySurprise: true, shotThrough: true }; var kindUpgrades = { premiumDelivery: false, coldResistance: false, santaCrow: false, transcendence: false, weatherproofPackaging: false, goldenSnowflakes: true, warmingCoat: false, coldRegards: true, stormKing: true, frostProtection: true, snowballDelivery: true }; var enemyBadUpgrades = { doublePack: false, badGirls: false, deadlySnowfall: false, hiddenKnifeCanon: true, hiddenBomber: true, hiddenKamikaze: true, ghostOfEvilChristmas: true }; var enemyGoodUpgrades = { biggerClouds: false, replicatingSnow: false, brokenChimneys: true, upsideDownWorld: true, freezingCircumstances: false }; var hints = ["ravenHitBySnowball", "ravenStealsAPresent", "howToGetASuperPresent", "howToThrowPresents", "secretsInTheClouds", "advantageFromAbove", "advantageFromBelow", "movementProtectsAgainstColdness", "hitBoxPresent", "selflessAct", "whiteChristmas", "bugsPresents", "bugsPresents2", "presentsCanBeDestroyedByStorm", "howToUseChristmasKeeperMode", "HowToUseEscapeMode", "recordHunt", "hiddenInClouds", "interceptsFlyingEnvelopes"]; var Game = Container.expand(function () { var self = Container.call(this); self.handleSantaHit = function () { if (!santa.invincible) { if (santa.bellLives <= 0) { self.showGameOverScreen(); } else { santa.bellLives--; var lastBellIndex = santa.bells.length - 1; if (lastBellIndex >= 0) { var lastBell = santa.bells[lastBellIndex]; lastBell.destroy(); santa.bells.splice(lastBellIndex, 1); } santa.invincible = true; santa.blinkInterval = LK.setInterval(function () { santa.alpha = santa.alpha === 1 ? 0.5 : 1; }, 100); LK.setTimeout(function () { santa.invincible = false; LK.clearInterval(santa.blinkInterval); santa.alpha = 1; }, 2000); } } }; var gameover = false; var intro = true; var spawnForbidden = true; self.showGameOverScreen = function () { LK.off('tick'); stage.off('down'); stage.off('up'); stage.off('move'); var gameOverScreen = new Container(); gameOverScreen.alpha = 1; var randomHintIndex = Math.floor(Math.random() * hints.length); var gameOverGraphics = gameOverScreen.createAsset(hints[randomHintIndex], 'Game Over Screen', 0.5, 0.5); gameOverGraphics.x = 2048 / 2; gameOverGraphics.y = 2732 / 2; var okButton = gameOverScreen.createAsset('okButton', 'OK Button', 0.5, 0.5); okButton.x = 2048 / 2; okButton.y = 2732 / 2 + 1000; gameover = true; var highscore = 0; var thisscore = killCount + score; var wincolor = "goldenrod"; if (killCount > score) { wincolor = "#55ff55"; } else if (score > killCount) { wincolor = "#ff5555"; } var thisscoreTxt = new Text2('0', { size: 150, fill: "goldenrod", align: 'center' }); thisscoreTxt.anchor.set(0.5, 0); thisscoreTxt.x = 2048 / 2; thisscoreTxt.y = 2482; thisscoreTxt.setText(thisscore); self.addChild(thisscoreTxt); gameOverScreen.on('down', function (obj) { var event = obj.event; var pos = event.getLocalPosition(gameOverScreen); if (gameOverGraphics.alpha === 0.25 && !gameOverGraphics.getBounds().contains(pos.x, pos.y)) { gameOverGraphics.alpha = 1; } else if (!gameOverGraphics.getBounds().contains(pos.x, pos.y)) { gameOverGraphics.alpha = 0.25; } }); okButton.on('down', function () { gameOverScreen.destroy(); LK.showGameOver(); }); this.addChild(gameOverScreen); }; var background = self.createAsset('background', 'Game Background', 0, 0); self.addChild(background); background.width = 2200; background.height = 2732; background.speed = -1; self.background2 = self.createAsset('background', 'Game Background', 0, 0); self.addChild(self.background2); self.background2.width = -2200; self.background2.height = 2732; self.background2.x = 4400; self.backgroundB = self.createAsset('backgroundSky', 'Game Background Sky', 0, 0); self.addChildAt(self.backgroundB, 0); self.backgroundB.width = 2200; self.backgroundB.height = 2732; self.backgroundB.x = 0; self.backgroundA = self.createAsset('backgroundSky', 'Game Background Sky', 0, 0); self.addChildAt(self.backgroundA, 0); self.backgroundA.width = -2200; self.backgroundA.height = 2732; self.backgroundA.x = 4400; background.move = function () { background.x += background.speed; self.background2.x += background.speed; self.backgroundB.x += background.speed + 0.5; self.backgroundA.x += background.speed + 0.5; if (background.x <= -2200) background.x = 2200; if (self.background2.x <= 0) self.background2.x = 4400; if (self.backgroundB.x <= -2200) self.backgroundB.x = 2200; if (self.backgroundA.x <= 0) self.backgroundA.x = 4400; }; var scoreTxt = new Text2('0', { size: 150, fill: "#55ff55", align: 'center' }); scoreTxt.anchor.set(0.5, 0); scoreTxt.x = 2048 / 2 - 200; scoreTxt.y = 100; self.addChild(scoreTxt); var killCount = 0; var killTxt = new Text2(killCount.toString(), { size: 150, fill: "#ff5555", align: 'center' }); killTxt.anchor.set(0.5, 0); killTxt.x = 2048 / 2 + 200; killTxt.y = 100; var equalTxt = new Text2('=', { size: 150, fill: "#ffd700", align: 'center' }); equalTxt.anchor.set(0.5, 0); equalTxt.x = 2048 / 2; equalTxt.y = 100; self.addChild(equalTxt); self.addChild(killTxt); var collisionCheckCounter = 0; var presents = []; var collectableBells = []; var snowballs = []; var envelopes = []; var naughtyPresents = []; var kindPresents = []; var deadlyPresents = []; var superPresents = []; var chimneys = []; var clouds = []; var snowflakes = []; var brats = []; var ravens = []; var naughtySnowballs = []; var ravenAnger = 0; var consecutiveRavenKills = 0; var consecutiveSatisfiedChimneys = 0; var score = 0; self.santaCollideSnowflakes = function (santa, snowflakes) { for (var s = 0; s < snowflakes.length; s++) { var santaIsDead = false; var warmClothesHit = santa.sledgeIntersects(snowflakes[s]); if (santa.customIntersects(snowflakes[s]) || warmClothesHit) { if (snowflakes[s].deadlySnowflake && (!warmClothesHit && kindUpgrades["warmingCoat"] || !kindUpgrades["warmingCoat"])) { self.handleSantaHit(); } else { if (!(warmClothesHit && kindUpgrades["warmingCoat"])) { if (enemyGoodUpgrades["freezingCircumstances"]) { if (!self.frozenEffect) { self.frozenEffect = self.createAsset('frozenFrameEffect', 'Frozen Frame Graphics', 0.5, 0.5); self.frozenEffect.x = 2048 / 2; self.frozenEffect.y = 2732 / 2; self.frozenEffect.alpha = 0.6; self.addChild(self.frozenEffect); } if (snowflakes[s] && !snowflakes[s].goldenSnowflake && !santa.goldenBeard && santa.slowDownTimer >= 1) { self.handleSantaHit(); } } santa.slowDownTimer = 180; santa.removeChild(santa.frozenBeard); santa.frozenBeard = null; if (snowflakes[s].goldenSnowflake) santa.goldenBeard = true; if (!snowflakes[s].goldenSnowflake && !santa.goldenBeard) { santa.frozenBeard = santa.createAsset('frozenBeard', 'Frozen Beard Graphics', 0.5, 0.5); santa.frozenBeard.rotation = 345 * Math.PI / 180; santa.frozenBeard.x -= 80; santa.frozenBeard.y -= 80; santa.addChild(santa.frozenBeard); } else { santa.frozenBeard = santa.createAsset('frozenGoldenBeard', 'Frozen Golden Beard Graphics', 0.5, 0.5); santa.frozenBeard.rotation = 345 * Math.PI / 180; santa.frozenBeard.x -= 90; santa.frozenBeard.y -= 90; santa.addChild(santa.frozenBeard); santa.goldenBeard = true; } } if (naughtyUpgrades.snowballCanon) { var snowball = new CurvedSnowball(); snowball.x = santa.x - 100; snowball.y = santa.y; snowball.angle = Math.atan2(snowball.y - santa.y, snowball.x - santa.x - 100); santa.parent.addChild(snowball); snowballs.push(snowball); } if (snowflakes[s].goldenSnowflake) { score += 1; if (score >= presentNumber) { prepareSpawningUpgrade(); } killCount += 1; scoreTxt.setText(score.toString()); killTxt.setText(killCount.toString()); equalTxt.setText(score > killCount ? '>' : killCount > score ? '<' : '='); var floatingText = new FloatingText('+1', snowflakes[s].x, snowflakes[s].y, 'goldenrod'); self.addChild(floatingText); } } if (!santaIsDead) { snowflakes[s].destroy(); snowflakes.splice(s, 1); s--; continue; } } } }; self.santaCollideClouds = function (santa, clouds) { var santaIsHidden = false; for (var k = 0; k < clouds.length; k++) { if (santa.customIntersects(clouds[k])) { clouds[k].revealing(); if (clouds[k].storm) { self.handleSantaHit(); } if (clouds[k].stormCreated) { if (!self.cloudEffectOn) { self.cloudStormEffect = self.createAsset('stormFrameEffect', 'Storm Frame Graphics', 0.5, 0.5); self.cloudStormEffect.x = 2048 / 2; self.cloudStormEffect.y = 2732 / 2; self.cloudStormEffect.alpha = 0.5; self.cloudStormEffect.rotationSpeed = 0.01; self.cloudStormEffect.updateRotation = function () { this.rotation += this.rotationSpeed; }; LK.on('tick', self.cloudStormEffect.updateRotation.bind(self.cloudStormEffect)); self.addChild(self.cloudStormEffect); self.cloudEffectOn = true; } } if (santa.sledgeIntersects(clouds[k])) { santaIsHidden = true; if (!self.cloudEffectOn && !self.cloudStormEffect) { self.cloudEffect = self.createAsset('cloudFrameEffect', 'Cloud Frame Graphics', 0.5, 0.5); self.cloudEffect.x = 2048 / 2; self.cloudEffect.y = 2732 / 2; self.cloudEffect.alpha = 0; self.addChild(self.cloudEffect); self.cloudEffectOn = true; } else if (self.cloudEffect && self.cloudEffect.alpha <= 0.4) { self.cloudEffect.alpha += 0.05; } } } else if (santa.sledgeIntersects(clouds[k])) { clouds[k].revealing(); if (santa.customIntersects(clouds[k])) { santaIsHidden = true; } } } santa.hidden = santaIsHidden; if (!santaIsHidden && self.cloudEffectOn) { if (self.cloudStormEffect && self.cloudStormEffect > 0) { self.cloudStormEffect.alpha -= 0.2; } if (self.cloudEffect && self.cloudEffect.alpha > 0) { self.cloudEffect.alpha -= 0.1; } else { if (self.cloudEffect) { self.removeChild(self.cloudEffect); self.cloudEffect = null; } else if (self.cloudStormEffect) { self.removeChild(self.cloudStormEffect); self.cloudStormEffect = null; } self.cloudEffectOn = false; } } }; self.santaCollideRavens = function (santa, ravens) { for (var r = 0; r < ravens.length; r++) { if (santa.customIntersects(ravens[r]) || santa.sledgeIntersects(ravens[r])) { self.handleSantaHit(); } } }; self.snowballCollideRavens = function (snowballs, ravens) { for (var r = 0; r < ravens.length; r++) { for (var s = 0; s < snowballs.length; s++) { if (!ravens[r].invulnerable && ravens[r].intersects(snowballs[s])) { if (ravens[r].carryingPresent) { ravens[r].carryingPresent.abducted = false; ravens[r].carryingPresent.carriedByBird = false; } ++killCount; if (killCount >= presentNumber) { prepareSpawningUpgrade(); } var floatingText = new FloatingText('+1', ravens[r].x, ravens[r].y, '#ff0000'); self.addChild(floatingText); killTxt.setText(killCount.toString()); killTxt.setText(killCount.toString()); equalTxt.setText(score > killCount ? '>' : killCount > score ? '<' : '='); ravenAnger = Math.min(++ravenAnger, 30); var destroyedRaven = new DestroyedRaven(ravens[r].x, ravens[r].y, snowballs[s].moveSpeed, snowballs[s].angle); self.addChild(destroyedRaven); snowballs[s].destroy(); snowballs.splice(s, 1); ravens[r].destroy(); ravens.splice(r, 1); r--; break; } } if (r < 0) continue; if (ravens[r].x < -100 || ravens[r].y > 2732 || ravens[r].y < 0) { ravens[r].invulnerable = true; ravens[r].destroy(); ravens.splice(r, 1); consecutiveRavenKills = 0; r--; } } }; self.snowballCollideSnowflakes = function (snowflakes) { for (var i = snowballs.length - 1; i >= 0; i--) { for (var s = (snowflakes && snowflakes.length) - 1; s >= 0; s--) { if (snowballs[i].intersects(snowflakes[s])) { if (snowflakes[s].deadlySnowflake) { snowballs[i].createAsset('redSnowball', 'Red Snowball Graphics', 0.5, 0.5); } else if (snowflakes[s].goldenSnowflake) { snowballs[i].createAsset('goldenSnowball', 'Golden Snowball Graphics', 0.5, 0.5); score += 1; killCount += 1; if (killCount >= presentNumber || score >= presentNumber) { prepareSpawningUpgrade(); } scoreTxt.setText(score.toString()); equalTxt.setText(score > killCount ? '>' : killCount > score ? '<' : '='); killTxt.setText(score.toString()); var floatingText = new FloatingText('+1', snowflakes[s].x, snowflakes[s].y, '#55ff55'); self.addChild(floatingText); } snowballs[i].scale.x += 0.25 * snowflakes[s].scale.x; snowballs[i].scale.y += 0.25 * snowflakes[s].scale.y; snowflakes[s].destroy(); snowflakes.splice(s, 1); } } } }; self.handlePresentsCollisions = function (presents, snowballs, clouds, ravens, santa, deadlyPresents) { for (var i = presents.length - 1; i >= 0; i--) { if (presents[i].carriedByBird && (presents[i].x + presents[i].width < 0 || presents[i].x - presents[i].width > 2048)) { presents[i].destroy(); presents.splice(i, 1); LK.setTimeout((function () { var deadlyPresent = new DeadlyPresent(); deadlyPresent.x = santa.x; deadlyPresent.y = 0; deadlyPresents.push(deadlyPresent); this.addChild(deadlyPresent); ravenAnger = Math.max(ravenAnger - 5, 0); }).bind(this), 3000); } for (var s = snowballs.length - 1; s >= 0; s--) { if (presents[i] && presents[i].intersects(snowballs[s])) { presents[i].x = snowballs[s].x; presents[i].y = snowballs[s].y; presents[i].moveSpeed = snowballs[s].moveSpeed; presents[i].angle = snowballs[s].angle; presents[i].frontThrow = true; if (!kindUpgrades["snowballDelivery"] && kindUpgrades["snowballDelivery"] && !presents[i].snowballDeliveryBonus) { presents[i].snowballDeliveryBonus = true; presents[i].scoreValue *= 2; } } } for (var r = 0; r < ravens.length; r++) { if (!ravens[r].hitByPresent && ravens[r].intersects(presents[i])) { ravens[r].hitByPresent = true; ravens[r].carryingPresent = presents[i]; presents[i].abducted = true; presents[i].carriedByBird = true; } } } }; this.checkChimneyCollisions = function () { for (var j = 0; j < chimneys.length; j++) { if ((kindUpgrades["transcendence"] && !santa.isStationary || !kindUpgrades["transcendence"]) && santa.sledgeIntersects(chimneys[j])) { self.showGameOverScreen(); } for (var i = 0; i < presents.length; i++) { if (!presents[i].abducted && chimneys[j].intersects(presents[i]) && presents[i].y <= chimneys[j].y - chimneys[j].height / 2 + 65) { if (!chimneys[j].satisfied) { score += presents[i].scoreValue; if (score >= presentNumber) { prepareSpawningUpgrade(); } var floatingText = new FloatingText('+' + presents[i].scoreValue, presents[i].x, presents[i].y, '#00ff00'); self.addChild(floatingText); scoreTxt.setText(score.toString()); equalTxt.setText(score > killCount ? '>' : killCount > score ? '<' : '='); chimneys[j].satisfied = true; } presents[i].destroy(); presents.splice(i, 1); } } if (kindUpgrades["santaCrow"]) { for (var i = 0; i < deadlyPresents.length; i++) { if (chimneys[j].intersects(deadlyPresents[i]) && deadlyPresents[i].y <= chimneys[j].y - chimneys[j].height / 2 + 65) { if (!chimneys[j].satisfied) { score++; if (score >= presentNumber) { prepareSpawningUpgrade(); } var floatingText = new FloatingText('+' + presents[i].scoreValue, chimneys[j].x, chimneys[j].y, '#55ff55'); self.addChild(floatingText); scoreTxt.setText(score.toString()); equalTxt.setText(score > killCount ? '>' : killCount > score ? '<' : '='); chimneys[j].satisfied = true; } deadlyPresents[i].destroy(); deadlyPresents.splice(i, 1); } } } if (chimneys[j].y - chimneys[j].height > 2732) { chimneys[j].destroy(); chimneys.splice(j, 1); } else if (chimneys[j].x < -chimneys[j].width) { consecutiveSatisfiedChimneys = 0; chimneys[j].destroy(); chimneys.splice(j, 1); } } }; self.handleCloudInteractionsAndDestruction = function (clouds, snowballs, presents) { for (var k = 0; k < clouds.length; k++) { for (var s = 0; s < snowballs.length; s++) { if (clouds[k].intersects(snowballs[s])) { clouds[k].revealing(); } } for (var p = 0; p < presents.length; p++) { if (clouds[k].intersects(presents[p])) { clouds[k].revealing(); if (!kindUpgrades["weatherproofPackaging"] && clouds[k].storm && clouds[k].intersects(presents[p])) { var destroyedPresent = new DestroyedPresentByStorm(presents[p].x, presents[p].y, clouds[k].speed); this.addChild(destroyedPresent); this.removeChild(presents[p]); presents[p].destroy(); presents.splice(p, 1); } } } if (enemyGoodUpgrades["replicatingSnow"] && !clouds[k].revealed) { for (var i = 0; i < snowflakes.length; i++) { if (snowflakes[i].scale.x >= 0.6 && !snowflakes[i].goldenSnowflake && clouds[k].intersects(snowflakes[i])) { var snowflake = new Snowflake(); snowflake.x = clouds[k].x - 200; snowflake.y = clouds[k].y + 50; snowflake.scale.x = snowflakes[i].scale.x / 3 * 2; snowflake.scale.y = snowflakes[i].scale.y / 3 * 2; snowflakes.push(snowflake); self.addChild(snowflake); var snowflake2 = new Snowflake(); snowflake2.x = clouds[k].x + 200; snowflake2.y = clouds[k].y + 50; snowflake2.scale.x = snowflakes[i].scale.x / 3 * 2; snowflake2.scale.y = snowflakes[i].scale.y / 3 * 2; snowflakes.push(snowflake2); self.addChild(snowflake2); snowflakes[i].destroy(); snowflakes.splice(i, 1); if (snowflakes[i].deadlySnowflake) { snowflake.deadlySnowflake = true; snowflake2.deadlySnowflake = true; } else { snowflake.deadlySnowflake = false; snowflake2.deadlySnowflake = false; } snowflake.goldenSnowflake = false; snowflake2.goldenSnowflake = false; } } } if (clouds[k].x < -clouds[k].width) { if (santa.hidden) santa.hidden = false; clouds[k].destroy(); clouds.splice(k, 1); k--; } } }; var santa = self.addChild(new Santa()); santa.x = 2048 / 2; santa.y = 2732 / 2; var deviceQuestionText = new Text2('On which device are you playing?', { size: 100, fill: '#fff', align: 'center' }); deviceQuestionText.anchor.set(0.5, 0.5); deviceQuestionText.x = 2048 / 2; deviceQuestionText.y = 100; self.addChild(deviceQuestionText); var clickAnywhere = new Text2('Click anywhere to start the game!', { size: 100, fill: 'goldenrod', align: 'center' }); clickAnywhere.anchor.set(0.5, 0.5); clickAnywhere.x = 2048 / 2; clickAnywhere.y = 2000; self.addChild(clickAnywhere); var title = self.addChild(new Title()); var introBegins = true; var titleReveals = false; var adventureBegins = false; var controlerWasChoosen = false; LK.on('tick', function () { background.move(); if (intro) { if (introBegins) { scoreTxt.alpha = 0; killTxt.alpha = 0; equalTxt.alpha = 0; background.alpha = 0; self.background2.alpha = 0; self.backgroundB.alpha = 0; self.backgroundA.alpha = 0; clickAnywhere.alpha = 0; title.alpha = 0; santa.alpha = 0; var smartphone = self.addChild(new SmartPhone()); self.smartphone = smartphone; var pc = self.addChild(new PC()); self.pc = pc; title.alpha = 0; pc.on('down', function () { controlMechanismPC = true; controlerWasChoosen = true; deviceQuestionText.destroy(); pc.destroy(); smartphone.destroy(); }); smartphone.on('down', function () { controlMechanismTouch = true; controlerWasChoosen = true; deviceQuestionText.destroy(); pc.destroy(); smartphone.destroy(); }); introBegins = false; } if (controlerWasChoosen && background.alpha < 1) { background.alpha += 0.005; self.background2.alpha += 0.005; self.backgroundB.alpha += 0.005; self.backgroundA.alpha += 0.005; if (background.alpha >= 1) { titleReveals = true; background.alpha = 1; self.background2.alpha = 1; self.backgroundB.alpha = 1; self.backgroundA.alpha = 1; } } if (titleReveals) { if (title.alpha <= 1) { title.alpha += 0.0025; } else if (clickAnywhere.alpha <= 1) { clickAnywhere.alpha = 1; } } if (adventureBegins) { title.destroy(); clickAnywhere.destroy(); intro = false; background.alpha = 1; self.background2.alpha = 1; self.backgroundB.alpha = 1; self.backgroundA.alpha = 1; santa.alpha = 1; scoreTxt.alpha = 1; killTxt.alpha = 1; equalTxt.alpha = 1; LK.setTimeout(spawnEnvelope, 60000); LK.setTimeout(spawnSnowflake, 0); LK.setTimeout(spawnCloud, 10000); LK.setTimeout(spawnRaven, 3000); LK.setTimeout(spawnBrat, 30000); spawnChimney(); } } else { santa.move(touchPosition); self.collisionTick = false; self.collisionTickB = false; self.collisionTickC = false; if (collisionCheckCounter++ % 7 == 0) { self.collisionTick = true; } else if (collisionCheckCounter % 7 == 2) { self.collisionTickB = true; } else if (collisionCheckCounter % 7 == 4) { self.collisionTickC = true; } else if (collisionCheckCounter % 7 == 6) { self.collisionTickD = true; } if (self.collisionTick) { self.santaCollideRavens(santa, ravens); } if (self.collisionTick) { self.santaCollideSnowflakes(santa, snowflakes); } if (self.collisionTickD) { self.santaCollideClouds(santa, clouds); } if (self.collisionTickB) { self.snowballCollideRavens(snowballs, ravens); } if (self.collisionTick || self.collisionTickB || self.collisionTickC || self.collisionTickD) { self.handlePresentsCollisions(presents, snowballs, clouds, ravens, santa, deadlyPresents); } if (naughtyUpgrades["assimilatingSnow"] && self.collisionTickB) { self.snowballCollideSnowflakes(snowflakes); } if (self.collisionTickB) { self.checkChimneyCollisions(); } if (self.collisionTickD) { self.handleCloudInteractionsAndDestruction(clouds, snowballs, presents); } for (var i = presents.length - 1; i >= 0; i--) { presents[i].fall(); if (self.collisionTick && presents[i] && presents[i].y - presents[i].height > 2732) { presents[i].destroy(); presents.splice(i, 1); } } for (var j = 0; j < chimneys.length; j++) { chimneys[j].moveAndCheckBounds(); } for (var i = superPresents.length - 1; i >= 0; i--) { superPresents[i].fall(); if (self.collisionTick && santa.customIntersects(superPresents[i]) || santa.sledgeIntersects(superPresents[i])) { superPresents[i].destroy(); superPresents.splice(i, 1); var naughtyKeys = Object.keys(naughtyUpgrades).filter(function (key) { return !naughtyUpgrades[key]; }); var kindKeys = Object.keys(kindUpgrades).filter(function (key) { return !kindUpgrades[key]; }); if (naughtyKeys.length > 0) { var randomNaughtyUpgrade = naughtyKeys[Math.floor(Math.random() * naughtyKeys.length)]; naughtyUpgrades[randomNaughtyUpgrade] = true; var upgradeIcon = new UpgradeIcon(randomNaughtyUpgrade, killTxt.x + killTxt.width / 2 + 100, killTxt.y); self.addChild(upgradeIcon); } if (kindKeys.length > 0) { var randomKindUpgrade = kindKeys[Math.floor(Math.random() * kindKeys.length)]; kindUpgrades[randomKindUpgrade] = true; var upgradeIcon = new UpgradeIcon(randomKindUpgrade, scoreTxt.x - scoreTxt.width * 2 - 300, scoreTxt.y); self.addChild(upgradeIcon); } continue; } if (self.collisionTick && superPresents[i].y - superPresents[i].height > 2732) { superPresents[i].destroy(); superPresents.splice(i, 1); } } for (var i = naughtyPresents.length - 1; i >= 0; i--) { naughtyPresents[i].fall(); if (self.collisionTick && santa.customIntersects(naughtyPresents[i]) || santa.sledgeIntersects(naughtyPresents[i])) { naughtyPresents[i].destroy(); naughtyPresents.splice(i, 1); var naughtyKeys = Object.keys(naughtyUpgrades).filter(function (key) { return !naughtyUpgrades[key]; }); if (naughtyKeys.length > 0) { var randomNaughtyUpgrade = naughtyKeys[Math.floor(Math.random() * naughtyKeys.length)]; naughtyUpgrades[randomNaughtyUpgrade] = true; var upgradeIcon = new UpgradeIcon(randomNaughtyUpgrade, killTxt.x + killTxt.width / 2 + 100, killTxt.y); self.addChild(upgradeIcon); } continue; } if (self.collisionTick && naughtyPresents[i].y - naughtyPresents[i].height > 2732) { naughtyPresents[i].destroy(); naughtyPresents.splice(i, 1); } } for (var i = kindPresents.length - 1; i >= 0; i--) { kindPresents[i].fall(); if (self.collisionTick && santa.customIntersects(kindPresents[i]) || santa.sledgeIntersects(kindPresents[i])) { kindPresents[i].destroy(); kindPresents.splice(i, 1); var kindKeys = Object.keys(kindUpgrades).filter(function (key) { return !kindUpgrades[key]; }); if (kindKeys.length > 0) { var randomKindUpgrade = kindKeys[Math.floor(Math.random() * kindKeys.length)]; kindUpgrades[randomKindUpgrade] = true; var upgradeIcon = new UpgradeIcon(randomKindUpgrade, scoreTxt.x - scoreTxt.width * 2 - 100, scoreTxt.y); self.addChild(upgradeIcon); } continue; } if (self.collisionTick && kindPresents[i].y > 2732 - kindPresents[i].height) { kindPresents[i].destroy(); kindPresents.splice(i, 1); } } for (var i = snowballs.length - 1; i >= 0; i--) { snowballs[i].move(); if (self.collisionTickC && (snowballs[i].y - snowballs[i].height > 2738 || snowballs[i].x - snowballs[i].width > 2048 || snowballs[i].x + snowballs[i].width < 0)) { snowballs[i].destroy(); snowballs.splice(i, 1); } } for (var i = deadlyPresents.length - 1; i >= 0; i--) { deadlyPresents[i].fall(); if (self.collisionTickB) { if (santa.customIntersects(deadlyPresents[i]) || santa.sledgeIntersects(deadlyPresents[i])) { self.handleSantaHit(); } if (deadlyPresents[i].y > 2732) { deadlyPresents[i].destroy(); deadlyPresents.splice(i, 1); } } } for (var r = 0; r < ravens.length; r++) { ravens[r].move(); } for (var b = 0; b < brats.length; b++) { brats[b].move(); if (self.collisionTickC && santa.customIntersects(brats[b]) || santa.sledgeIntersects(brats[b])) { self.handleSantaHit(); } for (var i = snowballs.length - 1; i >= 0; i--) { if (self.collisionTickC && snowballs[i] && brats[b] && brats[b].intersects(snowballs[i])) { var destroyedBrat = new DestroyedBrat(brats[b].bratType, brats[b].x, brats[b].y, snowballs[i].moveSpeed, snowballs[i].angle); self.addChild(destroyedBrat); ++killCount; if (killCount >= presentNumber) { prepareSpawningUpgrade(); } var floatingText = new FloatingText('+1', brats[b].x, brats[b].y, '#ff0000'); self.addChild(floatingText); killTxt.setText(killCount.toString()); equalTxt.setText(score > killCount ? '>' : killCount > score ? '<' : '='); if (killCount >= presentNumber) { prepareSpawningUpgrade(); } snowballs[i].destroy(); snowballs.splice(i, 1); brats[b].destroy(); brats.splice(b, 1); b--; continue; } } for (var i = 0; i < presents.length; i++) { if (self.collisionTickC && !presents[i].abducted && brats[b] && brats[b].intersects(presents[i])) { var destroyedBrat = new DestroyedBrat(brats[b].bratType, brats[b].x, brats[b].y, presents[i].moveSpeed, presents[i].angle); self.addChild(destroyedBrat); score += presents[i].scoreValue; var floatingText = new FloatingText('+1', brats[b].x, brats[b].y, '#00ff00'); self.addChild(floatingText); if (score >= presentNumber) { prepareSpawningUpgrade(); } scoreTxt.setText(score.toString()); equalTxt.setText(score > killCount ? '>' : killCount > score ? '<' : '='); presents[i].destroy(); presents.splice(i, 1); brats[b].destroy(); brats.splice(b, 1); b--; continue; } } if (kindUpgrades["santaCrow"] && self.collisionTickB) { for (var i = 0; i < deadlyPresents.length; i++) { if (self.collisionTickC && brats[b].intersects(deadlyPresents[i])) { ++score; if (score >= presentNumber) { prepareSpawningUpgrade(); } scoreTxt.setText(score.toString()); equalTxt.setText(score > killCount ? '>' : killCount > score ? '<' : '='); deadlyPresents[i].destroy(); deadlyPresents.splice(i, 1); brats[b].destroy(); brats[b].splice(b, 1); b--; continue; } } } if (self.collisionTick && brats[b] && (brats[b].x - brats[b].width > 2048 || brats[b].y > 2732 || brats[b].y < 0)) { brats[b].destroy(); brats.splice(b, 1); b--; } } for (var n = 0; n < naughtySnowballs.length; n++) { naughtySnowballs[n].move(); if (self.collisionTickB && santa.customIntersects(naughtySnowballs[n]) || santa.sledgeIntersects(naughtySnowballs[n])) { if (naughtySnowballs[n].glueSnowball === true) { if (enemyGoodUpgrades["freezingCircumstances"] && !santa.goldenBeard && santa.slowDownTimer >= 1) { self.handleSantaHit(); } else if (!santa.frozenBeard) { santa.frozenBeard = santa.createAsset('frozenBeard', 'Frozen Beard Graphics', 0.5, 0.5); santa.frozenBeard.rotation = 345 * Math.PI / 180; santa.frozenBeard.x -= 80; santa.frozenBeard.y -= 80; santa.addChild(santa.frozenBeard); if (enemyGoodUpgrades["freezingCircumstances"]) { self.frozenEffect = self.createAsset('frozenFrameEffect', 'Frozen Frame Graphics', 0.5, 0.5); self.frozenEffect.x = 2048 / 2; self.frozenEffect.y = 2732 / 2; self.frozenEffect.alpha = 0.6; self.addChild(self.frozenEffect); } } santa.slowDownTimer = kindUpgrades["coldResistance"] ? 60 : 180; naughtySnowballs[n].destroy(); naughtySnowballs.splice(n, 1); n--; } else { self.handleSantaHit(); } } else if (self.collisionTick && naughtySnowballs[n].x - naughtySnowballs[n].width > 2048 || naughtySnowballs[n].y > 2732 || naughtySnowballs[n].y < 0) { naughtySnowballs[n].destroy(); naughtySnowballs.splice(n, 1); n--; } } for (var s = 0; s < snowflakes.length; s++) { snowflakes[s].move(); if (self.collisionTick && snowflakes[s].y - snowflakes[s].height > 2732) { snowflakes[s].destroy(); snowflakes.splice(s, 1); s--; } } for (var k = 0; k < clouds.length; k++) { clouds[k].move(); } } for (var b = 0; b < collectableBells.length; b++) { collectableBells[b].move(); if (collisionCheckCounter % 5 == 3) { if (santa.customIntersects(collectableBells[b]) || santa.sledgeIntersects(collectableBells[b])) { santa.bellLives++; collectableBells[b].destroy(); collectableBells.splice(b, 1); b--; } else if (self.x < -self.width) { collectableBells[b].destroy(); collectableBells.splice(b, 1); b--; } } } for (var e = envelopes.length - 1; e >= 0; e--) { envelopes[e].move(); if (self.collisionTick) { if (santa.customIntersects(envelopes[e]) || santa.sledgeIntersects(envelopes[e])) { var enemyBadUpgradeKeys = Object.keys(enemyBadUpgrades).filter(function (key) { return !enemyBadUpgrades[key] && enemyBadUpgrades[key] !== null; }); if (enemyBadUpgradeKeys.length > 0) { var randomUpgradeKey1 = enemyBadUpgradeKeys[Math.floor(Math.random() * enemyBadUpgradeKeys.length)]; var upgradeAssetBad = self.createAsset(randomUpgradeKey1, 'Enemy Bad Upgrade', 0.5, 0.5); upgradeAssetBad.x = 1500; upgradeAssetBad.y = 2000; self.addChild(upgradeAssetBad); upgradeAssetBad.on('down', function () { enemyBadUpgrades[randomUpgradeKey1] = true; var tornUpgrade = new TornUpgrade(randomUpgradeKey2, upgradeAssetGood.x, upgradeAssetGood.y); enemyGoodUpgrades[randomUpgradeKey2] = null; self.addChild(tornUpgrade); if (upgradeAssetBad) { var animationTick = 0; var animationInterval = LK.setInterval(function () { if (animationTick < 60) { animationTick++; upgradeAssetBad.scale.x *= 1.025; upgradeAssetBad.scale.y *= 1.025; upgradeAssetBad.alpha -= 0.0167; } else { LK.clearInterval(animationInterval); upgradeAssetBad.destroy(); } }, 16.6667); } if (upgradeAssetBad) upgradeAssetBad.off('down'); upgradeAssetGood.destroy(); timerBar.destroy(); LK.clearInterval(decisionInterval); }); } var enemyGoodUpgradeKeys = Object.keys(enemyGoodUpgrades).filter(function (key) { return !enemyGoodUpgrades[key] && enemyGoodUpgrades[key] !== null; }); if (enemyGoodUpgradeKeys.length > 0) { var randomUpgradeKey2 = enemyGoodUpgradeKeys[Math.floor(Math.random() * enemyGoodUpgradeKeys.length)]; var upgradeAssetGood = self.createAsset(randomUpgradeKey2, 'Enemy Good Upgrade', 0.5, 0.5); upgradeAssetGood.x = 500; upgradeAssetGood.y = 2000; self.addChild(upgradeAssetGood); upgradeAssetGood.on('down', function () { enemyGoodUpgrades[randomUpgradeKey2] = true; var tornUpgrade = new TornUpgrade(randomUpgradeKey1, upgradeAssetBad.x, upgradeAssetBad.y); enemyBadUpgrades[randomUpgradeKey1] = null; self.addChild(tornUpgrade); if (upgradeAssetGood) { var animationTick = 0; var animationInterval = LK.setInterval(function () { if (animationTick < 60) { animationTick++; upgradeAssetGood.scale.x *= 1.025; upgradeAssetGood.scale.y *= 1.025; upgradeAssetGood.alpha -= 0.0167; } else { LK.clearInterval(animationInterval); upgradeAssetGood.destroy(); } }, 16.6667); } upgradeAssetGood.off('down'); upgradeAssetBad.destroy(); timerBar.destroy(); LK.clearInterval(decisionInterval); }); } var decisionTick = 0; var timerBar = new TimerBar(); self.addChild(timerBar); var decisionInterval = LK.setInterval(function () { if (decisionTick < 300) { decisionTick++; timerBar.updateWidth(1 - 0.0033 * decisionTick); } else { LK.clearInterval(decisionInterval); if (Math.random() < 0.5) { if (upgradeAssetBad) upgradeAssetBad.emit('down'); } else { if (upgradeAssetGood) upgradeAssetGood.emit('down'); } timerBar.destroy(); } }, 16.6667); envelopes[e].destroy(); envelopes.splice(e, 1); } else if (envelopes[e].x + envelopes[e].width < 0) { var animationTick = 0; var enemyBadUpgradeKeys = Object.keys(enemyBadUpgrades).filter(function (key) { return !enemyBadUpgrades[key]; }); if (enemyBadUpgradeKeys.length > 0) { var randomUpgradeKey1 = enemyBadUpgradeKeys[Math.floor(Math.random() * enemyBadUpgradeKeys.length)]; var upgradeAssetBad = self.createAsset(randomUpgradeKey1, 'Enemy Bad Upgrade', 0.5, 0.5); enemyBadUpgrades[randomUpgradeKey1] = true; upgradeAssetBad.x = envelopes[e].x - envelopes[e].width; upgradeAssetBad.y = envelopes[e].y; self.addChild(upgradeAssetBad); var animationInterval = LK.setInterval(function () { if (animationTick < 300) { animationTick++; upgradeAssetBad.alpha -= 0.01; upgradeAssetBad.x += 30; } else { LK.clearInterval(animationInterval); upgradeAssetBad.destroy(); } }, 16.6667); } var enemyGoodUpgradeKeys = Object.keys(enemyGoodUpgrades).filter(function (key) { return !enemyGoodUpgrades[key]; }); if (enemyGoodUpgradeKeys.length > 0) { var randomUpgradeKey2 = enemyGoodUpgradeKeys[Math.floor(Math.random() * enemyGoodUpgradeKeys.length)]; enemyGoodUpgrades[randomUpgradeKey2] = true; var upgradeAssetGood = self.createAsset(randomUpgradeKey2, 'Enemy Good Upgrade', 0.5, 0.5); upgradeAssetGood.x = envelopes[e].x - envelopes[e].width * 3; upgradeAssetGood.y = envelopes[e].y; self.addChild(upgradeAssetGood); var animationInterval2 = LK.setInterval(function () { if (animationTick < 300) { animationTick++; upgradeAssetGood.alpha -= 0.01; upgradeAssetGood.x += 30; } else { LK.clearInterval(animationInterval2); upgradeAssetGood.destroy(); } }, 16.6667); } envelopes[e].destroy(); envelopes.splice(e, 1); e--; } } } }); var enemySpawnInterval = 5000; var envelopeCounter = 0; function spawnEnvelope() { if (!gameover) { envelopeCounter++; var envelope = new FlyingEnvelope(santa); envelope.x = 2048; envelope.y = Math.random() * 2000 + 200; envelopes.push(envelope); self.addChild(envelope); var karma = killCount - score; if (envelopeCounter < 3) { LK.setTimeout(spawnEnvelope, 60000); } } } function spawnRaven() { if (!gameover) { var raven = new Raven(santa, ravenAnger); raven.x = 2048; raven.y = Math.random() * 2000 + 200; ravens.push(raven); self.addChild(raven); if (enemyBadUpgrades["doublePack"]) { var raven = new Raven(santa, ravenAnger); raven.x = 2048; raven.y = Math.random() * 2000 + 200; ravens.push(raven); self.addChild(raven); } var karma = killCount - score; enemySpawnInterval = Math.max(3750, Math.min(5000 - karma * 125, 5000)); LK.setTimeout(spawnRaven, enemySpawnInterval); } } function spawnBrat() { if (!gameover) { var brat = new Brat(santa, naughtySnowballs); brat.x = 0; brat.y = Math.random() * 2000 + 200; brats.push(brat); self.addChild(brat); var karma = killCount - score; enemySpawnInterval = Math.max(3750, Math.min(5000 - karma * 125, 5000)); LK.setTimeout(spawnBrat, enemySpawnInterval * 2.25); } } function spawnSnowflake() { if (!gameover) { var snowflake = new Snowflake(); snowflake.x = Math.random() * 2048; snowflake.y = 0; snowflakes.push(snowflake); self.addChild(snowflake); var karma = score - killCount; var timeOut = Math.max(1500, Math.min(2000 - karma * 50, 2000)); LK.setTimeout(spawnSnowflake, timeOut); } } function spawnCloud() { if (!gameover) { var cloud = new Cloud(); if (Math.random() > 2) { var collectableBell = new CollectableBell(); collectableBell.x = 2248; collectableBell.y = Math.random() * (2732 / 2 + 600); collectableBells.push(collectableBell); self.addChild(collectableBell); cloud.x = collectableBell.x; cloud.y = collectableBell.y; cloud.speed = collectableBell.speed; if (Math.random() * 1 > 0.75) { cloud.blinkTimer = 150 + Math.random() * 150; } clouds.push(cloud); self.addChild(cloud); LK.setTimeout(spawnCloud, 2000 + Math.random() * 3000); } else { cloud.x = 2248; cloud.y = Math.random() * (2732 / 2 + 600); if (Math.random() * 1 > 0.75) { cloud.blinkTimer = 150 + Math.random() * 150; } clouds.push(cloud); self.addChild(cloud); LK.setTimeout(spawnCloud, 2000 + Math.random() * 3000); } } } function spawnChimney() { if (!gameover) { var chimney = new Chimney(); chimney.x = 2448; chimney.y = 2632; chimney.scoreTxt = scoreTxt; chimneys.push(chimney); self.addChild(chimney); LK.setTimeout(spawnChimney, 4000 + Math.random() * 2000); } } function prepareSpawningUpgrade() { var tickCounter = 0; var compareScore = presentNumber; presentNumber += presentNumberNext; presentNumberNext += 5; self.onTick = function () { if (tickCounter < 120) { tickCounter++; } else { if (score >= compareScore ^ killCount >= compareScore) { if (score >= compareScore) { spawnKindPresent(); } if (killCount >= compareScore) { spawnNaughtyPresent(); } } else { spawnSuperPresent(); } LK.off('tick', self.tickReference); } }; self.tickReference = self.onTick.bind(self); LK.on('tick', self.tickReference); } function spawnSuperPresent() { var superPresent = new SuperPresent(); superPresent.x = 2048 / 2; superPresent.y = 0; superPresents.push(superPresent); self.addChild(superPresent); equalTxt.setText(score > killCount ? '>' : killCount > score ? '<' : '='); } function spawnNaughtyPresent() { var naughtyPresent = new NaughtyPresent(); naughtyPresent.x = 2048 / 2; naughtyPresent.y = 0; naughtyPresents.push(naughtyPresent); self.addChild(naughtyPresent); equalTxt.setText(score > killCount ? '>' : killCount > score ? '<' : '='); } function spawnKindPresent() { var kindPresent = new KindPresent(); kindPresent.x = 2048 / 2; kindPresent.y = 0; kindPresents.push(kindPresent); self.addChild(kindPresent); equalTxt.setText(score > killCount ? '>' : killCount > score ? '<' : '='); } var touchPosition = { x: santa.x, y: santa.y }; var controlMechanismPC = false; var controlMechanismTouch = false; var touchedRight = false; var touchedLeft = false; var stayOnPoint = false; var touchedSanta = false; var santaEscapeMode = false; var touchStartTime = 0; stage.on('down', function (obj) { if (!adventureBegins && controlerWasChoosen) { adventureBegins = true; } else if (controlMechanismPC) { var event = obj.event; var pos = event.getLocalPosition(self); if (santa.customIntersects({ x: pos.x, y: pos.y, width: 1, height: 1 }) || santa.keeperModeIntersects({ x: pos.x, y: pos.y, width: 1, height: 1 })) { touchedSanta = true; if (santa.isStationary) { santa.toggleMovement(); touchedSanta = false; santaEscapeMode = true; } } if (gameover && !gameOverScreen.containsPoint(pos)) { gameOverScreen.alpha = 0.25; } if (pos.x <= santa.x + 50) { touchedLeft = true; } else { touchedRight = true; } touchStartTime = Date.now(); } else if (controlMechanismTouch) { var event = obj.event; var pos = event.getLocalPosition(self); if (santa.isStationary && (santa.customIntersects({ x: pos.x, y: pos.y, width: 1, height: 1 }) || santa.keeperModeIntersects({ x: pos.x, y: pos.y, width: 1, height: 1 }))) { santa.toggleMovement(); santaEscapeMode = true; } if (gameover && !gameOverScreen.containsPoint(pos)) { gameOverScreen.alpha = 0.25; } if (pos.x <= santa.x + 50) { touchedLeft = true; } else { touchedRight = true; } touchStartTime = Date.now(); } }); stage.on('up', function (obj) { if (controlMechanismPC && adventureBegins) { var event = obj.event; var pos = event.getLocalPosition(self); if (touchedSanta && Date.now() - touchStartTime >= 250 && (santa.customIntersects({ x: pos.x, y: pos.y, width: 1, height: 1 }) || santa.keeperModeIntersects({ x: pos.x, y: pos.y, width: 1, height: 1 }))) { santa.toggleMovement(); } else if (santa.canThrowSnowball && touchStartTime >= 0 && touchedRight && (naughtyUpgrades["masterfulThrowingArm"] || pos.x > santa.x + 50)) { var snowball = new CurvedSnowball(); snowball.x = santa.x; snowball.y = santa.y - 100; var dx = pos.x - snowball.x; var dy = pos.y - snowball.y; snowball.angle = Math.atan2(dy, dx); var maxDuration = 1; var touchDuration = naughtyUpgrades["snowballMaster"] ? maxDuration : Math.min((Date.now() - touchStartTime) / 1000, maxDuration); snowball.fullLoaded = touchDuration >= 1; snowball.moveSpeed = Math.min(snowball.moveSpeed * touchDuration * 4, 30); snowballs.push(snowball); self.addChild(snowball); santa.throwSnowball(); } else if (!touchedRight && touchStartTime >= 0 && santa.canThrowPresent) { var present = new Present(); if (pos.x > santa.x + 50) { present.frontThrow = true; present.x = santa.x + 75; present.y = santa.y; var dx = pos.x - present.x; var dy = pos.y - present.y; present.angle = Math.atan2(dy, dx); var maxDuration = 1; var touchDuration = Math.min((Date.now() - touchStartTime) / 1000, maxDuration); present.moveSpeed = Math.min(present.moveSpeed * touchDuration, 20); } else { present.x = santa.x; present.y = santa.y + 75; } presents.push(present); self.addChild(present); santa.throwPresent(); } stayOnPoint = false; } else if (controlMechanismTouch && adventureBegins) { var event = obj.event; var pos = event.getLocalPosition(self); if (Date.now() - touchStartTime >= 250 && (santa.customIntersects({ x: pos.x, y: pos.y, width: 1, height: 1 }) || santa.keeperModeIntersects({ x: pos.x, y: pos.y, width: 1, height: 1 }))) { santa.toggleMovement(); } else if (santa.canThrowSnowball && touchStartTime >= 0 && touchedRight && (naughtyUpgrades["masterfulThrowingArm"] || pos.x > santa.x + 50)) { var snowball = new CurvedSnowball(); snowball.x = santa.x; snowball.y = santa.y - 100; var dx = pos.x - snowball.x; var dy = pos.y - snowball.y; snowball.angle = Math.atan2(dy, dx); var maxDuration = 1; var touchDuration = naughtyUpgrades["snowballMaster"] ? maxDuration : Math.min((Date.now() - touchStartTime) / 1000, maxDuration); snowball.fullLoaded = touchDuration >= 1; snowball.moveSpeed = Math.min(snowball.moveSpeed * touchDuration * 4, 30); snowballs.push(snowball); self.addChild(snowball); santa.throwSnowball(); } else if (!touchedRight && touchStartTime >= 0 && santa.canThrowPresent) { var present = new Present(); if (pos.x > santa.x + 50) { present.frontThrow = true; present.x = santa.x + 75; present.y = santa.y; var dx = pos.x - present.x; var dy = pos.y - present.y; present.angle = Math.atan2(dy, dx); var maxDuration = 1; var touchDuration = Math.min((Date.now() - touchStartTime) / 1000, maxDuration); present.moveSpeed = Math.min(present.moveSpeed * touchDuration, 20); } else { present.x = santa.x; present.y = santa.y + 75; } presents.push(present); self.addChild(present); santa.throwPresent(); } } touchedLeft = false; touchedRight = false; touchedSanta = false; santaEscapeMode = false; touchStartTime = 0; }); stage.on('move', function (obj) { if (controlMechanismPC && adventureBegins) { var event = obj.event; var pos = event.getLocalPosition(self); if (Date.now() - touchStartTime < 500 && !stayOnPoint) { stayOnPoint = true; touchPosition = { x: santa.x, y: santa.y }; } else if (!stayOnPoint) { touchPosition = { x: pos.x, y: pos.y }; } } else if (controlMechanismTouch && adventureBegins) { var event = obj.event; var pos = event.getLocalPosition(self); touchPosition = { x: pos.x, y: pos.y }; } }); });
===================================================================
--- original.js
+++ change.js
@@ -565,14 +565,15 @@
self.moveSpeed = snowballType === 'glueSnowball' || snowballType === 'badNut' ? 20 : 10;
self.tickCount = 0;
self.angle = 0;
self.move = function () {
- if (!self.glueSnowball || !self.badNut) {
+ if (!self.glueSnowball && !self.badNut) {
self.y += Math.sin(self.angle) * self.moveSpeed;
- } else if (self.tickCount > 15) {
- self.y += Math.sin(self.angle) * self.moveSpeed + (self.tickCount - 15) * 0.5;
+ } else if (self.tickCount > 30) {
+ self.moveSpeed *= 0.98;
+ self.y += Math.sin(self.angle) * self.moveSpeed + (self.tickCount - 30) * 0.5;
} else {
- self.y += self.moveSpeed + self.tickCount * 0.1;
+ self.y += Math.sin(self.angle) * self.moveSpeed + self.tickCount * 0.1;
}
self.x += Math.cos(self.angle) * self.moveSpeed;
self.rotation += 0.1;
self.tickCount++;
@@ -623,9 +624,9 @@
snowballDelivery: true
};
var enemyBadUpgrades = {
doublePack: false,
- badGirls: true,
+ badGirls: false,
deadlySnowfall: false,
hiddenKnifeCanon: true,
hiddenBomber: true,
hiddenKamikaze: true,
@@ -1265,12 +1266,12 @@
}
if (self.collisionTickD) {
self.santaCollideClouds(santa, clouds);
}
- if (self.collisionTickB || self.collisionTickD) {
+ if (self.collisionTickB) {
self.snowballCollideRavens(snowballs, ravens);
}
- if (self.collisionTickB || self.collisionTickD) {
+ if (self.collisionTick || self.collisionTickB || self.collisionTickC || self.collisionTickD) {
self.handlePresentsCollisions(presents, snowballs, clouds, ravens, santa, deadlyPresents);
}
if (naughtyUpgrades["assimilatingSnow"] && self.collisionTickB) {
self.snowballCollideSnowflakes(snowflakes);
A lazy santa clause on his sleigh with reindeers. 2d cartoon, side view Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A christmas present, cartoon 2d, side view Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A chimney, cartoon 2d, side view Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
2d cartoon cloud, side view, game asset Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
2d cartoon of a lonely snowflake, sideview Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
evil flying cartoon raven, sideview, christmas style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Cartoon of a christmas present, evil raven style, side view Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Froozen beard, cartoon, sideview Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Little brat on a sledge, girl, cartoon, winter, sideview, evil Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Little girl on a sledge, cartoon, winter, sideview, evil, winter boots Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
super christmas present, golden, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Icon for santas cold resistence, cartoon, with the text: „Cold Resistence“ at top Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Icon for premium christmas delivery, cartoon, with the text: „Premium Delivery“ at top Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Icon for santa throwing a snowball, cartoon, with the text: „Snowball Master“ at top Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
christmas present for kind santa, cartoon, power up Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
christmas present for naughty santa, cartoon, power up Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Icon for a Snowball machine on the back of santas sledge, cartoon, with the text „snowball machine“ on the top Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Icon for santa crow, on a circle, with the text „santa crow“ at top Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a pergament with a golden present at top, at the bottom there is the text: "Each tenth point you have the change to get a super Present, make sure naughty points are equal to kind points"
a pergament button with the Text: "OK"; 2 d game asset
a pergament with a raven stealing a christmas present on the top. At the bottom is the text: "Not only are ravens happy to receive gifts and are appeased by them, they also like to give the gift back... with deadly intent."
a pergament with a raven hit by a snowball on the top. At the bottom is the text: "Ravens may be naughty to deserve a snowball, but you should know, Ravens never forget!"
blue electricity in the sky cartoon, 2d
Icon for santa moving through walls, on a circle, with the text „transcendence“ at top, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Icon for a very speedy icicle, on a circle, with the text „pointed Icicle“ at top, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Icon for a froozen christmas present, on a circle, with the text „icy Surprise“ at top, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Icon for a explosive present, on a circle, with the text „detonating wrapping paper“ at top, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Icon for a mechanical arm, on a circle, with the text „Santa Ballista 360“ at top, cartoon, christmas style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Icon for a electified snowball, on a circle, with the text „Thunderball“ at top, cartoon, christmas style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
exclamation mark in the shape of a candy cane Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Icon for a snowball hitting a present in the sky, on a circle, with the text „Snowball Delivery“ at top, cartoon, christmas style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Icon for a santa as a storm king on a circle, with the text „Storm King“ at top, cartoon, christmas style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a pergament with a present throwed by someone into a basket at top, at the bottom there is the text: "There are many ways of how can throw a present. Let it just fall or throw it like a basketball."
a pergament with a snowball and two clouds, in one cloud is a powerful shield hidden, in a other cloud is a grinding grinch with a bomb. There is the text: "Everything can be hidden in the clouds. Throw a snowball to see what is there."
a pergament with santa on a sledge and his flying reindeers throwing a snowball to a raven. There is the text: "Its easier to hit something from above than below. Thanks to gravity."
a pergament with a freezing santa on a sledge in the sky. There is the text: "using the stationary mode is useful, but only movement will warm you up"
a pergament with a flying santa on his sledge hiding for ravens and storms. In front of him is a chimney. There is the text: "Flying low can save you from the birds and bad weather, but there are dangers too"
a pergament with Klaus and Jesper from the movie Klaus. There is the text: "A true selfless act always sparks another. -Klaus"
a pergament of a christmas present with a box glove trap. There is the text: "You think, the hit box is confusing? Thank you for your information. You get a present for this."
Icon for a snowball collide with snoflakes and becomes bigger, on a circle, with the text „ASSIMILATING SNOW“ at top, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Epic background of a grinch village in the mountains, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a electrified destroyed christmas present, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
raven with christmas hat and colorful scarf got hit by a snowball in the air, he is shocked, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a pergament of a christmas present hit by a storm lightning in the sky. There is the text: "Gifts are not guaranteed to withstand storm damage."
a pergament of a Santa Clause on his sledge with reindeers in the sky. He holds a scepter of candy cane. There is the text: "Click on Santa for a short duration to use the KeeperMode."
a pergament of a happy girl. she got a big fat slimy bug as chrismas present. There is the text: "If you find a bug, you cam write me a message on Discord FRVR. - Sasbe"
a pergament of Santa Clause on his flying sledge with reindeers, he flees for ravens and leaves a big frosty cloud behind him. There is the text "In Keeper Mode, you can touch santa and swipe your finger into the direction you want to move with extra speed"
a pergament of many snowflakes in the sky. With a high good Karma Counter. There is the text "high karma is a guarantee for a white christmas... and a slowly workday"
icon of a weatherproof christmas present flying in the sky, on a circle, cartoon. With the text: "weatherproof packaging" Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
epic landscape intro in the clouds. cartoon 2d style. It has the title: "Saint Karma"
a very deadly and sharp snowflake with skull shape, red, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a golden snowflake, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a snowball with magical powder, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a snowball with magical powder, white color with golden tone, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
snow powder in the sky, pixel Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
frozen golden beard, only beard, cartoon, side view Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a smartphone, christmas style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a PC, christmas style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
icon for a golden snowflake, on a circle, on the top is the text: "golden snowflakes" cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
There is the text: "there are many ways zo beat a highscore, but can you also beat all in once?" On a pergament with many highscores called good, bad, max, min and diff.
icon for santa with a thick warm coat, but his face is very cold, on a circle, with the text at top: "warming coat", cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a snowball with red power, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
white snowball with some blue glue, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
flying envelope with wings, christmas style, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a pergament letter with the name "Deadly Snow". It has a snowflake in shape of a skull on it. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a pergament letter with the name "Bad Nuts". It has a evil looking little girl brat with a ponytail on a sledge on it. vertical. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a pergament letter with the name "Very cloudy". It has a big cloud on it. vertical. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
the text "freezing circumstances", in a old font
a speech bubbly with a question mark, cartoon Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a pergament of Santa hiding with his flying sleigh and reindeers in a cloud. There is the text "In clouds you are protected from enemy attention."
a pergament of santa catching a flying envelope in the sky. There is the text "Catch any flying envelopes in the sky. Otherwise the evil forces will become stronger."
frame made of sharp ice, it fill the complete screen, in the center is black only
frame made of cozy clouds, it fill the complete screen, in the center is black only, on black background
frame made of dark clouds, some blue sparks, it fill the complete screen, in the center is white only, on white background
a pergament letter with the name "Replicating Snow". It has a cloud with replicating snowflakes on it. vertical. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a little bell Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a red nut hidden in a snowball, side view, cartoon. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.