Attack types and self inflicting attacks

I was curious to see if anyone knew all the “attack_type” 's for monster_attacks.

Are they hardcoded and is it possible for monsters to use an attack on themselves, as well as the effects it would cause if used on the player?

I’m trying to test out new things as far as enemy AI and attacks but the information I’ve seen so far is limited, outdated or for the basic attacks(stab, bash & cut).

Can monsters give themselves and allies buff/de-buffs?

As far as I can tell, attack_type is obsolete and “special_attacks” is used instead. “special_attacks” can be defined in JSON but there are also hard-coded special attacks.

Monsters can give themselves or each other buffs. A notorious example is the zombie master, who can upgrade other zombies.

Awesome! I have high hopes for this now.

I found the zombie master in the monsters.json and i see the “[ [ “UPGRADE”, 10 ] ],” you were referring to, going to try to find the actual Upgrade effect and see if I can take a peek at it.

Also is this line of code for attack_type the one you were referring to as obsolete?


I whipped up a basic attack for a monster to test and assumed this was the way to do it.

Either way hearing monsters can give each others buff/de-buff is very good news. Going to keep digging in the files and see what I can learn.

Aha! That’s in monster_attacks.json, which is the JSON implementation of monster special attacks. Okay, now I get it. You’re right, it’s not obsolete, just underused.

attack_type can be one of leap, melee, bite, gun (as far as I can tell). special attacks can also reference one of the hardcoded attacks listed in src/monstergenerator.cpp starting around line 340.

basic attacks can just a melee skill and damage dice number and size. You only need to implement a monster_attack for attacks that do something other than bash or cut damage.

1 Like

attack_type can be one of leap, melee, bite, gun (as far as I can tell).

yep i tested them all and gun works aswell.

special attacks can also reference one of the hardcoded attacks listed in src/monstergenerator.cpp starting around line 340.

Nice nice! I didn’t even know you could reference hardcoded attacks! I’m actually excited now. :smiley:

basic attacks can just a melee skill and damage dice number and size. You only need to implement a monster_attack for attacks that do something other than bash or cut damage.

Got it! Back to work I go!