feat:提交
This commit is contained in:
38
tests/dev1/dataHandle/common/BlockBorderPoint.ts
Normal file
38
tests/dev1/dataHandle/common/BlockBorderPoint.ts
Normal file
@@ -0,0 +1,38 @@
|
||||
import type { PlaceBlock } from "../confClass"
|
||||
|
||||
/** 拖拉的小板顶点 */
|
||||
export class BlockBorderPoint
|
||||
{
|
||||
/** 板 */
|
||||
block: PlaceBlock
|
||||
/** 原坐标x */
|
||||
x: number
|
||||
/** 原坐标y */
|
||||
y: number
|
||||
/** 大板坐标X */
|
||||
placeX: number
|
||||
/** 大板坐标Y */
|
||||
placeY: number
|
||||
|
||||
/** 拖拉点距切割后板的坐标偏移x */
|
||||
bx = 0
|
||||
/** 拖拉点距切割后板的坐标偏移x */
|
||||
by = 0
|
||||
/** 在placed线框中的序号 */
|
||||
curveIndex: number
|
||||
/** 在板的位置: 10:基点(左下点);1:右下角;2:右上角;3:左上角; -1:表示异形非顶点 areaID */
|
||||
posId: number
|
||||
|
||||
constructor(block: PlaceBlock, x: number, y: number, index: number, posId: number, bx = 0, by = 0)
|
||||
{
|
||||
this.block = block
|
||||
this.x = x
|
||||
this.y = y
|
||||
this.placeX = (block ? block.placeX : 0) + x
|
||||
this.placeY = (block ? block.placeY : 0) + y
|
||||
this.curveIndex = index
|
||||
this.posId = posId
|
||||
this.bx = bx
|
||||
this.by = by
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user