private int getBitmask()
{
int bitmask = 0;
bitmask += getBitmask(x , y , S);
bitmask += getBitmask(x , y+1, W);
bitmask += getBitmask(x+1, y , D);
bitmask += getBitmask(x-1, y , A);
bitmask += getBitmask(x+1, y+1, E);
bitmask += getBitmask(x-1, y+1, Q);
return bitmask;
}