Skip to content

Commit 235b0f9

Browse files
committed
minor fix for allowing animations
1 parent d756c1d commit 235b0f9

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "DynamicalBilliards"
22
uuid = "4986ee89-4ee5-5cef-b6b8-e49ba721d7a5"
33
repo = "https://github.com/JuliaDynamics/DynamicalBilliards.jl.git"
4-
version = "3.10.2"
4+
version = "3.10.3"
55

66
[deps]
77
Distributed = "8ba89e20-285c-5b6f-9357-94700520ee1b"

src/timeevolution/propagation.jl

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,10 +44,12 @@ Check if it is on the correct side of the obstacle. If not,
4444
change the particle position by [`distance`](@ref) along the [`normalvec`](@ref)
4545
of the obstacle.
4646
"""
47-
function relocate!(p::AbstractParticle{T},
48-
o::Obstacle{T}, tmin::T, cp::SV{T}) where {T}
49-
47+
function relocate!(p::AbstractParticle{T}, o::Obstacle{T}, tmin::T, cp::SV{T}) where {T}
5048
propagate!(p, cp, tmin) # propagate to collision point
49+
okay = _correct_pos!(p, o)
50+
return okay
51+
end
52+
function _correct_pos!(p, o)
5153
d = distance(p.pos, o)
5254
okay = _okay(d, o)
5355
if !okay

0 commit comments

Comments
 (0)