It looks like you're pretty close; you just need to repeat the check for each of the buckets. You can either copy-and-paste the code as many times as you need (probably 4 in this case), but a more maintainable way would be to use a loop.
Code:
for(int i = 0; i < 4; i++)
{
// put code for a single basket here
}
--Ryan
P.S. You can use tags to inline code in your post. Look for the button with the # symbol in the post editor
__________________
FRC 2046, 2007-2008, Student member
FRC 1708, 2009-2012, College mentor; 2013-2014, Mentor
FRC 766, 2015-, Mentor