zz zz schreef: >> When applying your patch I'm getting compiler errors, these to be >> precise: >> > feature.h: In function `void proj_ImpactFunc(PROJ_OBJECT*)': >> > feature.h:54: error: too many arguments to function `BOOL >> > featureDamage(FEATURE*, UDWORD, UDWORD)' >> > projectile.c:2081: error: at this point in file >> > feature.h: In function `BOOL objectDamage(BASE_OBJECT*, UDWORD, >> > UDWORD, UDWORD)': >> > feature.h:54: error: too many arguments to function `BOOL >> > featureDamage(FEATURE*, UDWORD, UDWORD)' >> > projectile.c:2507: error: at this point in file >> Which occurs because you added `psStats->weaponClass' before >> `psStats->weaponSubClass' in the argumentlist on line 2081. >> And because you added `weaponClass' before `weaponSubClass' in the >> argumentlist on line 2507. >> >> Both these changes where done without modifying feature.h and feature.c >> which would be a required change. When I simply revert the changes of >> those two lines your patch compiles without errors. >> >> -- >> Giel > I didnt touch 'featureDamage()' function,maybe someone changed it > recently after I created this patch...though I didnt have problems > compiling with these changes with the latest rev. > > this is rev 391 line 1891 to line 1894:(line 2078 to line 2081 after > my changes) > bKilled = featureDamage(psCurrF, > calcDamage(weaponRadDamage( > psStats, psObj->player), > psStats->weaponEffect, > (BASE_OBJECT *)psCurrF), > psStats->weaponClass, > psStats->weaponSubClass);
Are you sure about the revision number of 391? Because the most current version is 510. Secondly I've checked the logs and I found that the function prototype has indeed changed in revision 507, so my advise is to change your patch accordingly and it should then compile cleanly. Diff of feature.h r507: > Index: feature.h > =================================================================== > --- feature.h (revision 506) > +++ feature.h (revision 507) > @@ -51,8 +51,7 @@ > wreckage to clear*/ > extern FEATURE * checkForWreckage(DROID *psDroid); > > -extern BOOL featureDamage(FEATURE *psFeature, UDWORD damage, UDWORD > weaponClass, > - UDWORD weaponSubClass); > +extern BOOL featureDamage(FEATURE *psFeature, UDWORD damage, UDWORD > weaponSubClass); > > #endif > > -- Giel
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Warzone-dev mailing list Warzone-dev@gna.org https://mail.gna.org/listinfo/warzone-dev