| | |
| | | POINT: 2, |
| | | }) |
| | | |
| | | export const DEVICE_SELECTED_EFFECT_PADDING = Object.freeze({ |
| | | SHELF: 10, |
| | | STATION: 10, |
| | | CHARGE: 10, |
| | | DIRECTION: 10, |
| | | |
| | | AGV: 10, |
| | | POINT: 100, |
| | | }) |
| | | |
| | | export const AGV_STATUS_MODE = Object.freeze({ |
| | | EMPTY_NO_BATTERY: 1, |
| | | EMPTY_HALF_BATTERY: 2, |
| | |
| | | DEVICE_TYPE, |
| | | DEVICE_Z_INDEX, |
| | | AGV_STATUS_MODE, |
| | | DEVICE_SELECTED_EFFECT_PADDING, |
| | | } from './constants'; |
| | | |
| | | import shelf from '/map/shelf.svg'; |
| | |
| | | break; |
| | | } |
| | | if (sprite && deviceType !== DEVICE_TYPE.AGV) { |
| | | sprite.blendMode = PIXI.BLEND_MODES.MULTIPLY; |
| | | // sprite.blendMode = PIXI.BLEND_MODES.MULTIPLY; |
| | | } |
| | | return sprite; |
| | | } |
| | |
| | | |
| | | const { width, height } = sprite; |
| | | const maxDimension = Math.max(width, height); |
| | | const radius = (maxDimension / 2) + maxDimension / 5; |
| | | const radius = (maxDimension / 2) + (DEVICE_SELECTED_EFFECT_PADDING[sprite.data?.type] || 10); |
| | | |
| | | const color = themeMode === 'light' ? 0x2f68ac : 0xffffff; |
| | | const alpha = .5; |
| | | const color = themeMode === 'light' ? '#40739e' : '#718093'; |
| | | const alpha = 1; |
| | | |
| | | effectCircle = new PIXI.Graphics(); |
| | | effectCircle.beginFill(color, alpha); |