lorom
math pri on

org 0 ; dummy org to shut asar up

macro write1(p, v)
    org <p>
    db <v>
endmacro

macro write2(p, v)
    org <p>
    dw <v>
endmacro

macro moveSpritemapDown(p_spritemap, y_offset)
    !n = read1(<p_spritemap>)
    !i = 0
    while !i < !n
        !y = read1(<p_spritemap>+2+!i*5+2)
        %write1(<p_spritemap>+2+!i*5+2, !y-<y_offset>)
        !i #= !i+1
    endwhile
endmacro

macro shrinkEnemyHitboxHeight(p_header, y_offset)
    !height = read2(<p_header>+$A)
    %write2(<p_header>+$A, !height-<y_offset>)
endmacro

!yOffset = 8

; Modify space pirate heights

; These are wall pirates, no need to modify them
; %shrinkEnemyHitboxHeight($A0F353, !yOffset)
; %shrinkEnemyHitboxHeight($A0F393, !yOffset)
; %shrinkEnemyHitboxHeight($A0F3D3, !yOffset)
; %shrinkEnemyHitboxHeight($A0F413, !yOffset)
; %shrinkEnemyHitboxHeight($A0F453, !yOffset)
; %shrinkEnemyHitboxHeight($A0F493, !yOffset)

%shrinkEnemyHitboxHeight($A0F4D3, !yOffset)
%shrinkEnemyHitboxHeight($A0F513, !yOffset)
%shrinkEnemyHitboxHeight($A0F553, !yOffset)
%shrinkEnemyHitboxHeight($A0F593, !yOffset)
%shrinkEnemyHitboxHeight($A0F5D3, !yOffset)
%shrinkEnemyHitboxHeight($A0F613, !yOffset)
%shrinkEnemyHitboxHeight($A0F653, !yOffset)
%shrinkEnemyHitboxHeight($A0F693, !yOffset)
%shrinkEnemyHitboxHeight($A0F6D3, !yOffset)
%shrinkEnemyHitboxHeight($A0F713, !yOffset)
%shrinkEnemyHitboxHeight($A0F753, !yOffset)
%shrinkEnemyHitboxHeight($A0F793, !yOffset)

