|
|
@ -104,7 +104,7 @@ export class BoardMoveTool
|
|
|
|
if (obj.visible)
|
|
|
|
if (obj.visible)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
i++;
|
|
|
|
i++;
|
|
|
|
if (i > 50)
|
|
|
|
if (i > 30)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
let now = performance.now();
|
|
|
|
let now = performance.now();
|
|
|
|
let r = now - start;
|
|
|
|
let r = now - start;
|
|
|
@ -140,6 +140,7 @@ export class BoardMoveTool
|
|
|
|
derv.applyMatrix4(brRot);
|
|
|
|
derv.applyMatrix4(brRot);
|
|
|
|
p.setZ(br.Thickness * 0.5);
|
|
|
|
p.setZ(br.Thickness * 0.5);
|
|
|
|
p.applyMatrix4(brOCS);
|
|
|
|
p.applyMatrix4(brOCS);
|
|
|
|
|
|
|
|
await Sleep(1);
|
|
|
|
let intersection = this.RayPoint(p, derv, brsObject);
|
|
|
|
let intersection = this.RayPoint(p, derv, brsObject);
|
|
|
|
|
|
|
|
|
|
|
|
if (intersection)
|
|
|
|
if (intersection)
|
|
|
@ -173,6 +174,7 @@ export class BoardMoveTool
|
|
|
|
{
|
|
|
|
{
|
|
|
|
let p = new Vector3(br.Width * 0.5, br.Height * y, br.Thickness).applyMatrix4(brOCS);
|
|
|
|
let p = new Vector3(br.Width * 0.5, br.Height * y, br.Thickness).applyMatrix4(brOCS);
|
|
|
|
centerP = centerP ?? p;
|
|
|
|
centerP = centerP ?? p;
|
|
|
|
|
|
|
|
await Sleep(1);
|
|
|
|
let intersection = this.RayPoint(p, brNormal, brsObject);
|
|
|
|
let intersection = this.RayPoint(p, brNormal, brsObject);
|
|
|
|
if (intersection)
|
|
|
|
if (intersection)
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -202,6 +204,7 @@ export class BoardMoveTool
|
|
|
|
{
|
|
|
|
{
|
|
|
|
let p = new Vector3(br.Width * 0.5, br.Height * y, 0).applyMatrix4(brOCS);
|
|
|
|
let p = new Vector3(br.Width * 0.5, br.Height * y, 0).applyMatrix4(brOCS);
|
|
|
|
centerP = centerP ?? p;
|
|
|
|
centerP = centerP ?? p;
|
|
|
|
|
|
|
|
await Sleep(1);
|
|
|
|
let intersection = this.RayPoint(p, brNormal2, brsObject);
|
|
|
|
let intersection = this.RayPoint(p, brNormal2, brsObject);
|
|
|
|
if (intersection)
|
|
|
|
if (intersection)
|
|
|
|
{
|
|
|
|
{
|
|
|
|