Skip to content

Commit

Permalink
set default r_cm in BodyShape
Browse files Browse the repository at this point in the history
  • Loading branch information
baggepinnen committed Oct 26, 2023
1 parent 158df26 commit 4ddff0e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components.jl
Original file line number Diff line number Diff line change
Expand Up @@ -281,10 +281,10 @@ The `BodyShape` component is similar to a [`Body`](@ref), but it has two frames
- `r`: Vector from `frame_a` to `frame_b` resolved in `frame_a`
- All `kwargs` are passed to the internal `Body` component.
"""
@component function BodyShape(; name, m = 1, r = [0, 0, 0], r_0 = 0, radius = 0.08, kwargs...)
@component function BodyShape(; name, m = 1, r = [0, 0, 0], r_cm = 0.5*r, r_0 = 0, radius = 0.08, kwargs...)
systems = @named begin
frameTranslation = FixedTranslation(r = r)
body = Body(; kwargs...)
body = Body(; r_cm, kwargs...)
frame_a = Frame()
frame_b = Frame()
end
Expand Down

0 comments on commit 4ddff0e

Please sign in to comment.