Freedom Reborn Archive

Freedom Force Forums => Scripting Forum => Topic started by: seraglio on April 10, 2007, 09:57:22 AM

Title: triggering damage without breaking mezz
Post by: seraglio on April 10, 2007, 09:57:22 AM
I'm working on a custom power swap. I'm trying to emulate a fairly slow disease damage over time. I want the damage to not be visible..no big number bubble or pain animation, no breaking primary states.

Dr Mike showed in a simple line of code comparing trigger_damage(char,damage) to another way that wont break states. It was very simple. 'Corse that posts long gone and I dont seem to have it anywhere.

I think it might have innvolved just setting current health = current health - the damage you want, but I'm not sure. Dont want to do that if there is another way.

For what its worth this is ffx2.6 and at this point I dont want to factor in damage management, invulneribility should be effective. I'll figure out how to turn off regen attributes later.

Thanks.
Title: Re: triggering damage without breaking mezz
Post by: joemama on April 10, 2007, 10:55:28 AM
Do you happen to remember the topic of the post?

I copied some of Dr. Mike's tutorials when I thought I was going to teach myself scripting.....

...fortunately EZ Script came along (thank you M25), so I dropped it like a bad habit.

At any rate, I have the following posts saved:

"Event and Command Handlers" 9/30/04
"Cutscenes in FF" 9/30/04
"Scripting for Dummies" 8/10/04

I have a few others, but those are the one's specifically by Dr. Mike (perhaps the "Event and Command Handlers"?).

Let me know if these help at all and I'll post them or pm to you.

JM
Title: Re: triggering damage without breaking mezz
Post by: M25 on April 10, 2007, 01:41:36 PM
There's a function in 2.6 called FFX_ApplyDamage(char,damage,mental=0) that will probably do what you want.  It may bypass invulnerability though.  I'm not sure.

Title: Re: triggering damage without breaking mezz
Post by: Epimethee on April 10, 2007, 05:21:32 PM
> There's a function in 2.6 called FFX_ApplyDamage(char,damage,mental=0) that will probably do what you want.  It may bypass invulnerability though.
It will bypass invulnerability only if you set mental=1.
Title: Re: triggering damage without breaking mezz
Post by: seraglio on April 10, 2007, 06:18:33 PM
Thanks all FFX_ApplyDamage works. 5 hours later I almost have the rest of Pox working......