Characters Ignoring Another Character's Attributes

Started by spydermann93, July 22, 2015, 10:16:26 PM

Previous topic - Next topic

spydermann93

Is there a way to make it so that a character with attribute X ignores the bonuses of another character with attribute X while other characters without attribute X still have to deal with the attribute?

For example, say attribute X is called "Super Reflexes".  This attribute gives a character +5 agility.  Now, say another character has Super Reflexes.  Is it possible to make it so that these two characters ignore each other's Super Reflexes?  That way, if three characters were in a fight, two on team A and one on team B, the two speedsters could ignore each other's attributes and fight "normally" while the third character still has to contend with the +5 agility.

hoss20

If you have the FFX Manual, click on M25 AI on the left side menu. Then click on AI Tactics Doc that drops down underneath it. All of the contents here are helpful, but you will specifically want Subtype/Situation Rules. This will instruct you on how to accomplish what you are trying to do. It looks like you will have to add super_reflexes as a subtype and then have your AI reference this.

spydermann93

I don't think that will solve the issue.

What I'm talking about is something like this:

Characters A and B have super reflexes and a base agility of 5.  With super reflexes, they have a modified agility of 10.

Character C does not have super reflexes.

When Character A attacks B, Character B has an agility of 5 for dodging A.  When C attacks B, B has an agility of 10 for dodging C.

Something like that.

hoss20

Sorry. This is what happens when I skim over things at too late an hour. I was trying to look at other attributes like Vulnerability or Parasite, but the customizations for these don't have Agility as a choice to have affected. What you're looking for may need some additional scripting.

Epimethee

Since this involves attacks missing which you want to hit, the first way I can think of is using mlogreader's damage detection (which might need some debugging IIRC). The second—again IIRC—, would involve increasing the game's default hit chance value and increasing the third character's agility to compensate.

Either way, you'll need to write a fair bit of code.
FFX add-on for FFvsTTR at ffx.freedomforceforever.com

stumpy

#5
If the two toons fight one another alone, then this should be doable with one of the contingency attributes that change a character depending on his surroundings. I am thinking that Vulnerability might do the job. You'd want to open ffx.py and write a new custom detrimental effect like loseAgilityAndSpeed to reduce agility and speed, but that would be fairly straightforward if you use the loseStrength function that's already in ffx.py as a template. Then, open ffxdefaults.py and add a line like ["loseAgilityAndSpeed"], (with your new function name) to the FFX_PENALTIES list.

A problem occurs when they are fighting one another when others are around, since their agilities and speeds would be lowered to normal for purposes of attacks from those other characters, as well. I don't know of a practical way for only the speedsters to ignore each others' exceptional abilities.

Out of curiosity, what is the problem you are seeing with two high-agility characters fighting? Do they never hit each other? Ultimately, that shouldn't really be happening if the Super Reflexes doesn't take the toon outside the normal range of character abilities the for which the game's combat has been balanced. Outside that range, two characters with over-the-top abilities might go for a long time and never be able to hit one another because the game's combat mechanics aren't designed with those abilities in mind. But, if neither has abilities that are over 10 (that's 9 in the scripts, since they start at zero there), then they should be hard, but not completely impossible to hit by other characters, at least if the other character have melee powers with high attack speeds.
Courage is knowing it might hurt, and doing it anyway. Stupidity is the same. And that's why life is hard. - Jeremy Goldberg

spydermann93

Quote from: stumpy on July 26, 2015, 06:21:05 PMOut of curiosity, what is the problem you are seeing with two high-agility characters fighting? Do they never hit each other? Ultimately, that shouldn't really be happening if the Super Reflexes doesn't take the toon outside the normal range of character abilities the for which the game's combat has been balanced. Outside that range, two characters with over-the-top abilities might go for a long time and never be able to hit one another because the game's combat mechanics aren't designed with those abilities in mind. But, if neither has abilities that are over 10 (that's 9 in the scripts, since they start at zero there), then they should be hard, but not completely impossible to hit by other characters, at least if the other character have melee powers with high attack speeds.

That's exactly what's happening.  Super Reflexes + 10 Agility is one more than a character with 10 Agility, Nimble, and Danger Sense, so I didn't think it would be too bad.  The main idea that I'm trying to replicate is having super-speedsters dodge "slower" characters rather easily while other super-speedsters are treated normally.  Kind of two tiers of melee combat rather than one overarching tier.

Another attribute that I was thinking of is increasing the Swiftness of a character's melee attacks.  Is that possible?

stumpy

Increasing the swiftness of melee attacks will reduce the chance that a highly agile character will dodge the attack. But, the game isn't designed to deal with characters whose overall agility is so much higher than 10. So, there is no certainty that even a very fast melee attack (and with any attributes that add to that) will be able to hit a toon whose agility is effectively 15. By going past 10 with abilities, which is something the scripting system unintentionally lets us do, you may have left the realm where there is an effective melee attack, which is something we cannot improve by scripting.

BTW, my take on the broader issue of running into game limits when trying to create characters that realistically recreate the powers of some comic book superheroes (or supervillians) is that many of those superheroes can't really be done. And, it's not because the game is doing something wrong so much as because the comic book characters are unrealistic to such an extreme degree. Imagine a character like the Flash dodging a bullet. If he knows the bullet is coming and he isn't immobilized, the bullet should never hit him. Not one out of 10 times, not one out of 10,000 times. From his perspective, the rest of the world is moving in super- ultra- slow-motion; it's basically still. A bullet can't hit him any more than a tree stump can hit one of us. Because of simple momentum, any bullet accelerated to a significant fraction of his speed would basically cripple the person who held the gun that fired it.

But, games can't realistically allow that kind of speed. It essentially becomes a WIN button. That's why we start running into problems when we take characters outside of the game's accepted range of abilities. We come to a point where the game doesn't have a melee attack that represents a punch thrown so fast that it could hit someone with XX (15 or whatever) agility.
Courage is knowing it might hurt, and doing it anyway. Stupidity is the same. And that's why life is hard. - Jeremy Goldberg