index : btroops | |
Virtual board game-aid for BattleTroops, an infantry combat simulator wargame published by FASA in 1989. |
aboutsummaryrefslogtreecommitdiff |
diff options
author | Catalin Mititiuc <webdevcat@proton.me> | 2024-04-23 21:14:30 -0700 |
---|---|---|
committer | Catalin Mititiuc <webdevcat@proton.me> | 2024-04-23 21:14:30 -0700 |
commit | 96e6f8a09afaf7bc729b7e14eb0d72dd372ca9fd (patch) | |
tree | 2e916cb653ec260905e5773aaf056f6c8a9cfb8f /src/modules/sightLine.js | |
parent | f60969ef8dc72d3b97c5abb9f637171d2a6f2921 (diff) |
WIP: sight line and trace working again
Diffstat (limited to 'src/modules/sightLine.js')
-rw-r--r-- | src/modules/sightLine.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/modules/sightLine.js b/src/modules/sightLine.js index de88521..4790bd8 100644 --- a/src/modules/sightLine.js +++ b/src/modules/sightLine.js @@ -170,8 +170,8 @@ export default class SightLine { update(cell, { x, y }) { const sl = this.svg.querySelector('.sight-line'), target = this.svg.querySelector('.sight-line-target').parentElement, - x1 = cell.parentElement.dataset.x, - y1 = cell.parentElement.parentElement.dataset.y, + x1 = cell.dataset.x, + y1 = cell.parentElement.dataset.y, x2 = target.dataset.x, y2 = target.parentElement.dataset.y; |