Skip to content

Commit

Permalink
[#72] Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Orchaldir committed Sep 20, 2023
1 parent 63af208 commit 8c75018
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions rpg_tools_rendering/src/rendering/equipment/shirt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,12 @@ fn render_sleeves(

fn add_neckline(aabb: &AABB, torso: &TorsoConfig, shirt: &Shirt, builder: &mut Polygon2dBuilder) {
match shirt.neckline {
Neckline::Boat => add_round(&aabb, torso, builder, 0.7, 0.05),
Neckline::Crew => add_round(&aabb, torso, builder, 0.3, 0.1),
Neckline::DeepV => add_v(&aabb, torso, builder, 0.4),
Neckline::None => add_straight(&aabb, torso, builder),
Neckline::Scoop => add_round(&aabb, torso, builder, 0.5, 0.2),
Neckline::V => add_v(&aabb, torso, builder, 0.2),
Neckline::Boat => add_round(aabb, torso, builder, 0.7, 0.05),
Neckline::Crew => add_round(aabb, torso, builder, 0.3, 0.1),
Neckline::DeepV => add_v(aabb, torso, builder, 0.4),
Neckline::None => add_straight(aabb, torso, builder),
Neckline::Scoop => add_round(aabb, torso, builder, 0.5, 0.2),
Neckline::V => add_v(aabb, torso, builder, 0.2),
}
}

Expand All @@ -87,8 +87,7 @@ fn add_round(
}

fn add_v(aabb: &AABB, torso: &TorsoConfig, builder: &mut Polygon2dBuilder, depth: f32) {
let width = torso.shoulder_width / 3.0;
builder.add_mirrored_points(aabb, width, 0.0, true);
add_straight(aabb, torso, builder);
builder.add_point(aabb.get_point(0.5, depth), true);
}

Expand Down

0 comments on commit 8c75018

Please sign in to comment.