Prev: 45585 Up: Map Next: 45676
45642: WitnessMoraleLoss
A = a witness slot: if he is still alive, -1 morale (clamped at 0) and record his slot in H ("a live witness saw it").
45642 LD B,A IX -> the witness's record
45643 LD IX,29566
45647 LD DE,8
45650 ADD IX,DE
45652 DJNZ 45650
45654 LD B,A keep the slot in B
45655 LD A,(IX+7) still alive?
45658 OR A
45659 RET NZ no: the dead see nothing
45660 DEC (IX+6) morale -1,
45663 LD A,127
45665 CP (IX+6) clamped at 0
45668 JR NC,45674
45670 LD (IX+6),0
45674 LD H,B H = this live witness's slot
45675 RET
Prev: 45585 Up: Map Next: 45676