if(manipulator->grabbing()) {
for(int k = 0; k < _nb_shapes; k++) if(_shapes[k] == manipulator->grabbing()) {
bool hit = _targets[k];
- if(hit & drand48() < 0.25) {
+ if(hit && (drand48() < 0.25)) {
manipulator->force_release();
scramble(universe);
return 1.0;
_relative_x[index[(k+1)%nb]] - _relative_x[index[m]],
_relative_y[index[(k+1)%nb]] - _relative_y[index[m]]);
- if(a1 * a2 > 0 && best_split < 0 || (abs(a1 - a2) < best_split)) {
+ if((a1 * a2 > 0 && best_split < 0) || (abs(a1 - a2) < best_split)) {
best_n = n; best_m = m;
best_split = abs(a1 - a2);
}