mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-08 13:44:59 +00:00
Fixed error in Powder's backfire message, fixed move disruption affecting recharge moves when it shouldn't, fixed error when Shell Side Arm has no targets, fixed AI not unregistering Mega Evolution if it won't do so after all
This commit is contained in:
@@ -271,7 +271,6 @@ module RPG
|
||||
|
||||
def update_sprite_position(sprite, index, is_new_sprite = false)
|
||||
return if !sprite || !sprite.bitmap || !sprite.visible
|
||||
# TODO: FPS.
|
||||
delta_t = Graphics.delta
|
||||
lifetimes = (is_new_sprite) ? @new_sprite_lifetimes : @sprite_lifetimes
|
||||
if lifetimes[index] >= 0
|
||||
@@ -287,7 +286,6 @@ module RPG
|
||||
if @weatherTypes[weather_type][0].category == :Rain && index.odd? # Splash
|
||||
sprite.opacity = (lifetimes[index] < 0.2) ? 255 : 0 # 0.2 seconds
|
||||
else
|
||||
# TODO: FPS.
|
||||
dist_x = @weatherTypes[weather_type][0].particle_delta_x * delta_t
|
||||
dist_y = @weatherTypes[weather_type][0].particle_delta_y * delta_t
|
||||
sprite.x += dist_x
|
||||
@@ -301,7 +299,6 @@ module RPG
|
||||
sprite.x += Graphics.width if sprite.x - @ox < -sprite.width
|
||||
sprite.y -= Graphics.height if sprite.y - @oy > Graphics.height
|
||||
sprite.y += Graphics.height if sprite.y - @oy < -sprite.height
|
||||
# TODO: FPS.
|
||||
sprite.opacity += @weatherTypes[weather_type][0].particle_delta_opacity * delta_t
|
||||
x = sprite.x - @ox
|
||||
y = sprite.y - @oy
|
||||
@@ -313,13 +310,11 @@ module RPG
|
||||
end
|
||||
|
||||
def recalculate_tile_positions
|
||||
# TODO: FPS.
|
||||
delta_t = Graphics.delta
|
||||
weather_type = @type
|
||||
if @fading && @fade_time >= [FADE_OLD_TONE_END - @time_shift, 0].max
|
||||
weather_type = @target_type
|
||||
end
|
||||
# TODO: FPS.
|
||||
@tile_x += @weatherTypes[weather_type][0].tile_delta_x * delta_t
|
||||
@tile_y += @weatherTypes[weather_type][0].tile_delta_y * delta_t
|
||||
while @tile_x < @ox - @weatherTypes[weather_type][2][0].width
|
||||
@@ -416,7 +411,6 @@ module RPG
|
||||
@sun_magnitude = weather_max if @sun_magnitude != weather_max && @sun_magnitude != -weather_max
|
||||
@sun_magnitude *= -1 if (@sun_magnitude > 0 && @sun_strength > @sun_magnitude) ||
|
||||
(@sun_magnitude < 0 && @sun_strength < 0)
|
||||
# TODO: FPS.
|
||||
@sun_strength += @sun_magnitude.to_f * Graphics.delta / 0.4 # 0.4 seconds per half flash
|
||||
tone_red += @sun_strength
|
||||
tone_green += @sun_strength
|
||||
@@ -430,7 +424,6 @@ module RPG
|
||||
def update_fading
|
||||
return if !@fading
|
||||
old_fade_time = @fade_time
|
||||
# TODO: FPS.
|
||||
@fade_time += Graphics.delta
|
||||
# Change tile bitmaps
|
||||
if @type != @target_type
|
||||
@@ -489,7 +482,6 @@ module RPG
|
||||
update_screen_tone
|
||||
# Storm flashes
|
||||
if @type == :Storm && !@fading
|
||||
# TODO: FPS.
|
||||
if @time_until_flash > 0
|
||||
@time_until_flash -= Graphics.delta
|
||||
if @time_until_flash <= 0
|
||||
|
||||
Reference in New Issue
Block a user