structure.c line 7958: if (psDroid->resistance <= 0) // comparison of <= 0 does not match previous expressions of < 0

structure.c: electronicDamage: Shouldnt the system check if droid count is exceeded before calling "(void)giftSingleDroid(psDroid, attackPlayer);" It does this afterwards and calls recycledroid after giftSingleDroid.

Calls (void)giftSingleDroid(psDroid, attackPlayer); which clones the object, destroying the original pointer, later, the routine attempts to "recycle" the pointer to droid which is now invalid.

// tell the cluster system it has been attacked clustObjectAttacked((BASE_OBJECT *)psDroid); psDroid->resistance = (SWORD)(psDroid->resistance - damage); if (psDroid->resistance <= 0) { //add a console message for the selected Player if (psDroid->player == selectedPlayer) {