Sets modifiers at coordinates.
void setModifiers(int x, int y, int mod) { if (isCellValid(x, y)) { attributes[(y * width + x) * 3 + 2] = mod; } }