diff options
Diffstat (limited to 'src/client.rs')
-rw-r--r-- | src/client.rs | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/client.rs b/src/client.rs index dc5f4a8..d24637b 100644 --- a/src/client.rs +++ b/src/client.rs @@ -476,14 +476,19 @@ fn gizmos_attack_indicator( ); gizmos.arrow_2d(position.0, dash_end, Color::YELLOW); } - DirectionalAbility::Pull(Pull { max_distance }) => { - let Some((_, pull_start, pull_end)) = pull_collision( + DirectionalAbility::Pull(Pull { max_distance, .. }) => { + let Some(PullCollision { + pull_end, + collision_position, + .. + }) = pull_collision( PlayerId(client_id.0), position.0, direction, max_distance, &player_positions, - ) else { + ) + else { let pull_direction = -max_distance * direction; let pull_start = position.0 - pull_direction; let pull_end = pull_start @@ -492,7 +497,7 @@ fn gizmos_attack_indicator( gizmos.arrow_2d(pull_start, pull_end, Color::YELLOW); return; }; - gizmos.arrow_2d(pull_start, pull_end, Color::YELLOW); + gizmos.arrow_2d(collision_position, pull_end, Color::YELLOW); } DirectionalAbility::Spear(Spear { max_distance, .. }) => { gizmos.arrow_2d( |