kopia lustrzana https://github.com/backface/turtlestitch
change metric units to cm (on request)
rodzic
10c5fa8e0f
commit
1d7c47a8b4
|
@ -63,12 +63,14 @@ TurtleShepherd.prototype.getJumpCount = function() {
|
|||
TurtleShepherd.prototype.getDimensions = function() {
|
||||
|
||||
if (this.metric) {
|
||||
c = 1;
|
||||
unit = "mm";
|
||||
//c = 1;
|
||||
//unit = "mm";
|
||||
c = 0.1
|
||||
unit = "cm";
|
||||
} else {
|
||||
c = 0.03937;
|
||||
unit = "in";
|
||||
}
|
||||
}
|
||||
w= ((this.maxX - this.minX)/5 * c).toFixed(2).toString();
|
||||
h= ((this.maxY - this.minY)/5 * c).toFixed(2).toString();
|
||||
return w + " x " + h + " " + unit;
|
||||
|
|
Ładowanie…
Reference in New Issue