User prompt
Bütün tuşların "sadece" yüksekliğini arttır
User prompt
Bu tuşları 4e çıkart. Normal tuşlar olcak ama 4 tane olucak. Bende hepsini farklı tasarlayabilicem
User prompt
Oyunu biraz daha hizlandir. Ve ilerledikçe daha da hizlansin. (Erkenden olmasın bu yavaş yavaş ama kararlı bı sekilde hizlansin) ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
Uzun notalari kaldır
User prompt
Uzun notaların colliderini düzelt. Basmama rağmen "early" hatası veriyor
User prompt
Bir notaya erken bastığımız zaman o nota yok olsun. Tekrar basmamiza gerek kalmasın. Uzun notalarda da aynı şekilde. ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
Uzun basmamız gereken notayı çizgiye degdikten sonra başlat tetiğini. Ve bundan sonra her early için eksi puan yiyelim. Not al notalari biraz daha uzat. Ve sıralar arasına görünür bı çizgi çek ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
Early ve missed yazısı ekranın tam ortasında büyük olsun. Uzun basmamız gereken notaya bı kere basmamız yeterli olsun. Uzun basmak sadece ekstra puan versin. Zamanında basabildigimiz her tuş icin de "Nice" yazısı yazsın ekranın ortasında diğerlerinin büyüklüğünde. ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
Tuşlara bastigimi belirgin et. Çizgiye gelmeden bastiklarima "early" uyarısı, çizgiden sonra bastiklarima "Missed" uyarısı yazsın. Ve kaçırma sayım olmasın. Tek hakkım olsun. Tuşları büyüt. Tek tiklamali olan Normal olsun uzun basmanız gerek de biraz daha uzun olsun. Tuşa basma animasyonu da ekle ↪💡 Consider importing and using the following plugins: @upit/tween.v1
Code edit (1 edits merged)
Please save this source code
User prompt
Piano Tiles Rush
Initial prompt
Bana piano tiles gibi bi oyun yap. 4 sıra olsun. Tuşlar olsun. Basılı tutmalı tuşlar olsun. Her bir tuşun animasyonu olsun.
/****
* Plugins
****/
var tween = LK.import("@upit/tween.v1");
/****
* Classes
****/
var QuickTile = Container.expand(function () {
var self = Container.call(this);
var graphics = self.attachAsset('quickTile', {
anchorX: 0.5,
anchorY: 0.5
});
self.speed = 12;
self.lane = 0;
self.hit = false;
self.missed = false;
self.earlyPressed = false;
self.update = function () {
self.y += self.speed;
// Check if tile is past hit line and not hit
if (self.y > hitLineY + 80 && !self.hit && !self.missed) {
self.missed = true;
showFeedback('MISSED', self.lane);
LK.getSound('miss').play();
LK.showGameOver();
}
};
return self;
});
/****
* Initialize Game
****/
var game = new LK.Game({
backgroundColor: 0x1a1a1a
});
/****
* Game Code
****/
var lanes = [];
var hitLineY = 2200;
var tiles = [];
var activeLanes = [false, false, false, false];
var comboCount = 0;
var tileSpawnTimer = 0;
var feedbackTexts = [];
var tileSpawnInterval = 45;
var gameSpeed = 1;
// Create lanes
for (var i = 0; i < 4; i++) {
var lane = game.addChild(LK.getAsset('lane', {
anchorX: 0.5,
anchorY: 0.5
}));
lane.x = 256 + i * 512;
lane.y = 1366;
lanes.push(lane);
}
// Create hit line
var hitLine = game.addChild(LK.getAsset('hitLine', {
anchorX: 0.5,
anchorY: 0.5
}));
hitLine.x = 1024;
hitLine.y = hitLineY;
// Create lane dividers
for (var i = 1; i < 4; i++) {
var divider = game.addChild(LK.getAsset('laneDivider', {
anchorX: 0.5,
anchorY: 0.5
}));
divider.x = i * 512;
divider.y = 1366;
}
// Create UI
var scoreText = new Text2('Score: 0', {
size: 80,
fill: 0xFFFFFF
});
scoreText.anchor.set(0.5, 0);
LK.gui.top.addChild(scoreText);
var comboText = new Text2('Combo: 0', {
size: 60,
fill: 0xFFFF00
});
comboText.anchor.set(0.5, 0);
comboText.y = 100;
LK.gui.top.addChild(comboText);
function updateScoreDisplay() {
scoreText.setText('Score: ' + LK.getScore());
comboText.setText('Combo: ' + comboCount);
}
function showFeedback(text, laneIndex) {
var feedbackText = new Text2(text, {
size: 120,
fill: text === 'EARLY' ? 0xFFFF00 : text === 'MISSED' ? 0xFF0000 : 0x00FF00
});
feedbackText.anchor.set(0.5, 0.5);
feedbackText.x = 1024; // Center of screen
feedbackText.y = 1366; // Center of screen vertically
feedbackText.alpha = 1;
game.addChild(feedbackText);
feedbackTexts.push(feedbackText);
tween(feedbackText, {
alpha: 0,
y: feedbackText.y - 100
}, {
duration: 1000,
onFinish: function onFinish() {
feedbackText.destroy();
var index = feedbackTexts.indexOf(feedbackText);
if (index > -1) feedbackTexts.splice(index, 1);
}
});
}
function spawnTile() {
var laneIndex = Math.floor(Math.random() * 4);
var tile = new QuickTile();
tile.lane = laneIndex;
tile.x = 256 + laneIndex * 512;
tile.y = -100;
tiles.push(tile);
game.addChild(tile);
}
function getLaneFromX(x) {
if (x < 512) return 0;
if (x < 1024) return 1;
if (x < 1536) return 2;
return 3;
}
function activateLane(laneIndex) {
if (laneIndex >= 0 && laneIndex < 4) {
activeLanes[laneIndex] = true;
lanes[laneIndex].removeChild(lanes[laneIndex].children[0]);
var activeLane = LK.getAsset('laneActive', {
anchorX: 0.5,
anchorY: 0.5
});
lanes[laneIndex].addChild(activeLane);
}
}
function deactivateLane(laneIndex) {
if (laneIndex >= 0 && laneIndex < 4) {
activeLanes[laneIndex] = false;
lanes[laneIndex].removeChild(lanes[laneIndex].children[0]);
var normalLane = LK.getAsset('lane', {
anchorX: 0.5,
anchorY: 0.5
});
lanes[laneIndex].addChild(normalLane);
}
}
game.down = function (x, y, obj) {
var laneIndex = getLaneFromX(x);
activateLane(laneIndex);
// Add lane press animation
tween(lanes[laneIndex], {
scaleX: 1.05,
scaleY: 1.05
}, {
duration: 100,
easing: tween.easeOut
});
// Check for quick tile hits
var hitTile = false;
for (var i = 0; i < tiles.length; i++) {
var tile = tiles[i];
if (tile instanceof QuickTile && tile.lane === laneIndex && !tile.hit && !tile.missed && !tile.earlyPressed) {
var distance = Math.abs(tile.y - hitLineY);
if (distance <= 80) {
tile.hit = true;
LK.setScore(LK.getScore() + 10);
comboCount++;
showFeedback('NICE', laneIndex);
LK.getSound('tap').play();
// Visual effect
tween(tile, {
alpha: 0,
scaleX: 1.5,
scaleY: 1.5
}, {
duration: 200,
onFinish: function onFinish() {
tile.destroy();
}
});
updateScoreDisplay();
hitTile = true;
break;
} else if (tile.y < hitLineY - 80) {
// Early press
tile.earlyPressed = true;
showFeedback('EARLY', laneIndex);
LK.getSound('early').play();
LK.setScore(LK.getScore() - 5); // Deduct points for early press
// Destroy tile immediately on early press
tween(tile, {
alpha: 0,
scaleX: 0.5,
scaleY: 0.5
}, {
duration: 200,
onFinish: function onFinish() {
tile.destroy();
}
});
updateScoreDisplay();
hitTile = true;
break;
}
}
}
};
game.up = function (x, y, obj) {
var laneIndex = getLaneFromX(x);
deactivateLane(laneIndex);
// Add lane release animation
tween(lanes[laneIndex], {
scaleX: 1,
scaleY: 1
}, {
duration: 100,
easing: tween.easeOut
});
};
game.update = function () {
// Spawn tiles
tileSpawnTimer++;
if (tileSpawnTimer >= tileSpawnInterval) {
spawnTile();
tileSpawnTimer = 0;
// Increase difficulty over time
if (LK.ticks % 300 === 0) {
gameSpeed += 0.15;
tileSpawnInterval = Math.max(25, tileSpawnInterval - 1);
}
}
// Clean up tiles
for (var i = tiles.length - 1; i >= 0; i--) {
var tile = tiles[i];
if (tile.y > 2800 || tile.hit || tile.completed || tile.missed && tile.y > hitLineY + 200 || tile.earlyPressed && tile.y > 2800) {
if (!tile.destroyed) {
tile.destroy();
tiles.splice(i, 1);
}
}
}
// Update tile speeds based on game speed
for (var i = 0; i < tiles.length; i++) {
tiles[i].speed = 12 * gameSpeed;
}
}; ===================================================================
--- original.js
+++ change.js
@@ -11,9 +11,9 @@
var graphics = self.attachAsset('quickTile', {
anchorX: 0.5,
anchorY: 0.5
});
- self.speed = 8;
+ self.speed = 12;
self.lane = 0;
self.hit = false;
self.missed = false;
self.earlyPressed = false;
@@ -46,9 +46,9 @@
var activeLanes = [false, false, false, false];
var comboCount = 0;
var tileSpawnTimer = 0;
var feedbackTexts = [];
-var tileSpawnInterval = 60;
+var tileSpawnInterval = 45;
var gameSpeed = 1;
// Create lanes
for (var i = 0; i < 4; i++) {
var lane = game.addChild(LK.getAsset('lane', {
@@ -232,11 +232,11 @@
if (tileSpawnTimer >= tileSpawnInterval) {
spawnTile();
tileSpawnTimer = 0;
// Increase difficulty over time
- if (LK.ticks % 600 === 0) {
- gameSpeed += 0.1;
- tileSpawnInterval = Math.max(30, tileSpawnInterval - 2);
+ if (LK.ticks % 300 === 0) {
+ gameSpeed += 0.15;
+ tileSpawnInterval = Math.max(25, tileSpawnInterval - 1);
}
}
// Clean up tiles
for (var i = tiles.length - 1; i >= 0; i--) {
@@ -249,7 +249,7 @@
}
}
// Update tile speeds based on game speed
for (var i = 0; i < tiles.length; i++) {
- tiles[i].speed = 8 * gameSpeed;
+ tiles[i].speed = 12 * gameSpeed;
}
};
\ No newline at end of file
A line. In-Game asset. 2d. High contrast. No shadows
A "single" tile of musical note 🎵. In-Game asset. 2d. High contrast. No shadows
A single tile of musical note 🎵 blue. In-Game asset. 2d. High contrast. No shadows
A single tile of musical note green. In-Game asset. 2d. High contrast. No shadows
A single musical tile red. In-Game asset. 2d. High contrast. No shadows
An UI written "NICE". In-Game asset. 2d. High contrast. No shadows
An UI written "Missed". In-Game asset. 2d. High contrast. No shadows
An UI written "Early". In-Game asset. 2d. High contrast. No shadows
A score display written +10 on it. In-Game asset. 2d. High contrast. No shadows
A score Ui that written -30 on it. In-Game asset. 2d. High contrast. No shadows
An image of "Perfect" Written on it. In-Game asset. 2d. High contrast. No shadows