A92: Cutting off sprites


[Prev][Next][Index][Thread]

A92: Cutting off sprites




how is it possible to cut off how many lines are in a sprite from within the 
sprite:...mask: construct using a register?  for example:
sprite(x,y,lines)
int x;
int y;
int lines;
{
asm("
    move.w 8(%sp),%d0
    move.w 10(%sp),%d1
    move.w 12(%sp),%d2
    lea sprites(%PC),%a0
    bra oversprite
sprites:
    dc.w    %d2 //error received here
    dc.w    3
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
    dc.b    255,255,255
oversprite:
");
put_sprite();
};

is there a way to do it?