Sword powerUp() ability question

I tried to use Sword of the Temple Gard powerUp() function in a working level ( Summit Gate ) and it crashed. So I tested it in https://codecombat.com/play/level/usual-day?

// code without powerUp()
hero.moveXY(60, 40);
    var enemy = hero.findNearestEnemy();
    if (enemy && hero.distanceTo(enemy)<15){
        // if (!hero.hasEffect("power-up") && hero.isReady("power-up"))
        //     hero.powerUp();

and same code without comments:

My findings for the hero health after the battle and the speed the enemies are defeated is:

      Sword        | no PowerUp | with PowerUp |  hero grows  |
   Temple Gard     |       2904 |         2227 |  with powerUp|
   Speed           |      quick |         slow |

I don’t remember the “grow effect” in previous versions of powerUp(), only the sword above the hero’s head so checked the patches

I don’t know if the Claymore, the Great Sword, the Darksteel Blade and the Simple Catana are also affected , but it’s worth checking

1 Like

Only the Temple Guard ability has a “grow” ability, however, it’s really not meant to directly buff the sword in all situations. In multiplayer arenas, the power-up ability is useful in a sense of knocking players away, however some other situations might not.

All swords above have powerUp() ability, and this is a disability if using something you get weaker.

Xython, note that every sword’s powerUp changes different stats. And you do get something stronger by having more knockback.

No, test it yourself anywhere, see the time you defeat an enemy and the health you are losing. It’s a pretty substantial nerf to the weakest type of heroes. And it crashes already done levels.

I’m saying every sword has different powerUp buffs. Some increase attack speed, some increase damage, etc.
And since it’s not a passive ability, why bother using powerUp to specifically “crash” certain levels? You have the option to not use the powerUp, if it ends up making you take more damage, etc, then you can just not use it.

Can you show an example where using this ability is more effective than simple attacking? I found quite the opposite…

@xython It’s good for medium-health swarms because you can minimalize the DPS taken by having other targets pushed away while you take on one target vs. you against a swarm around you.
With Power-Up:
Damage Taken: 660
No Power-Up:
Damage Taken: 1104

I’m almost convinced… Can you show the same situation with a free hero?
And if it works you can restore the previous powerUp() ( without the grow effect ) and rename the new ability as powerKnockBack() or something similar ( let’s follow the basic programming rule: If it ain’t broken, don’t fix it! ) And test all other swords as well…

There ya’ go @xython:
With Power-Up:
Damage Taken: 614

No Power-Up:
Damage Taken: 1116


does scatter shot count as a PowerUP

I wouldn’t say so. powerUp is a specific ability and you always use hero.powerUp() to call it. Scattershot is a bit weird though, it doesn’t have a cooldown (well, there’s a delay between each shot, but there is with attack to) so I wonder what the point of the regular attack is… Ah well it’s very cool nonetheless.

So it is a ability or something like that