Variable update

This commit is contained in:
sam
2023-11-28 13:26:59 +01:00
parent 03e6d69de1
commit f4535ba7f8

View File

@@ -68,18 +68,19 @@ async function disconnect() {
}
//--------------------Game--------------------
let Playerposx = 500;
let playerPosX = 500;
let Playerposy = 300;
let bullets = [];
let myBullet = new bullet();
let playerSpeed = 5;
let radius = 2;
async function Movementloop() {
if (booleanArray[1]) {
Playerposx += 2;}
playerPosX += 2;}
if (booleanArray[3]) {
Playerposx -= 2;}
playerPosX -= 2;}
if (booleanArray[2]) {
Playerposy += 2;}
if (booleanArray[0]) {
@@ -116,7 +117,7 @@ function draw(){
background(0,0,0,10);
// draw a circle at the mouse position
circle(Playerposx, Playerposy, 50);
circle(playerPosX, Playerposy, 50);
}
//test
//test2