Minor fix for mirrored anchor rotations

This commit is contained in:
Bán Dénes 2021-11-27 21:03:50 +01:00
parent a593f61111
commit 0ec16dbaf6

View file

@ -55,7 +55,11 @@ const anchor = exports.parse = (raw, name, points={}, check_unexpected=true, def
point.shift(xyval, true)
}
if (raw.rotate !== undefined) {
point.r += a.sane(raw.rotate, `${name}.rotate`, 'number')(units)
let angle = a.sane(raw.rotate, `${name}.rotate`, 'number')(units)
if (point.meta.mirrored) {
angle = -angle
}
point.r += angle
}
if (raw.affect !== undefined) {
const candidate = point