Added water ripple animation, removed second error message when the Compiler crashes

This commit is contained in:
Maruno17
2024-04-01 22:13:16 +01:00
parent 1ff5b12acd
commit a2af2c36f9
6 changed files with 25 additions and 4 deletions

View File

@@ -154,6 +154,18 @@ EventHandlers.add(:on_step_taken, :grass_rustling,
}
)
# Show water ripple animation
EventHandlers.add(:on_step_taken, :still_water_ripple,
proc { |event|
next if !$scene.is_a?(Scene_Map)
event.each_occupied_tile do |x, y|
next if !$map_factory.getTerrainTagFromCoords(event.map.map_id, x, y, true).shows_water_ripple
spriteset = $scene.spriteset(event.map_id)
spriteset&.addUserAnimation(Settings::WATER_RIPPLE_ANIMATION_ID, x, y, true, -1)
end
}
)
# Auto-move the player over waterfalls and ice
EventHandlers.add(:on_step_taken, :auto_move_player,
proc { |event|