Merge branch 'vbox-layout' into new-vbox-combiner

This commit is contained in:
Mashy
2019-11-24 15:50:26 +10:00
3 changed files with 18 additions and 7 deletions
+4 -1
View File
@@ -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);