User prompt
CREATE A SUBBUTEO GAME FROM THIS
User prompt
avoid the button disapper bug
User prompt
you misunderstood the task. The player selects a button by clicking, pulls the mouse back and the button starts to slide in the opposite direction to a distance equal to the force of the pull back
User prompt
not working
User prompt
add frame to the edges of the map Buttons never left it out
User prompt
add Control Strip an orange line and if player moving back the mouse than line is growing up to how powerfull the shot
User prompt
do it
User prompt
slow down the buttons movement to the guarter
User prompt
add click event to the game to move buttons freely one by one
User prompt
Arrange the player's buttons in a 4-3-4 formation and move the goalkeeper 100 units away from the bottom of the court
User prompt
PLAYER BUTTONS ON THE DOWNER HALF OF THE MAP WHEN THE GAME IS LOADED
Initial prompt
Button Soccer
===================================================================
--- original.js
+++ change.js
@@ -134,33 +134,33 @@
});
}
// Add frame to the edges of the map
playerButtons.forEach(function (button) {
- if (button.x < 0) {
- button.x = 0;
+ if (button.x < 50) {
+ button.x = 50;
}
- if (button.y < 0) {
- button.y = 0;
+ if (button.y < 50) {
+ button.y = 50;
}
- if (button.x > 2048) {
- button.x = 2048;
+ if (button.x > 2048 - 50) {
+ button.x = 2048 - 50;
}
- if (button.y > 2732) {
- button.y = 2732;
+ if (button.y > 2732 - 50) {
+ button.y = 2732 - 50;
}
});
opponentButtons.forEach(function (button) {
- if (button.x < 0) {
- button.x = 0;
+ if (button.x < 50) {
+ button.x = 50;
}
- if (button.y < 0) {
- button.y = 0;
+ if (button.y < 50) {
+ button.y = 50;
}
- if (button.x > 2048) {
- button.x = 2048;
+ if (button.x > 2048 - 50) {
+ button.x = 2048 - 50;
}
- if (button.y > 2732) {
- button.y = 2732;
+ if (button.y > 2732 - 50) {
+ button.y = 2732 - 50;
}
});
};
// Handle player button selection