
--set_global("g_debug_start_at_wave", 15) -- Note: indices start at 1

-------------------------------------------------------------------------------

local escalate_speech_wait = 3.5

-------------------------------------------------------------------------------
-- Escalate 1 -> 2

add_wave_ping_event_wait(0)
add_wave_time_wait(escalate_speech_wait)

add_wave(function ()
  return waves_sequential(
    wait_none(),
    {
      wave_spawn(pos_gen_circle(vec(0.0, 0.0), 2.5, 8), CPP_wm_skellington_melee),
    })
end)

-------------------------------------------------------------------------------
-- Escalate 2 -> 3

add_wave_ping_event_wait(0)
add_wave_time_wait(escalate_speech_wait)

add_wave(function ()
  return waves_sequential(
    wait_time(1.0),
    {
      wave_spawn(pos_gen_circle(vec(0.0, 0.0), 2.5, 8), CPP_wm_skellington_melee),
    })
end)

add_wave(function ()
  return waves_sequential(
    wait_none(),
    {
      wave_spawn(pos_gen_circle(vec(0.0, 0.0), 3.7, 11), CPP_wm_skellington_melee),
    })
end)

-------------------------------------------------------------------------------
-- Escalate 3 -> 4

add_wave_ping_event_wait(0)
add_wave_time_wait(escalate_speech_wait)

add_wave(function ()
  return waves_sequential(
    wait_time(1.0),
    {
      wave_spawn(pos_gen_circle(vec(0.0, 0.0), 1.4, 6), CPP_wm_skellington_fire_bomber),
    })
end)

add_wave(function ()
  return waves_sequential(
    wait_time(1.0),
    {
      wave_spawn(pos_gen_circle(vec(0.0, 0.0), 2.5, 8), CPP_wm_skellington_melee),
    })
end)

add_wave(function ()
  return waves_sequential(
    wait_none(),
    {
      wave_spawn(pos_gen_circle(vec(0.0, 0.0), 3.7, 11), CPP_wm_skellington_melee),
    })
end)

-------------------------------------------------------------------------------
-- Final chase forever

--[[
add_wave_time_wait(2.0)

add_wave(function ()
  return waves_sequential(
    wait_none(), 
    { 
      wave_chase(1000, 2.5, CPP_wm_skellington_melee),
    })
end)
--]]