Note: LucasForums Archive Project
The content here was reconstructed by scraping the Wayback Machine in an effort to restore some of what was lost when LF went down. The LucasForums Archive Project claims no ownership over the content or assets that were archived on archive.org.

This project is meant for research purposes only.

How do I edit Force Drain?

Page: 1 of 1
 Tararara
09-23-2004, 3:38 PM
#1
I've never ventured into JA coding beyond doodling with NPC files, but I would really like to change Force Drain in MP.

I have fond memories of draining Stormtroopers in SP, but in MP Drain is absolutly useless, draining only Force manna. I want to make it drain health, but I don't have the faintest clue where to start. Can someone help me?
 Tinny
09-23-2004, 5:57 PM
#2
hmm, try taking a look insde w_force.c at these 2 functions. forcedrain and forceshootdrain, those might help, and try look at the forcelightning and forceshootlightning code too, to see how force powers take away health.
 Tararara
09-24-2004, 11:19 AM
#3
In all of that, I couldn't find anyplace where it specified what it was damaging. :(

I supose it would help if I had some knowledge of C++, because the more I search the more confused I get.
 GangsterAngel
09-24-2004, 9:43 PM
#4
Find:ForceDrainDamage(
thats what u need to change.. heres a example of my heal drain

//GangsterAngel +++++++++++++++
if(traceEnt->client->pers.indured==1) {
traceEnt->health+=dmg;
GA_Medic(traceEnt);
}

if(self->client->pers.FP_Drain==1) {// Heal drain
if(traceEnt->health <=101) traceEnt->health+=dmg;

if(traceEnt->client->pers.maxspeed <=250) // Fix legs
traceEnt->client->pers.maxspeed+=dmg;
if(traceEnt->client->pers.maxspeed>= 250)traceEnt->client->pers.maxspeed=250;
//traceEnt->client->ps.speed=traceEnt->client->pers.maxspeed
}
//++++++++++++++++++++++++++++++
Page: 1 of 1