Freedom Reborn

Freedom Force Forums => Scripting Forum => Topic started by: bearded on August 02, 2010, 05:14:02 AM

Title: direct flying melee
Post by: bearded on August 02, 2010, 05:14:02 AM
i stumbled on this by accident. i used to have a darkseid attack that did a ranged beam across the entire map and wipe out every building it hit like a deadly scythe. i can't figure out how i did that, but i was experimenting with range. i gave a direct attack the min of 0 and the max of 5, and i noticed the character approached the target and used the power right on top of it. this bug could be exploited i think.
using beyonder's hawkman i gave him a direct crushing attack in ffedit named 'melee_flight'. i used the melee_flight animation and after a bit of working with it, i renamed the hover defaults for ranged, area, and direct so they were also based on the beyonder's melee_flight animations. it ended up being a flying kick sort of thing when he is hovering. and a leap into the air when he was on the ground.
and. it works.
the range set at 0, 5 he approaches any target, in the air or on the ground. this does not seem to work for ranged attacks, he simply approaches target but never discharges the power. with direct, he hits.
isn't there a way to make a ranged or direct attack repeat just like melee? i seem to remember something.
i did a hawkman vs the vulture melee style combat totally in the air.
and then i had hawkman fly over the creeper and kick him in the head from the air.
the only downside is with direct attacks, the targets agility and dodge don't work properly. the workaround is to make a new power called 'air_defense' with the flags set to defend against direct and crushing. and then only using direct crushing attacks for the air fighters. if you make it an active defense with short duration you can even use dodge animations. it looks pretty good.
it seems like, if the target is too high, out of range that the character will approach but not discharge until they are close enough, i'm going to experiment some more to be sure of this.
this is for  :ff: .
has anyone else tried this technique?
Title: Re: direct flying melee
Post by: BentonGrey on August 02, 2010, 05:21:57 AM
VERY interesting Bearded!  I'll have to try this out for FF2.  If we could refine this a bit, you may just have stumbled on a real flying melee! :D
Title: Re: direct flying melee
Post by: TrajkLogik on August 02, 2010, 12:02:40 PM
The character will repeat the attack if the power costs no energy.

This is similar to the method of using projectile powers to simulate a flying melee with the exception that you can dodge projectiles.

I've come up with another method of adding an attribute that adds a flying melee command to a character when they fly. Using the command will trigger a custom Melee power with the Airborne Targets flag. It works well except that you have to be right next to the target and at the same height when you execute the attack or else they will land and then use the attack. I added code that will force them to fly to the target before using the power.
Title: Re: direct flying melee
Post by: bearded on August 02, 2010, 12:25:18 PM
when you say custom power, you mean python scripted?
i've tried using the beam or projectile, and it just didn't work for me the way i wanted. the target always seemed too far away for a melee blow to hit. this range bug means the attacker is right on the target, just like melee.
also, i like how i can control the formula for how often a target is hit, with the 'air defense'.
the best part is it doesn't matter if you are flying or not, if you aren't, the leaping looks right, and if you are, the kicking works on non fliers as well as fliers. and it never makes you land. unless you get knockback while flying.
i thought there was a button you press while clicking on the target to continue attacking.
Title: Re: direct flying melee
Post by: TrajkLogik on August 03, 2010, 11:39:28 AM
What I mean by custom power is a power created in FFEdit.

With the projectile, you should only use short ranged projectile and only use it when you're next to the target. You can control how close the AI is when using it by adjusting the parameters in the tactic.

The air_defense wouldn't work for me because I use Direct Crushing attacks to simulate Telekinetic punches and shoves.

Well, the whole point of flying melee is for it to be used when you're flying and not when on the ground. That's what all the other melee powers are for.

I believe if you hold the C key down while triggering a power, they will use it continually.
Title: Re: direct flying melee
Post by: bearded on August 05, 2010, 04:56:55 AM
the best part so far i realized is there is no need for any custom script so far. but with that in mind i begin to wonder about something.
the ffx swaps work by checking states, right? i wonder if it would be possible to do a direct attack, using my range bug method, and then do a swap for something, like hex or stun, swap it to a melee attack power?
how would i add new swaps to the list? the swaps are simply powers, right?
Title: Re: direct flying melee
Post by: Epimethee on August 05, 2010, 02:09:15 PM
Quote from: bearded link=topic=53423.msg723756#msg723756 date=
the best part so far i realized is there is no need for any custom script so far. but with that in mind i begin to wonder about something.
the ffx swaps work by checking states, right? i wonder if it would be possible to do a direct attack, using my range bug method, and then do a swap for something, like hex or stun, swap it to a melee attack power?
how would i add new swaps to the list? the swaps are simply powers, right?
Alas, a limitation/bug of the FF engine is that direct and area attacks do not register as game events, contrarily to melee, projectile or beam attacks. Otherwise Dr Mike wouldn't have had to add all these invisible beam fxes to simulate direct attacks for power swaps.