Fix less precise grid snapping.

master
sigonasr2 9 months ago
parent 84268e139e
commit e14ef84422
  1. 2
      TiledCollisionEditor/main.cpp

@ -106,7 +106,7 @@ public:
if(GetKey(CTRL).bHeld){
return vf2d{round(worldCoords.x),round(worldCoords.y)};
}
return vf2d{round(worldCoords.x/tileset.tilewidth)*tileset.tilewidth,round(worldCoords.y/tileset.tileheight)*tileset.tileheight};
return vf2d{round(worldCoords.x/(tileset.tilewidth/4))*tileset.tilewidth/4,round(worldCoords.y/(tileset.tileheight/4))*tileset.tileheight/4};
};
if(EditingQuad){

Loading…
Cancel
Save