I’m on Kithgard Brawl (round 6), with Javascript. When I use any code with hero.shield(); inside of a loop, it’s telling me to fix my code because it has an infinite loop. I know it has an infinite loop, but the code should still work as-is, since the loop is executing at least one command each time. The exact code I’m using is below, but the bug can be replicated with just hero.shield().
loop {
if(hero.isReady("invisibility") && hero.now() > 10) {
hero.cast("invisibility", hero);
}
hero.shield();
}
Another thing: When I use hero.shield(); inside of a loop, the health doesn’t get updated. My hero’s health is going down, but the health differences only show up about half the time. This sometimes causes the game to incorrectly give me a “SUCCESS”, but submitting my code just wastes my code turn-in for that day. I’m using the Deflector, with 3500+ health.
Please let me know if this isn’t a bug, as I’d really like to advance in this round. As of now, my hero can only survive for about 36 seconds on round 6. I can’t really work on an adequate strategy with shielding until I can get hero.shield() to work right.