fixed final bugs in gridsystem