From 5ccdfea1848c68d57daf21e0a6b6837cd8765018 Mon Sep 17 00:00:00 2001 From: a327ex Date: Tue, 29 Jun 2021 13:27:04 -0300 Subject: [PATCH] Small bug fix --- arena.lua | 5 ++++- buy_screen.lua | 4 ++-- main.lua | 8 ++++---- todo | 2 ++ 4 files changed, 12 insertions(+), 7 deletions(-) diff --git a/arena.lua b/arena.lua index e7bed3c..f4a3eac 100644 --- a/arena.lua +++ b/arena.lua @@ -398,7 +398,9 @@ function Arena:update(dt) end self:update_game_object(dt*slow_amount) - main_song_instance.pitch = math.clamp(slow_amount*self.main_slow_amount, 0.05, 1) + if not self.slow_transitioning then + main_song_instance.pitch = math.clamp(slow_amount*self.main_slow_amount, 0.05, 1) + end star_group:update(dt*slow_amount) self.floor:update(dt*slow_amount) @@ -645,6 +647,7 @@ function Arena:quit() if not self.arena_clear_text then self.arena_clear_text = Text2{group = self.ui, x = gw/2, y = gh/2 - 48, lines = {{text = '[wavy_mid, cbyc]arena clear!', font = fat_font, alignment = 'center'}}} end self:gain_gold() self.t:after(2, function() + self.slow_transitioning = true self.t:tween(0.7, self, {main_slow_amount = 0}, math.linear, function() self.main_slow_amount = 0 end) end) self.t:after(3, function() diff --git a/buy_screen.lua b/buy_screen.lua index ae59f6a..ba200cc 100644 --- a/buy_screen.lua +++ b/buy_screen.lua @@ -163,7 +163,7 @@ function BuyScreen:on_enter(from, level, units, passives, shop_level, shop_xp) b.info_text = nil end} - trigger:tween(1, main_song_instance, {volume = 0.2}, math.linear) + trigger:tween(1, main_song_instance, {volume = 0.2, pitch = 1}, math.linear) --[[ if self.level == 1 then @@ -1439,7 +1439,7 @@ function ItemCard:update(dt) _G[random:table{'coins1', 'coins2', 'coins3'}]:play{pitch = random:float(0.95, 1.05), volume = 0.5} self.parent:gain_gold((self.level == 1 and 10) or (self.level == 2 and 20) or (self.level == 3 and 30)) table.remove(self.parent.passives, self.i) - self:die() + input.m2.pressed = false self.parent:set_items() system.save_run(self.parent.level, gold, self.parent.units, self.parent.passives, self.parent.shop_level, self.parent.shop_xp, run_passive_pool, locked_state) end diff --git a/main.lua b/main.lua index 3f4be14..35576f1 100644 --- a/main.lua +++ b/main.lua @@ -1542,8 +1542,8 @@ function init() --[[ main:add(BuyScreen'buy_screen') main:go_to('buy_screen', run.level or 1, run.units or {}, passives, run.shop_level or 1, run.shop_xp or 0) - ]]-- -- main:go_to('buy_screen', 7, run.units or {}, {'unleash'}) + ]]-- --[[ gold = 10 @@ -1555,10 +1555,10 @@ function init() 'insurance', 'dividends', 'berserking', 'unwavering_stance', 'unrelenting_stance', 'blessing', 'haste', 'divine_barrage', 'orbitism', 'psyker_orbs', 'psychosense', 'rearm', 'taunt', 'summon_instability', } main:add(Arena'arena') - main:go_to('arena', 3, { - {character = 'illusionist', level = 2}, + main:go_to('arena', 1, { + {character = 'vagrant', level = 3}, -- {character = 'carver', level = 2}, - {character = 'engineer', level = 2}, + {character = 'dual_gunner', level = 3}, -- {character = 'saboteur', level = 2}, -- {character = 'hunter', level = 2}, }, { diff --git a/todo b/todo index 528723e..5da94e8 100644 --- a/todo +++ b/todo @@ -17,6 +17,8 @@ Loop Update Warping Shots - X/Y/Z% chance for projectiles to ignore wall collisions and warp around the screen 1/2/3 times Culling Strike - instantly kill elites below 10/20/30% max HP Lightning Strike - X/Y/Z% chance for attacks to create chain lightning, dealing 60/80/100% damage and hitting 2/3/4 enemies + Psycholeak - Position X generates 1 additional orb every Y seconds + Divine Blessing - generate 1 healing orb every X seconds Psyker Additional orbs will prefer to be assigned to psykers, if there are no psykers then they will be assigned randomly Orb speed scales with the unit's attack speed