; Modify all spritemaps
%moveSpritemapDown($B2A8E2, !yOffset)
%moveSpritemapDown($B2A90C, !yOffset)
%moveSpritemapDown($B2A93B, !yOffset)
%moveSpritemapDown($B2A965, !yOffset)
%moveSpritemapDown($B2A999, !yOffset)
%moveSpritemapDown($B2A9C8, !yOffset)
%moveSpritemapDown($B2A9FC, !yOffset)
%moveSpritemapDown($B2AA3A, !yOffset)
%moveSpritemapDown($B2AA78, !yOffset)
%moveSpritemapDown($B2AAB6, !yOffset)
%moveSpritemapDown($B2AAEA, !yOffset)
%moveSpritemapDown($B2AB50, !yOffset)
%moveSpritemapDown($B2AB93, !yOffset)
%moveSpritemapDown($B2ABDB, !yOffset)
%moveSpritemapDown($B2AC41, !yOffset)
%moveSpritemapDown($B2AC93, !yOffset)
%moveSpritemapDown($B2ACBD, !yOffset)
%moveSpritemapDown($B2ACEC, !yOffset)
%moveSpritemapDown($B2AD16, !yOffset)
%moveSpritemapDown($B2AD4A, !yOffset)
%moveSpritemapDown($B2AD79, !yOffset)
%moveSpritemapDown($B2ADAD, !yOffset)
%moveSpritemapDown($B2ADEB, !yOffset)
%moveSpritemapDown($B2AE29, !yOffset)
%moveSpritemapDown($B2AE67, !yOffset)
%moveSpritemapDown($B2AE9B, !yOffset)
%moveSpritemapDown($B2AEDE, !yOffset)
%moveSpritemapDown($B2AF26, !yOffset)
%moveSpritemapDown($B2AF8C, !yOffset)
%moveSpritemapDown($B2AFDE, !yOffset)
%moveSpritemapDown($B2B012, !yOffset)
%moveSpritemapDown($B2B04B, !yOffset)
%moveSpritemapDown($B2B089, !yOffset)
%moveSpritemapDown($B2B0C2, !yOffset)
%moveSpritemapDown($B2B0F6, !yOffset)
%moveSpritemapDown($B2B12F, !yOffset)
%moveSpritemapDown($B2B16D, !yOffset)
%moveSpritemapDown($B2B1A6, !yOffset)
%moveSpritemapDown($B2B1DA, !yOffset)
%moveSpritemapDown($B2B20E, !yOffset)
%moveSpritemapDown($B2B242, !yOffset)
%moveSpritemapDown($B2B25D, !yOffset)
%moveSpritemapDown($B2B278, !yOffset)
%moveSpritemapDown($B2B2AC, !yOffset)
%moveSpritemapDown($B2B2E5, !yOffset)
%moveSpritemapDown($B2B323, !yOffset)
%moveSpritemapDown($B2B35C, !yOffset)
%moveSpritemapDown($B2B390, !yOffset)
%moveSpritemapDown($B2B3C9, !yOffset)
%moveSpritemapDown($B2B407, !yOffset)
%moveSpritemapDown($B2B440, !yOffset)
%moveSpritemapDown($B2B474, !yOffset)
%moveSpritemapDown($B2B4A8, !yOffset)
%moveSpritemapDown($B2B4DC, !yOffset)
%moveSpritemapDown($B2B4F2, !yOffset)
%moveSpritemapDown($B2B508, !yOffset)
%moveSpritemapDown($B2B537, !yOffset)
%moveSpritemapDown($B2B566, !yOffset)
%moveSpritemapDown($B2B59A, !yOffset)
%moveSpritemapDown($B2B5C9, !yOffset)
%moveSpritemapDown($B2B5F8, !yOffset)
%moveSpritemapDown($B2B627, !yOffset)
%moveSpritemapDown($B2B656, !yOffset)
%moveSpritemapDown($B2B685, !yOffset)
%moveSpritemapDown($B2B6B9, !yOffset)
%moveSpritemapDown($B2B6E8, !yOffset)
%moveSpritemapDown($B2B717, !yOffset)
%moveSpritemapDown($B2B746, !yOffset)
%moveSpritemapDown($B2B77A, !yOffset)
%moveSpritemapDown($B2B7B8, !yOffset)
%moveSpritemapDown($B2B7F6, !yOffset)
%moveSpritemapDown($B2B82F, !yOffset)
%moveSpritemapDown($B2B863, !yOffset)
%moveSpritemapDown($B2B8A1, !yOffset)
%moveSpritemapDown($B2B8DF, !yOffset)
%moveSpritemapDown($B2B918, !yOffset)
%moveSpritemapDown($B2B947, !yOffset)
%moveSpritemapDown($B2B976, !yOffset)
%moveSpritemapDown($B2B9A0, !yOffset)
%moveSpritemapDown($B2B9CA, !yOffset)
%moveSpritemapDown($B2B9EF, !yOffset)
%moveSpritemapDown($B2BA14, !yOffset)
%moveSpritemapDown($B2BA43, !yOffset)
%moveSpritemapDown($B2BA77, !yOffset)
%moveSpritemapDown($B2BADD, !yOffset)
%moveSpritemapDown($B2BB3E, !yOffset)
%moveSpritemapDown($B2BBA4, !yOffset)
%moveSpritemapDown($B2BBEC, !yOffset)
%moveSpritemapDown($B2BC48, !yOffset)
%moveSpritemapDown($B2BCAE, !yOffset)
%moveSpritemapDown($B2BCFB, !yOffset)
%moveSpritemapDown($B2BD43, !yOffset)
%moveSpritemapDown($B2BD8B, !yOffset)
%moveSpritemapDown($B2BDBA, !yOffset)
%moveSpritemapDown($B2BDCB, !yOffset)
%moveSpritemapDown($B2BE1D, !yOffset)
%moveSpritemapDown($B2BE74, !yOffset)
%moveSpritemapDown($B2BED5, !yOffset)
%moveSpritemapDown($B2BF45, !yOffset)
%moveSpritemapDown($B2BF79, !yOffset)
%moveSpritemapDown($B2BFB7, !yOffset)
%moveSpritemapDown($B2BFF5, !yOffset)
%moveSpritemapDown($B2C02E, !yOffset)
%moveSpritemapDown($B2C062, !yOffset)
%moveSpritemapDown($B2C0A0, !yOffset)
%moveSpritemapDown($B2C0DE, !yOffset)
%moveSpritemapDown($B2C117, !yOffset)
%moveSpritemapDown($B2C146, !yOffset)
%moveSpritemapDown($B2C175, !yOffset)
%moveSpritemapDown($B2C19F, !yOffset)
%moveSpritemapDown($B2C1C9, !yOffset)
%moveSpritemapDown($B2C1EE, !yOffset)
%moveSpritemapDown($B2C213, !yOffset)
%moveSpritemapDown($B2C242, !yOffset)
%moveSpritemapDown($B2C276, !yOffset)
%moveSpritemapDown($B2C2DC, !yOffset)
%moveSpritemapDown($B2C33D, !yOffset)
%moveSpritemapDown($B2C3A3, !yOffset)
%moveSpritemapDown($B2C3EB, !yOffset)
%moveSpritemapDown($B2C447, !yOffset)
%moveSpritemapDown($B2C4AD, !yOffset)
%moveSpritemapDown($B2C4FA, !yOffset)
%moveSpritemapDown($B2C542, !yOffset)
%moveSpritemapDown($B2C58A, !yOffset)
%moveSpritemapDown($B2C5B9, !yOffset)
%moveSpritemapDown($B2C60B, !yOffset)
%moveSpritemapDown($B2C662, !yOffset)
%moveSpritemapDown($B2C6C3, !yOffset)
%moveSpritemapDown($B2C733, !yOffset)
%moveSpritemapDown($B2C749, !yOffset)
%moveSpritemapDown($B2C769, !yOffset)
%moveSpritemapDown($B2C784, !yOffset)
%moveSpritemapDown($B2C7A9, !yOffset)
%moveSpritemapDown($B2C7BF, !yOffset)
%moveSpritemapDown($B2C7DF, !yOffset)
%moveSpritemapDown($B2C7FA, !yOffset)
%moveSpritemapDown($B2C81F, !yOffset)
%moveSpritemapDown($B2C862, !yOffset)
%moveSpritemapDown($B2C8AA, !yOffset)
%moveSpritemapDown($B2C910, !yOffset)
%moveSpritemapDown($B2C926, !yOffset)
%moveSpritemapDown($B2C946, !yOffset)
%moveSpritemapDown($B2C961, !yOffset)
%moveSpritemapDown($B2C986, !yOffset)
%moveSpritemapDown($B2C99C, !yOffset)
%moveSpritemapDown($B2C9BC, !yOffset)
%moveSpritemapDown($B2C9D7, !yOffset)
%moveSpritemapDown($B2C9FC, !yOffset)
%moveSpritemapDown($B2CA26, !yOffset)
%moveSpritemapDown($B2CA55, !yOffset)
%moveSpritemapDown($B2CA7F, !yOffset)
%moveSpritemapDown($B2CAB3, !yOffset)
%moveSpritemapDown($B2CAE2, !yOffset)
%moveSpritemapDown($B2CB16, !yOffset)
%moveSpritemapDown($B2CB54, !yOffset)
%moveSpritemapDown($B2CB92, !yOffset)
%moveSpritemapDown($B2CBD0, !yOffset)
%moveSpritemapDown($B2CC04, !yOffset)
%moveSpritemapDown($B2CC6A, !yOffset)
%moveSpritemapDown($B2CCAD, !yOffset)
%moveSpritemapDown($B2CCF5, !yOffset)
%moveSpritemapDown($B2CD5B, !yOffset)
%moveSpritemapDown($B2CDAD, !yOffset)
%moveSpritemapDown($B2CDD7, !yOffset)
%moveSpritemapDown($B2CE06, !yOffset)
%moveSpritemapDown($B2CE30, !yOffset)
%moveSpritemapDown($B2CE64, !yOffset)
%moveSpritemapDown($B2CE93, !yOffset)
%moveSpritemapDown($B2CEC7, !yOffset)
%moveSpritemapDown($B2CF05, !yOffset)
%moveSpritemapDown($B2CF43, !yOffset)
%moveSpritemapDown($B2CF81, !yOffset)
%moveSpritemapDown($B2CFB5, !yOffset)
%moveSpritemapDown($B2CFF8, !yOffset)
%moveSpritemapDown($B2D040, !yOffset)
%moveSpritemapDown($B2D0A6, !yOffset)
%moveSpritemapDown($B2D0F8, !yOffset)
%moveSpritemapDown($B2D12C, !yOffset)
%moveSpritemapDown($B2D165, !yOffset)
%moveSpritemapDown($B2D1A3, !yOffset)
%moveSpritemapDown($B2D1DC, !yOffset)
%moveSpritemapDown($B2D210, !yOffset)
%moveSpritemapDown($B2D249, !yOffset)
%moveSpritemapDown($B2D287, !yOffset)
%moveSpritemapDown($B2D2C0, !yOffset)
%moveSpritemapDown($B2D2F4, !yOffset)
%moveSpritemapDown($B2D328, !yOffset)
%moveSpritemapDown($B2D339, !yOffset)
%moveSpritemapDown($B2D345, !yOffset)
%moveSpritemapDown($B2D356, !yOffset)
%moveSpritemapDown($B2D362, !yOffset)
%moveSpritemapDown($B2D373, !yOffset)
%moveSpritemapDown($B2D37F, !yOffset)
%moveSpritemapDown($B2D390, !yOffset)
%moveSpritemapDown($B2D39C, !yOffset)
%moveSpritemapDown($B2D3D0, !yOffset)
%moveSpritemapDown($B2D3EB, !yOffset)
%moveSpritemapDown($B2D406, !yOffset)
%moveSpritemapDown($B2D43A, !yOffset)
%moveSpritemapDown($B2D473, !yOffset)
%moveSpritemapDown($B2D4B1, !yOffset)
%moveSpritemapDown($B2D4EA, !yOffset)
%moveSpritemapDown($B2D51E, !yOffset)
%moveSpritemapDown($B2D557, !yOffset)
%moveSpritemapDown($B2D595, !yOffset)
%moveSpritemapDown($B2D5CE, !yOffset)
%moveSpritemapDown($B2D602, !yOffset)
%moveSpritemapDown($B2D636, !yOffset)
%moveSpritemapDown($B2D647, !yOffset)
%moveSpritemapDown($B2D653, !yOffset)
%moveSpritemapDown($B2D664, !yOffset)
%moveSpritemapDown($B2D670, !yOffset)
%moveSpritemapDown($B2D681, !yOffset)
%moveSpritemapDown($B2D68D, !yOffset)
%moveSpritemapDown($B2D69E, !yOffset)
%moveSpritemapDown($B2D6AA, !yOffset)
%moveSpritemapDown($B2D6DE, !yOffset)
%moveSpritemapDown($B2D6F4, !yOffset)
%moveSpritemapDown($B2D70A, !yOffset)
%moveSpritemapDown($B2D739, !yOffset)
%moveSpritemapDown($B2D768, !yOffset)
%moveSpritemapDown($B2D79C, !yOffset)
%moveSpritemapDown($B2D7CB, !yOffset)
%moveSpritemapDown($B2D7FA, !yOffset)
%moveSpritemapDown($B2D829, !yOffset)
%moveSpritemapDown($B2D858, !yOffset)
%moveSpritemapDown($B2D887, !yOffset)
%moveSpritemapDown($B2D8BB, !yOffset)
%moveSpritemapDown($B2D8EA, !yOffset)
%moveSpritemapDown($B2D919, !yOffset)
%moveSpritemapDown($B2D948, !yOffset)
%moveSpritemapDown($B2D97C, !yOffset)
%moveSpritemapDown($B2D9BA, !yOffset)
%moveSpritemapDown($B2D9F8, !yOffset)
%moveSpritemapDown($B2DA31, !yOffset)
%moveSpritemapDown($B2DA65, !yOffset)
%moveSpritemapDown($B2DAA3, !yOffset)
%moveSpritemapDown($B2DAE1, !yOffset)
%moveSpritemapDown($B2DB1A, !yOffset)
%moveSpritemapDown($B2DB49, !yOffset)
%moveSpritemapDown($B2DB78, !yOffset)
%moveSpritemapDown($B2DBA2, !yOffset)
%moveSpritemapDown($B2DBCC, !yOffset)
%moveSpritemapDown($B2DBF1, !yOffset)
%moveSpritemapDown($B2DC16, !yOffset)
%moveSpritemapDown($B2DC45, !yOffset)
%moveSpritemapDown($B2DC79, !yOffset)
%moveSpritemapDown($B2DCDF, !yOffset)
%moveSpritemapDown($B2DD40, !yOffset)
%moveSpritemapDown($B2DDA6, !yOffset)
%moveSpritemapDown($B2DDEE, !yOffset)
%moveSpritemapDown($B2DE4A, !yOffset)
%moveSpritemapDown($B2DEBA, !yOffset)
%moveSpritemapDown($B2DF20, !yOffset)
%moveSpritemapDown($B2DF6D, !yOffset)
%moveSpritemapDown($B2DFB5, !yOffset)
%moveSpritemapDown($B2DFFD, !yOffset)
%moveSpritemapDown($B2E02C, !yOffset)
%moveSpritemapDown($B2E03D, !yOffset)
%moveSpritemapDown($B2E08F, !yOffset)
%moveSpritemapDown($B2E0E6, !yOffset)
%moveSpritemapDown($B2E147, !yOffset)
%moveSpritemapDown($B2E1A8, !yOffset)
%moveSpritemapDown($B2E1DC, !yOffset)
%moveSpritemapDown($B2E21A, !yOffset)
%moveSpritemapDown($B2E258, !yOffset)
%moveSpritemapDown($B2E291, !yOffset)
%moveSpritemapDown($B2E2C5, !yOffset)
%moveSpritemapDown($B2E303, !yOffset)
%moveSpritemapDown($B2E341, !yOffset)
%moveSpritemapDown($B2E37A, !yOffset)
%moveSpritemapDown($B2E3A9, !yOffset)
%moveSpritemapDown($B2E3D8, !yOffset)
%moveSpritemapDown($B2E402, !yOffset)
%moveSpritemapDown($B2E42C, !yOffset)
%moveSpritemapDown($B2E451, !yOffset)
%moveSpritemapDown($B2E476, !yOffset)
%moveSpritemapDown($B2E4A5, !yOffset)
%moveSpritemapDown($B2E4D9, !yOffset)
%moveSpritemapDown($B2E53F, !yOffset)
%moveSpritemapDown($B2E5A0, !yOffset)
%moveSpritemapDown($B2E606, !yOffset)
%moveSpritemapDown($B2E64E, !yOffset)
%moveSpritemapDown($B2E6AA, !yOffset)
%moveSpritemapDown($B2E71A, !yOffset)
%moveSpritemapDown($B2E780, !yOffset)
%moveSpritemapDown($B2E7CD, !yOffset)
%moveSpritemapDown($B2E815, !yOffset)
%moveSpritemapDown($B2E85D, !yOffset)
%moveSpritemapDown($B2E88C, !yOffset)
%moveSpritemapDown($B2E8DE, !yOffset)
%moveSpritemapDown($B2E935, !yOffset)
%moveSpritemapDown($B2E996, !yOffset)
%moveSpritemapDown($B2E9F7, !yOffset)
%moveSpritemapDown($B2EA0D, !yOffset)
%moveSpritemapDown($B2EA2D, !yOffset)
%moveSpritemapDown($B2EA48, !yOffset)
%moveSpritemapDown($B2EA6D, !yOffset)
%moveSpritemapDown($B2EA83, !yOffset)
%moveSpritemapDown($B2EAA3, !yOffset)
%moveSpritemapDown($B2EABE, !yOffset)
%moveSpritemapDown($B2EAE3, !yOffset)
%moveSpritemapDown($B2EB26, !yOffset)
%moveSpritemapDown($B2EB6E, !yOffset)
%moveSpritemapDown($B2EBD4, !yOffset)
%moveSpritemapDown($B2EBEA, !yOffset)
%moveSpritemapDown($B2EC0A, !yOffset)
%moveSpritemapDown($B2EC25, !yOffset)
%moveSpritemapDown($B2EC4A, !yOffset)
%moveSpritemapDown($B2EC60, !yOffset)
%moveSpritemapDown($B2EC80, !yOffset)
%moveSpritemapDown($B2EC9B, !yOffset)
