Motor Trouble

Hello, I have six motors hooked up to one button on the remote. For some reason the motors are only working part of the time. This is when there is no pressure or resistance on the motors either. Any feedback is great, thank you.

Post the code?

task main()
{
while(true)

if(vexRT[Btn6U]== 1)
{
	motor[middleliftleft] = -127;
}
else if (vexRT[Btn6D] == 1)
{
	motor[middleliftleft] = 127;
}
else
{
	motor[middleliftleft] = 0;




	if(vexRT[Btn6U]== 1)
	{
		motor[middleliftright] = -127;
	}
	else if (vexRT[Btn6D]==1)
	{
		motor[middleliftright] = 127;
	}
	else
	{
		motor[middleliftright] = 0;



		if(vexRT[Btn6U] == 1)
		{
			motor[rightlift] = -127;
		}
		else if (vexRT[Btn6D] == 1)
		{
			motor[rightlift] = 127;
		}
		else
		{
			motor[rightlift] = 0;





			if(vexRT[Btn6U]== 1)
			{
				motor[leftlift] = -127;
			}
			else if (vexRT[Btn6D]==1)
			{
				motor[leftlift] = 127;
			}
			else
			{
				motor[leftlift] = 0;




				if(vexRT[Btn6U]== 1)
				{
					motor[toprightlift] = -127;
				}
				else if (vexRT[Btn6U]==1)
				{
					motor[toprightlift] = 127;
				}
				else
				{
					motor[toprightlift] = 0;




					if(vexRT[Btn6U]== 1)
					{
						motor[topleftlift] = -127;
					}
					else if (vexRT[Btn6U]==1)
					{
						motor[topleftlift] = 127;
					}
					else
					{
						motor[topleftlift] = 0;


					}
				}
			}

		}
	}
}

}

You don’t have to write out separate statements for each motor. You can bunch all of them into one big if-else statement. It’d go something like this:

If {
motor 1 = 127
motor 2 = 127

} else {
motor 1 = 0
motor 2 = 0

}