enemy dropping below platform (without any bugs) is fully implemented now

This commit is contained in:
2025-01-23 01:06:16 +00:00
parent efbf0c7da9
commit e644160e38
4 changed files with 61 additions and 31 deletions

View File

@@ -187,11 +187,12 @@ struct
val platFinishX = platX + platW
val {x = eX, y = ey, yAxis = eyAxis, ...} = enemy
val ey = ey + Constants.enemySize
val standingOnPlat = standingOnArea (enemy, platformTree)
in
isBetween (platX, eX, platFinishX) andalso standingOnPlat
andalso (ey > platY andalso ey + Constants.jumpLimit >= platY)
andalso (ey > platY andalso ey >= platY)
end
fun canDrop (nextPlatform, platformTree, enemy) =