Skip to content

Commit 36b3ec5

Browse files
committed
Cleanup for Animated Jumpthru Ahorn plugin
1 parent a7bc4dd commit 36b3ec5

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

Ahorn/entities/animatedJumpthruPlatform.jl

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -28,18 +28,13 @@ end
2828

2929

3030
function Ahorn.render(ctx::Ahorn.Cairo.CairoContext, entity::AnimatedJumpthruPlatform, room::Maple.Room)
31-
texture = get(entity.data, "animationPath", "wood")
31+
texture = get(entity.data, "animationPath", "SpringCollab2020Example/rainbowwood")
3232

3333
# Values need to be system specific integer
3434
x = Int(get(entity.data, "x", 0))
35-
3635
width = Int(get(entity.data, "width", 8))
3736

38-
startX = div(x, 8) + 1
39-
stopX = startX + div(width, 8) - 1
40-
41-
len = stopX - startX
42-
for i in 0:len
37+
for i in 0:div(width, 8)-1
4338
Ahorn.drawImage(ctx, "objects/jumpthru/$(texture)00", 8 * i, 0)
4439
end
4540
end

0 commit comments

Comments
 (0)