# This test case helps identify performance problems on a level full of
# wandering monsters and possibly clouds. Works best on sprint maps.
#
# Wizmode is needed.

name = CPU_hog
species = mu
background = ar
restart_after_game = false
show_more = false

: bot_start = true
: function ready()
:   local esc = string.char(27)
:   local eol = string.char(13)
:   if you.turns() == 0 and bot_start then
:     bot_start = false
:     crawl.enable_more(false)
:     crawl.set_sendkeys_errors(true)
:     crawl.process_keys("&Y" .. esc)
:     crawl.call_dlua("crawl_require('dlua/stress.lua');" ..
:                     "stress.entomb();" ..
:                     "stress.awaken_level()")
:     crawl.sendkeys("5")
:   elseif you.turns() < 1000 then
:     crawl.sendkeys("5")
:   else
:     crawl.sendkeys("*qyes" .. eol .. esc .. esc)
:   end
: end
