Prev: 42150 Up: Map Next: 42179
42163: Award Actor Points
Used by the routine at BlowUpActor.
Adds points to the score for blowing up an actor. The points are 100 plus a value of 101 117 133 or 149 depending on bits 1-2 of the sprite ID, so they are 165, 175, 185 or 195.
Input
IX Actor record
AwardActorPoints 42163 LD A,(IX+0) Fetch the sprite ID of the actor.
42166 RLCA Rotate the sprite ID left three times.
42167 RLCA
42168 RLCA
42169 AND %00110000 Keep only the type of the actor (bits 4-5).
42171 ADD A,101 Add 101.
42173 LD C,A Stash the low byte of the points in C.
42174 LD B,1 Set the high byte of the points in B to 1.
42176 JP AddPointsToScore Jump to AddPointsToScore to add the points to the score.
Prev: 42150 Up: Map Next: 42179