From d44ac242e19ee23adb9d5028c9ba59ad859b4fd8 Mon Sep 17 00:00:00 2001 From: Koichi KAMICHI Date: Wed, 30 Dec 2009 05:43:09 +0000 Subject: [PATCH] Fixed bugs. --- engine/kage.js | 4 ++-- engine/kagecd.js | 6 +++--- engine/kagedf.js | 6 +++--- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/engine/kage.js b/engine/kage.js index 0f7bb66..addfc55 100755 --- a/engine/kage.js +++ b/engine/kage.js @@ -100,8 +100,8 @@ function Kage(size){ !(strokesArray[i][4] + 1 > strokesArray[j][6] || strokesArray[i][6] - 1 < strokesArray[j][4]) && Math.abs(strokesArray[i][3] - strokesArray[j][3]) < this.kMinWidthT * 4){ strokesArray[i][1] += (4 - Math.floor(Math.abs(strokesArray[i][3] - strokesArray[j][3]) / this.kMinWidthT)) * 100; - if(strokesArray[i][1] > this.kAdjustTateStep * 100){ - strokesArray[i][1] = strokesArray[i][1] % 100 + this.kAdjustTateStep * 100; + if(strokesArray[i][1] > this.kAdjustTateStep * 1000){ + strokesArray[i][1] = strokesArray[i][1] % 1000 + this.kAdjustTateStep * 1000; } } } diff --git a/engine/kagecd.js b/engine/kagecd.js index d37f823..b867f57 100755 --- a/engine/kagecd.js +++ b/engine/kagecd.js @@ -12,11 +12,11 @@ function cdDrawCurveU(kage, polygons, x1, y1, sx1, sy1, sx2, sy2, x2, y2, ta1, t var a1, a2, opt1, opt2, opt3; if(kage.kShotai == kage.kMincho){ // mincho - a1 = ta1 % 100; + a1 = ta1 % 1000; a2 = ta2 % 100; - opt1 = Math.floor((ta1 % 1000) / 100); + opt1 = Math.floor((ta1 % 10000) / 1000); opt2 = Math.floor(ta2 / 100); - opt3 = Math.floor(ta1 / 1000); + opt3 = Math.floor(ta1 / 10000); kMinWidthT = kage.kMinWidthT - opt1 / 2; kMinWidthT2 = kage.kMinWidthT - opt3 / 2; diff --git a/engine/kagedf.js b/engine/kagedf.js index 18c86bb..3a8578a 100755 --- a/engine/kagedf.js +++ b/engine/kagedf.js @@ -96,7 +96,7 @@ function dfDrawFont(kage, polygons, a1, a2, a3, x1, y1, x2, y2, x3, y3, x4, y4){ ty3 = y3; cdDrawLine(kage, polygons, x1, y1, tx1, ty1, a2, 1); - cdDrawCurve(kage, polygons, tx1, ty1, x2, y2, tx2, ty2, 1 + (a2 - a2 % 100) * 10, 1); + cdDrawCurve(kage, polygons, tx1, ty1, x2, y2, tx2, ty2, 1 + (a2 - a2 % 1000) * 10, 1); if(tx3 - tx2 > 0){ // for closer position cdDrawLine(kage, polygons, tx2, ty2, tx3, ty3, 6, 5); // bolder by force } @@ -135,7 +135,7 @@ function dfDrawFont(kage, polygons, a1, a2, a3, x1, y1, x2, y2, x3, y3, x4, y4){ ty2 = y2 + kage.kMage * Math.sin(rad) * v; } cdDrawLine(kage, polygons, x1, y1, tx1, ty1, a2, 1); - cdDrawCurve(kage, polygons, tx1, ty1, x2, y2, tx2, ty2, 1 + (a2 - a2 % 100) * 10, 1); + cdDrawCurve(kage, polygons, tx1, ty1, x2, y2, tx2, ty2, 1 + (a2 - a2 % 1000) * 10, 1); cdDrawLine(kage, polygons, tx2, ty2, x3, y3, 6, a3); // bolder by force } break; @@ -256,7 +256,7 @@ function dfDrawFont(kage, polygons, a1, a2, a3, x1, y1, x2, y2, x3, y3, x4, y4){ break; case 7: cdDrawLine(kage, polygons, x1, y1, x2, y2, a2, 1); - cdDrawCurve(kage, polygons, x2, y2, x3, y3, x4, y4, 1 + (a2 - a2 % 100), a3); + cdDrawCurve(kage, polygons, x2, y2, x3, y3, x4, y4, 1 + (a2 - a2 % 1000), a3); break; case 9: // may not be exist ... no need //kageCanvas[y1][x1] = 0; -- 1.7.10.4