From e985c29e02708f088ab7532649f4d817dc2f506b Mon Sep 17 00:00:00 2001 From: Nyeogmi Date: Sun, 18 Dec 2022 16:50:19 -0800 Subject: [PATCH] Fix yet another rope bug --- chameleonic.p8 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/chameleonic.p8 b/chameleonic.p8 index 6ec1c96..2239968 100644 --- a/chameleonic.p8 +++ b/chameleonic.p8 @@ -1381,7 +1381,7 @@ function rope:_tug(hypothetically) for i=#ancs-1,2,-1 do local ops_before_trash=self:_calc_push(ancs[i+1],ancs[i],ancs[i-1]) - local ops_after_trash=self:_calc_push(ancs[i+1],ancs[i-1],ancs[i]) + local ops_after_trash=self:_calc_push(ancs[i-2],ancs[i-1],ancs[i]) local ops_to_do={} if #ops_before_trash>0 then ops_to_do=ops_before_trash @@ -1496,6 +1496,7 @@ function rope:_calc_push( an,a0,a1 ) local ops={} + if (an==nil) return ops if a0.x==a1.x then local y0,y1=_mnmx(a0.y,a1.y)