Pattern attraction/repulsion along curve

You didn’t internalized your base curve parameter.
See linked especially no.3.