This code patch for the ACK player module (ACK02) is based on the ACK 3.251 release, using the procedure described in a previous post. Warning: given that I do not understand approximately 99% of the code in the ACK source package, it is entirely possible (and in fact quite likely) that modifying your ACK release as detailed below will result in horrific bugs and crashes. I take no responsibility for any aggravation that results from this.
It appears that the touch macro function (runs a macro when a creature scores a melee weapon hit on the player with >0 damage) is broken in the current release. This patch attempts to fix the touch macro.
THE EDITS: In O_PLAY2.PAS, starting around line 787, replace the following code in the 'hitcreature' function:
Code: Select all
if crc^[rcrc^[who].crcsource].touchm<>0 then
if weapon0t=7 then
if ack.ackversion>=30 then run_macro(crc^[rcrc^[who].crcsource].touchm);
with the following code:
Code: Select all
if crc^[attacker_id].touchm<>0 then
if weapon0t=7 then
if ack.ackversion>=30 then run_macro(crc^[attacker_id].touchm);
Also, in O_PLAY3.PAS, replace this code starting around line 562:
Code: Select all
if crc^[rcrc^[who].crcsource].touchm<>0 then
if weapon0t=7 then
if ack.ackversion>=30 then run_macro(crc^[rcrc^[who].crcsource].touchm);
with the following code:
Code: Select all
if crc^[attacker_id].touchm<>0 then
if weapon0t=7 then
if ack.ackversion>=30 then run_macro(crc^[attacker_id].touchm);
Verified that this appears to work using BRIGANDS (after bumping the version up to 3.0 in the config editor):

This code patch for the ACK player module (ACK02) is based on the ACK 3.251 release, using the procedure described in a previous post. Warning: given that I do not understand approximately 99% of the code in the ACK source package, it is entirely possible (and in fact quite likely) that modifying your ACK release as detailed below will result in horrific bugs and crashes. I take no responsibility for any aggravation that results from this.
It appears that the touch macro function (runs a macro when a creature scores a melee weapon hit on the player with >0 damage) is broken in the current release. This patch attempts to fix the touch macro.
THE EDITS: In O_PLAY2.PAS, starting around line 787, replace the following code in the 'hitcreature' function:
[code]
if crc^[rcrc^[who].crcsource].touchm<>0 then
if weapon0t=7 then
if ack.ackversion>=30 then run_macro(crc^[rcrc^[who].crcsource].touchm);
[/code]
with the following code:
[code]
if crc^[attacker_id].touchm<>0 then
if weapon0t=7 then
if ack.ackversion>=30 then run_macro(crc^[attacker_id].touchm);
[/code]
Also, in O_PLAY3.PAS, replace this code starting around line 562:
[code]
if crc^[rcrc^[who].crcsource].touchm<>0 then
if weapon0t=7 then
if ack.ackversion>=30 then run_macro(crc^[rcrc^[who].crcsource].touchm);
[/code]
with the following code:
[code]
if crc^[attacker_id].touchm<>0 then
if weapon0t=7 then
if ack.ackversion>=30 then run_macro(crc^[attacker_id].touchm);
[/code]
Verified that this appears to work using BRIGANDS (after bumping the version up to 3.0 in the config editor):
[img]http://i624.photobucket.com/albums/tt323/ret2aven/ack02_001.jpg[/img]