User prompt
que el jugador vaya a donde se de click en la pantalla ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
ahora coloca arboles aleatorios en todo el mapa
User prompt
que fuera del mapa en las zonas que sobresalen sean del mismo color de el fondo
User prompt
que la camara no vaya mas alla de los arboles del borde del mapa ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
que la camara no sobresalga mas alla de los bordes del mapa ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
la camara un poco mas cerca y que la camara no sobresalga mas alla de el mapa ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
que la camara este mas cerca de el jugador y lo siga hacia donde se mueva
User prompt
quiero que pongas arboles rodeando todos los bordes
User prompt
crea un mapa grande por el que se pueda mover el jugador pero solo el piso ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
que el jugador se vea sobre la el fondo
User prompt
quiero que el mapa sea grande pero que no se vea todo en la pantalla y se muestre solo la zona en la que esta el jugador pero que segun el movimiento del jugador la camara lo siga atravez del mapa ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
quiero que hallan edificios silumando una calle por donde el jugador no pueda pasar
User prompt
que el jugador mire primero hacia el destino y se mueva ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
que mire directamente hacia el punto que se señala segun el click ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
que el jugador gire hacia donde se mueve ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
que el personaje no siga el toque de la pantalla sino que silla el click unico que de haga ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
que el personaje se mueva mas lento ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
elimina todo y deja solo al jugador en un plano en que pueda moverse de manera vertical y horizontal
User prompt
el jugador aun no va a donde se toca la pantalla
User prompt
que el jugador vaya a donde se toque la pantalla ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
que el jugador se mueva segun en donde se toque la pantalla
Code edit (1 edits merged)
Please save this source code
User prompt
Survivor's Quest
Initial prompt
Quiero hacer un juego de supervivencia en el que tenemos que conseguir recursos y almacenarlos para sobrevivir a través de un escenario por el que podamos movernos vertical y horizontalmente desde un plano de vista de 45 grados.
/**** * Plugins ****/ var tween = LK.import("@upit/tween.v1"); var storage = LK.import("@upit/storage.v1"); /**** * Classes ****/ var Player = Container.expand(function () { var self = Container.call(this); var playerGraphics = self.attachAsset('player', { anchorX: 0.5, anchorY: 0.5 }); return self; }); /**** * Initialize Game ****/ var game = new LK.Game({ backgroundColor: 0x87ceeb }); /**** * Game Code ****/ // Create player var player = game.addChild(new Player()); player.x = 1024; player.y = 1366; // Game controls - touch to move player game.down = function (x, y, obj) { // Calculate angle to face movement direction var deltaX = x - player.x; var deltaY = y - player.y; var targetRotation = Math.atan2(deltaY, deltaX); // Use tween for smooth movement and rotation to touched position tween(player, { x: x, y: y, rotation: targetRotation }, { duration: 1200, easing: tween.easeOut }); }; // Main game update loop game.update = function () { // Keep player within bounds player.x = Math.max(30, Math.min(2018, player.x)); player.y = Math.max(30, Math.min(2702, player.y)); };
===================================================================
--- original.js
+++ change.js
@@ -31,12 +31,17 @@
player.x = 1024;
player.y = 1366;
// Game controls - touch to move player
game.down = function (x, y, obj) {
- // Use tween for smooth movement to touched position
+ // Calculate angle to face movement direction
+ var deltaX = x - player.x;
+ var deltaY = y - player.y;
+ var targetRotation = Math.atan2(deltaY, deltaX);
+ // Use tween for smooth movement and rotation to touched position
tween(player, {
x: x,
- y: y
+ y: y,
+ rotation: targetRotation
}, {
duration: 1200,
easing: tween.easeOut
});
robot estilo steampunk visto desde arriba totalmente no desde el frente con llantas. In-Game asset. 2d. High contrast. No shadows. vistasuperior
dame un fondo de color verde pasto. In-Game asset. 2d. High contrast. No shadows
has un robot negro tipo auto steampunk con aspecto desgastado que se mueva con llantas y este en una vista desde arriba In-Game asset. 2d. High contrast. No shadows
explosion realista. In-Game asset. 2d. High contrast. No shadows
haz un corazon con aspecto steampunk metalico desgastado. In-Game asset. 2d. High contrast. No shadows
una bateria energetica estilo steampunk. In-Game asset. 2d. High contrast. No shadows
has una flecha de señalizacion en estilo steampunk. In-Game asset. 2d. High contrast. No shadows
has un rayo. In-Game asset. 2d. High contrast. No shadows
has que se vea en estilo steampunk
has una rueda en estilo steampunk. In-Game asset. 2d. High contrast. No shadows
has un escudo en estilo steampunk. In-Game asset. 2d. High contrast. No shadows
plateada
un 0 es estilo steampunk. In-Game asset. 2d. High contrast. No shadows
1 en estilo steampunk. In-Game asset. 2d. High contrast. No shadows
numero 2 estilo steampunk. In-Game asset. 2d. High contrast. No shadows
numero 3 en estilo steampunk. In-Game asset. 2d. High contrast. No shadows
numero 4 en estilo steampunk. In-Game asset. 2d. High contrast. No shadows
numero 5 en estilo steampunk. In-Game asset. 2d. High contrast. No shadows
numero 6 en estilo steampunk. In-Game asset. 2d. High contrast. No shadows
numero 7 en estilo steampunk. In-Game asset. 2d. High contrast. No shadows
numero 8 en estilo steampunk. In-Game asset. 2d. High contrast. No shadows
numero 9 en estilo steampunk. In-Game asset. 2d. High contrast. No shadows
simbolo ":" en estilo steampunk. In-Game asset. 2d. High contrast. No shadows