Is this a glitch?

i am doing backwoods brawl and this message keeps popping up

loop:
    enemy = self.findNearestEnemy()
    self.shield()
    if self.isReady("cleave"):
        self.cleave(enemy)
    if self.isReady("chain-lightning"):
        self.cast("chain-lightning", enemy)

but this works perfectly fine in the cavern
i equipped the same gear and things and it does not work i copy and pasted the copde

also i get less gems and xp than i used to for the brawls every time i go up

What message keeps popping up?

cast’s argument target should have type object, but got null, You need something to cast upon

Are you sure that an enemy exist?

1 Like

yup they always exist and it works fine in the cavern brawl

Looks like not. Maybe your hero don’t see an enemy (obstacles, distance). It’s a good practice always check the existance before do something.

1 Like