I'm not at home so I couldn't test if it's actually working.
The following changes set the variables killed_x and killed_y when a monster (and player if you like) is killed. It works exactly like killedid, just with the coordinates instead of the id.
Find (src/map/map.h:308):
SP_KILLEDRID=122,
Add after:
SP_KILLED_X=123,
SP_KILLED_Y=124,
Find (src/map/pc.c:6035):
case SP_KILLEDRID: val = sd->killedrid; break;
Add after:
case SP_KILLED_X: val = sd->killed_x; break;
case SP_KILLED_Y: val = sd->killed_y; break;
Find (src/map/pc.c:6177):
case SP_KILLEDRID:
sd->killedrid = val;
return 1;
Add after:
case SP_KILLED_X:
sd->killed_x = val;
return 1;
case SP_KILLED_Y:
sd->killed_y = val;
return 1;
Find (src/map/mob.c:2429):
pc_setparam(mvp_sd, SP_KILLEDRID, md->class_);
Add after:
pc_setparam(mvp_sd, SP_KILLED_X, md->bl.x);
pc_setparam(mvp_sd, SP_KILLED_Y, md->bl.y);
Find (src/map/pc.h:390):
int killerrid, killedrid;
Add after:
int killed_x, killed_y;
Find (db/const.txt:296):
killedrid 122 1
Add after:
killed_x 123 1
killed_y 124 1
(Edit:) Sets the variables for custom mob kill events and killed players as well.
Find (src/map/mob.c:2416):
pc_setparam(sd, SP_KILLERRID, sd->bl.id);
Add after:
pc_setparam(sd, SP_KILLED_X, sd->bl.x);
pc_setparam(sd, SP_KILLED_Y, sd->bl.y);
Find (src/map/mob.c:2421):
pc_setparam(mvp_sd, SP_KILLERRID, sd?sd->bl.id:0);
Add after:
pc_setparam(mvp_sd, SP_KILLED_X, sd?sd->bl.x:0);
pc_setparam(mvp_sd, SP_KILLED_Y, sd?sd->bl.y:0);
Find (src/map/pc.c:5719):
pc_setparam(sd, SP_KILLERRID, src?src->id:0);
Add After:
pc_setparam(sd, SP_KILLED_X, src?src->x:0);
pc_setparam(sd, SP_KILLED_Y, src?src->y:0);
(/Edit)
If you want to add the x and y coordinates for player kills as well:
Find (src/map/pc.c:5778):
pc_setparam(ssd, SP_KILLEDRID, sd->bl.id);
Add after:
pc_setparam(ssd, SP_KILLED_X, sd->bl.x);
pc_setparam(ssd, SP_KILLED_Y, sd->bl.y);