PDA

View Full Version : Horny and the slow spell



Hades
February 1st, 2013, 17:06
When the :horny: is level 10, the get slow, yet they don't cast it in battle outside of possession. When I replaced the slow with Freeze, they uses it just fine.

Why is this?

Metal Gear Rex
February 1st, 2013, 20:46
When the :horny: is level 10, the get slow, yet they don't cast it in battle outside of possession. When I replaced the slow with Freeze, they uses it just fine.

Why is this?

It has nothing to do with the Creature, but rather the Spell itself. The Slow Spell is bugged. It doesn't fire unless the creature has some other projectile spell to fire, like Missile. The Monk, for instance, won't use Slow when he gets it at Level 3, until he gets Missile at Level 4. It's probably just some flaw in the coding or something.

mefistotelis
February 1st, 2013, 21:46
Slow is identified only as a "ranged_offensive_weapon" while Freeze is also "melee_offensive_weapon". Your creature probably prefers melee combat, so it will only switch to ranged weapons when no melee weapon is available.

The arrays responsible for weapon selection are defined in creature_states_combt.c.

Maybe Slow should exist in both arrays, like fart?

Hades
February 2nd, 2013, 01:50
Slow is identified only as a "ranged_offensive_weapon" while Freeze is also "melee_offensive_weapon". Your creature probably prefers melee combat, so it will only switch to ranged weapons when no melee weapon is available.

The arrays responsible for weapon selection are defined in creature_states_combt.c.

Maybe Slow should exist in both arrays, like fart?

Yet, the :samurai: and the :monk: prefer close quarters and use ranged spells like lightning and drain.

DragonsLover
February 2nd, 2013, 04:37
It doesn't matter if the creature has melee or ranged attack preference. Vampires, ranged attackers, won't shoot their Slow spell until they get the drain spell. Similarly, Spiders, melee attackers, won't shoot their Slow spell until they get the freeze spell. Slow should work the exact same way as freeze and shouldn't require another ranged attack in order to trigger. If you can find the bug, I'd get rid of the Missile spell for the horny.

mefistotelis
February 2nd, 2013, 08:22
If you can find the bug, I'd get rid of the Missile spell for the horny.
I think I can. Will do that in next commit. But that needs testing.