Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Mewdoom

zdoom - how to use MeleeThreshold with Melee attack ?

Recommended Posts

Hello guys,

it is possible to use MeleeThreshold to make the monster use its missile attack from a minimum range and also use is melee attack if he is under that range ?

the monster just try to keep get close to the player instead of use his melee attack, once he is close he use his melee attack ..

In fact, I would like to have two missile attack, one for range from 0 to 100 and the second one from, 100+ range.

Share this post


Link to post
Mewdoom said:

make the monster use its missile attack from a minimum range and also use is melee attack if he is under that range ?

the monster just try to keep get close to the player instead of use his melee attack, once he is close he use his melee attack ..

This is what monsters already normally do, and the particular range is defined by MeleeRange property. MeleeThreshold isn't needed at all.

Mewdoom said:

In fact, I would like to have two missile attack, one for range from 0 to 100 and the second one from, 100+ range.

Let it have one missile attack, and call A_JumpIfCloser in its first state to branch the attack logic depending on distance.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×