targetting arrows for mobile
This commit is contained in:
parent
8e73dcd92c
commit
af803efe4f
@ -110,8 +110,11 @@ class TargetSvg extends Component {
|
||||
? playerTeam.constructs.findIndex(c => c.id === cast.target_construct_id)
|
||||
: otherTeam.constructs.findIndex(c => c.id === cast.target_construct_id);
|
||||
|
||||
const skillNumber = window.innerWidth <= 800 // mobile styling trigger
|
||||
? playerTeam.constructs[source].skills.findIndex(s => s.skill === cast.skill)
|
||||
: 0;
|
||||
const sourceY = height;
|
||||
const sourceX = (source * width / 3) + width / 24;
|
||||
const sourceX = (source * width / 3) + width / 18 + skillNumber * (width / 9);
|
||||
const targetX = (target * width / 3) + width / 6
|
||||
+ (defensive ? width / 64 : 0)
|
||||
+ (source * width / 18);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user