Servo moving by itself on joystick control

Good evening. I was doing a single-joystick control on a robot arm, but the servos seem to move by themselves while ignoring the joystick entirely. Any help is appreciated and thank you in advance.

#include <Servo.h>

Servo servobase;
Servo servocodo1;
Servo servoarrab;
int joyX = 0;
int joyY = 1;
int joyVal;

void setup() {
  servobase.attach(3);
  servocodo1.attach(4);
  servoarrab.attach(5);

}

void loop() {
  joyVal = analogRead(joyX);
  joyVal = map (joyVal, -1023, 1023, 0, 180);
    if (joyVal > 0);{
              
              for (int i = 0; i < 90; i++) {
              servocodo1.write(i);
              delay(10);
              }
              for (int i = 30; i > 0; i--) {
              servoarrab.write(i);
              delay(10);
            }
         }

    if (joyVal < 0);{
                  
              for (int i = 90; i > 0; i--) {
              servocodo1.write(i);
              delay(10);
              }
              for (int i = 0; i < 30; i++) {
              servoarrab.write(i);
              delay(10);
            }
         }

    

  joyVal = analogRead(joyY);
  joyVal = map (joyVal, -1023, 1023, 0, 180);
    if (joyVal > 0);{
      
              for (int i = 180; i < 0; i--) {
              servobase.write(i);
              delay(10);
              }
         }

    if (joyVal < 0);{
              for (int i = 0; i < 180; i++) {
              servobase.write(i);
              delay(10);
              }
      
    }
  delay(15);

}

Are you expecting the servo to mimic the joysticks movements? Because this is not what you have programmed the servos to do.
All you are saying here is to sweep through a range if the joystick is above or below zero. Then do that again next time around.
Did you mean to use pins A0 and A1 for the joystick rather than pins 0 and 1?
Did you take into consideration a deadzone in the centre position of the joystick. They don’t necessarily read out perfectly centred when they are physically in the middle.
How are you powering the servos? Trying to power more than 1 servo directly using the arduino will lead to unpredictable results. Use a separate power supply to connect to the servos, and the signal wires go to the arduino. The grounds of the power supply and arduino will need to be connected together.

Put some Serial prints in so you can see what is happening. For instance:

  joyVal = analogRead(joyY);
  joyVal = map (joyVal, -1023, 1023, 0, 180);
    if (joyVal > 0);{

You can never get a negative value out of an analogRead(). So the output from the map will be roughly 90-180. Then you check to see if it is >0. It always will be.

If you can explain clearly what you are hoping it will do it should be possible to help...but I don't think that code is even close.

BTW analogRead(0) does read from analog pin A0 so that isn't one of the problems. But the program is less confusing to read if you refer to the pin as A0.

Steve