# T o u h o u D a n m a k u f u [ S i n g l e ] 
 
 # S c r i p t V e r s i o n [ 3 ] 
 
 # T i t l e [ " v s   M a g i c   T e a m   s p e l l   c a r d   0 1   h a r d " ] 
 
 # T e x t [ " v s   M a g i c   T e a m   s p e l l   c a r d   0 1   h a r d " ] 
 
 
 
 l e t   m s p a r k T e x   =   " s c r i p t / p l a y e r / d c s _ p l a y e r / d c s m a g i c b . p n g " ; 
 
 l e t   t o s s   =   f a l s e ;   
 
 
 
 l e t   c u t M a r i s a   =   " s c r i p t / t h d c s / s y s t e m / f a c e / m a r i s a n o r m . p n g " ; 
 
 l e t   c u t A r i s u   =   " s c r i p t / t h d c s / s y s t e m / f a c e / a r i s u n o r m . p n g " ; 
 
 
 
 # i n c l u d e   " s c r i p t / t h d c s / s y s t e m / s h o t l i b r a r y . t x t " 
 
 # i n c l u d e   " s c r i p t / t h d c s / f u n c t i o n s / f u n c t i o n _ c o m m o n . t x t " 
 
 # i n c l u d e   " s c r i p t / t h d c s / f u n c t i o n s / f u n c t i o n _ g l o b a l . t x t " 
 
 # i n c l u d e   " s c r i p t / t h d c s / f u n c t i o n s / f u n c t i o n _ b o s s e f f . t x t " 
 
 # i n c l u d e   " s c r i p t / t h d c s / f u n c t i o n s / f u n c t i o n _ c u t i n . t x t " 
 
 
 
 @ I n i t i a l i z e   { 
 
 	 S e t C o m m o n D a t a ( " s p e l l S c r i p t I D " , G e t O w n S c r i p t I D ) ; 
 
 
 
 	 S e t C o m m o n D a t a ( " i s D u e t " ,   t r u e ) ; 
 
 	 S e t C o m m o n D a t a ( " b o s s C i r c l e T y p e " , 0 ) ; 
 
 	 S e t C o m m o n D a t a ( " b o s s A t t a c k T y p e " , 2 ) ; 
 
 	 S e t C o m m o n D a t a ( " b o s s B g T y p e " , 3 2 ) ; 
 
 	 r e n d e r B o s s ( 3 3 ) ; 
 
 	 r e n d e r B o s s 2 ( 3 4 ) ; 
 
 	 b o s s M a g i c C i r c l e 2 ; 
 
 	 s e t A u r a ( b o s s O b j , 1 8 0 , 1 8 0 , 3 2 ) ; 
 
 	 s e t A u r a ( b o s s 2 O b j , 6 4 , 6 4 , 2 5 5 ) ; 
 
 	 s e t I n v u l n e r a b l e T i m e ( b o s s O b j , 2 4 0 ) ; 
 
 	 s e t I n v u l n e r a b l e T i m e ( b o s s 2 O b j , 2 4 0 ) ; 
 
 
 
 	 i f ( G e t A r e a C o m m o n D a t a ( " s y s t e m " , " g a m e L a n g " , 0 )   = =   0 )   {   S e t C o m m o n D a t a ( " c a r d N a m e " , " ۘ 00gzzNb_rd
0" ) ;   } 
 
 	 i f ( G e t A r e a C o m m o n D a t a ( " s y s t e m " , " g a m e L a n g " , 0 )   = =   1 )   {   S e t C o m m o n D a t a ( " c a r d N a m e " , " F l i g h t   0A e r i a l   D o l l   B o m b i n g 
0" ) ;   } 
 
 
 
 	 O b j M o v e _ S e t P o s i t i o n ( b o s s O b j , b o s s X , b o s s Y ) ; 
 
 	 O b j M o v e _ S e t P o s i t i o n ( b o s s 2 O b j , G e t C o m m o n D a t a ( " b o s s 2 X " , b o s s 2 X ) , G e t C o m m o n D a t a ( " b o s s 2 Y " , b o s s 2 Y ) ) ; 
 
 	 
 
 	 O b j M o v e _ S e t D e s t A t S p e e d ( b o s s O b j , G e t C e n t e r X - 6 4 , 1 2 0 , 5 ) ; 
 
 	 O b j M o v e _ S e t D e s t A t S p e e d ( b o s s 2 O b j , G e t C e n t e r X + 6 4 , 1 2 0 , 5 ) ; 
 
 	 S e t S h o t A u t o D e l e t e C l i p ( 3 2 , 3 2 , 3 2 , 3 2 ) ; 
 
 
 
 	 c u t i n ( N A Z R I N , c u t M a r i s a , 0 , 0 , 1 0 2 4 , 1 0 2 4 , 0 . 4 ) ; 
 
 	 c u t i n 2 ( D U E T 1 , 0 , c u t A r i s u , 0 , 0 , 1 0 2 4 , 1 0 2 4 , 0 . 4 ) ; 
 
 
 
 	 S e t A u t o D e l e t e O b j e c t ( t r u e ) ; 
 
 	 m a i n T a s k ; 
 
 }   
 
 
 
 @ E v e n t   {   
 
 	 a l t e r n a t i v e ( G e t E v e n t T y p e ( ) )   
 
 	 c a s e ( E V _ R E Q U E S T _ L I F E )   {   
 
 	 	 S e t S c r i p t R e s u l t ( 4 2 0 ) ; 
 
 	 } 
 
 	 c a s e ( E V _ R E Q U E S T _ T I M E R )   {   
 
 	 	 S e t S c r i p t R e s u l t ( 5 7 ) ; 
 
 	 } 
 
 	 c a s e ( E V _ R E Q U E S T _ S P E L L _ S C O R E )   { 
 
 	         l e t   s p e l l C a r d B o n u s   =   c a l c u l a t e A n d G e t S p e l l C a r d B o n u s ( ) ; 
 
 	 	 S e t S c r i p t R e s u l t ( s p e l l C a r d B o n u s ) ; 
 
 	 } 	 
 
 	 c a s e ( E V _ U S E R + 9 9 9 9 )   { 
 
 	 	 S e t C o m m o n D a t a ( " s p e l l c a r d I D " , " m a g i c 0 1 h a r d " ) ;   
 
 	 } 
 
 }   
 
 
 
 @ M a i n L o o p   {   y i e l d ;   }   
 
 @ F i n a l i z e   {   }   
 
 
 
 t a s k   m a i n T a s k   {   
 
 	 y i e l d ; 
 
 	 s c r i p t E n d i n g ; 	 
 
 	 w a i t ( 6 0 ) ; 
 
 	 c o n t r o l ; 
 
 }   
 
 
 
 / /   I n i t i a l   c o n t r o l 
 
 t a s k   c o n t r o l   { 
 
 	 w h i l e ( !   O b j _ I s D e l e t e d ( b o s s O b j ) )   { 	 
 
 	 	 O b j M o v e _ S e t D e s t A t S p e e d ( b o s s O b j , G e t C e n t e r X , 6 4 , 5 ) ; 
 
 	 	 w a i t ( 6 0 ) ; 
 
 	 	 a r i s u R a n d M o v e ; 
 
 	 	 b o s s A t t a c k   =   1 ; 
 
 	 	 c o n c e n E f f e c t ( b o s s O b j , 1 0 , 4 , 2 5 5 , 2 5 5 , 6 4 ) ; 
 
 	 	 c o n c e n E f f e c t ( b o s s O b j , 1 0 , 4 , 6 4 , 6 4 , 2 5 5 ) ; 
 
 	 	 c o n c e n E f f e c t ( b o s s O b j , 1 0 , 4 , 6 4 , 2 5 5 , 6 4 ) ; 
 
 	 	 d i s c o S p a r k ; 
 
 	 	 d i s c o S t a r s ; 
 
 	 	 w a i t ( 3 6 0 ) ; 
 
 	 	 m a r i s a R a n d M o v e ; 
 
 	 	 s u m m o n D o l l s ; 
 
 	 	 w a i t ( 5 0 0 ) ; 
 
 	 	 O b j M o v e _ S e t D e s t A t W e i g h t ( b o s s O b j , G e t C e n t e r X - 9 6 , 1 2 0 , 2 0 , 3 0 ) ; 
 
 	 	 O b j M o v e _ S e t D e s t A t W e i g h t ( b o s s 2 O b j , G e t C e n t e r X + 9 6 , 1 2 0 , 2 0 , 3 0 ) ; 
 
 	 	 w a i t ( 1 8 0 ) ; 
 
 	 	 
 
 	 	 O b j M o v e _ S e t D e s t A t S p e e d ( b o s s O b j , G e t C e n t e r X , 6 4 , 5 ) ; 
 
 	 	 w a i t ( 6 0 ) ; 
 
 	 	 a r i s u R a n d M o v e ; 
 
 	 	 b o s s A t t a c k   =   1 ; 
 
 	 	 c o n c e n E f f e c t ( b o s s O b j , 1 0 , 4 , 2 5 5 , 2 5 5 , 6 4 ) ; 
 
 	 	 c o n c e n E f f e c t ( b o s s O b j , 1 0 , 4 , 6 4 , 6 4 , 2 5 5 ) ; 
 
 	 	 c o n c e n E f f e c t ( b o s s O b j , 1 0 , 4 , 6 4 , 2 5 5 , 6 4 ) ; 
 
 	 	 d i s c o S p a r k ; 
 
 	 	 d i s c o S t a r s 2 ; 
 
 	 	 w a i t ( 3 6 0 ) ; 
 
 	 	 m a r i s a R a n d M o v e ; 
 
 	 	 s u m m o n D o l l s ; 
 
 	 	 w a i t ( 5 0 0 ) ; 
 
 	 	 O b j M o v e _ S e t D e s t A t W e i g h t ( b o s s O b j , G e t C e n t e r X - 9 6 , 1 2 0 , 2 0 , 3 0 ) ; 
 
 	 	 O b j M o v e _ S e t D e s t A t W e i g h t ( b o s s 2 O b j , G e t C e n t e r X + 9 6 , 1 2 0 , 2 0 , 3 0 ) ; 
 
 	 	 w a i t ( 1 8 0 ) ; 	 	 
 
 	 } 
 
 } 
 
 
 
 / /   M a r i s a   r a n d o m   m o v e m e n t 
 
 t a s k   m a r i s a R a n d M o v e   { 
 
 	 l o o p ( 5 )   { 
 
 	 	 O b j M o v e _ R a n d o m P o s W e i g h t ( b o s s O b j , r a n d _ i n t ( 4 5 , 7 5 ) , r a n d _ i n t ( 1 5 , 3 0 ) , 2 0 , 3 0 , G e t C l i p M i n X + 3 2 , G e t C l i p M i n Y + 1 1 2 , G e t C l i p M a x X - 3 2 , G e t C l i p M i n Y + 1 2 0 ) ; 
 
 	 	 w a i t ( 6 0 ) ; 
 
 	 } 
 
 } 
 
 
 
 / /   A l i c e   r a n d o m   m o v e m e n t 
 
 t a s k   a r i s u R a n d M o v e   { 
 
 	 l o o p ( 5 )   { 
 
 	 	 O b j M o v e _ R a n d o m P o s W e i g h t ( b o s s 2 O b j , r a n d _ i n t ( 4 5 , 7 5 ) , r a n d _ i n t ( 1 5 , 3 0 ) , 2 0 , 3 0 , G e t C l i p M i n X + 3 2 , G e t C l i p M i n Y + 1 1 2 , G e t C l i p M a x X - 3 2 , G e t C l i p M i n Y + 1 2 0 ) ; 
 
 	 	 w a i t ( 6 0 ) ; 
 
 	 } 
 
 } 
 
 
 
 / /   M a r i s a   b l a z i n g   s t a r 
 
 t a s k   m a r i s a B l a z e   {   
 
 	 w a i t ( 6 0 ) ; 
 
 	 l e t   d i r   =   0 ; 
 
 	 l e t   l a s t X   =   G e t P l a y e r X ; 
 
 	 O b j M o v e _ S e t D e s t A t S p e e d ( b o s s O b j , l a s t X , G e t C l i p M i n Y - 6 4 , 5 ) ; 
 
 	 w h i l e ( O b j M o v e _ G e t S p e e d ( b o s s O b j )   >   0 )   {   y i e l d ;   }   
 
 	 l a s t X   =   G e t P l a y e r X ; 
 
 	 O b j M o v e _ S e t S p e e d ( b o s s O b j , 0 ) ;   
 
 	 d i r   =   G e t P o i n t T o P o i n t A n g l e ( G e t P l a y e r X , G e t P l a y e r Y , b o s s X , b o s s Y ) ; 
 
 	 O b j M o v e _ S e t A n g l e ( b o s s O b j , d i r ) ; 
 
 	 O b j M o v e _ S e t A c c e l e r a t i o n ( b o s s O b j , 0 . 2 ) ;   
 
 	 O b j M o v e _ S e t M a x S p e e d ( b o s s O b j , 8 ) ; 
 
 	 m a r i s a B l a z e L a s e r ; 
 
 	 P l a y S F X ( S F X _ N E P 0 0 ) ; 
 
 	 q u a k e C a m 2 D ( 5 , 1 2 0 ) ;   q u a k e C a m 3 D ( 5 , 1 2 0 ) ; 
 
 	 w a i t ( 1 2 0 ) ; 
 
 	 O b j M o v e _ S e t D e s t A t S p e e d ( b o s s O b j , G e t C e n t e r X , G e t C e n t e r Y - 6 4 , 7 ) ; 	 
 
 } 
 
 
 
 / /   M a r i s a   b a c k w a r d   f i r i n g   l a s e r 
 
 t a s k   m a r i s a B l a z e L a s e r   { 
 
 	 l e t   d i r   =   0 ; 
 
 	 d i r   =   G e t P o i n t T o P o i n t A n g l e ( G e t P l a y e r X , G e t P l a y e r Y , b o s s X , b o s s Y ) ; 
 
 	 l o o p ( 2 4 )   {   
 
 	 	 f a k e L a s e r S h o t 2 ( b o s s X , b o s s Y , d i r - 1 8 0 , 0 ) ; 
 
 	 	 w a i t ( 5 ) ; 
 
 	 } 
 
 } 
 
 
 
 / /   S u m m o n   d o l l s 
 
 t a s k   s u m m o n D o l l s   {   
 
 	 l e t   d i r   =   r a n d _ i n t ( 0 , 3 6 0 ) ; 
 
 	 a s c e n t ( i   i n   0 . . 5 )   {   
 
 	 	 s h a n g h a i D o l l ( b o s s 2 X + 6 4 * c o s ( d i r ) , b o s s 2 Y + 6 4 * s i n ( d i r ) , d i r ) ; 
 
 	 	 d i r + = 3 6 0 / 5 ; 
 
 	 } 
 
 	 O b j M o v e _ S e t D e s t A t S p e e d ( b o s s 2 O b j , G e t C e n t e r X + r a n d _ i n t ( - 9 6 , 9 6 ) , b o s s Y , 2 ) ; 
 
 	 w a i t ( 2 4 0 ) ; 
 
 	 O b j M o v e _ S e t D e s t A t W e i g h t ( b o s s 2 O b j , G e t C e n t e r X , G e t C e n t e r Y , 2 0 , 3 0 ) ; 
 
 	 m a r i s a B l a z e ; 
 
 	 w a i t ( 1 5 ) ; 
 
 	 t o s s   =   t r u e ; 
 
 	 w a i t ( 1 2 0 ) ; 
 
 	 t o s s   =   f a l s e ; 
 
 } 
 
 
 
 / /   S t a r s   z e 
 
 t a s k   d i s c o S t a r s   { 
 
 	 l e t   d i r   =   0 ; 
 
 	 l e t   k l e u r   =   1 9 4 ; 
 
 	 a s c e n t ( i   i n   0 . . 2 0 )   { 
 
 	 	 a s c e n t ( j   i n   0 . . 8 )   {   
 
 	 	 	 l e t   s t a r S h o t 0 0   =   C r e a t e S h o t A ( G e t E n e m y X , G e t E n e m y Y , 1 5 ) ; 
 
 	 	 	 S e t S h o t D a t a A ( s t a r S h o t 0 0 , 0 , 2 , d i r , 0 , 0 , 2 , k l e u r ) ; 
 
 	 	 	 S e t S h o t D a t a A ( s t a r S h o t 0 0 , 2 5 , 0 , d i r , 0 , 0 , 0 , k l e u r ) ; 
 
 	 	 	 S e t S h o t D a t a A ( s t a r S h o t 0 0 , 1 2 0 , 3 , d i r , 0 . 1 , 0 . 0 5 , 3 , k l e u r ) ; 
 
 	 	 	 d i r + = 3 6 0 / 8 ; 
 
 	 	 } 
 
 	 	 k l e u r + + ; 
 
 	 	 i f ( k l e u r   >   2 0 0 )   {   k l e u r   =   1 9 4 ;   }   
 
 	 	 w a i t ( 1 0 ) ; 
 
 	 	 d i r + = 8 ; 
 
 	 } 
 
 } 
 
 
 
 / /   S t a r s   z e   2 
 
 t a s k   d i s c o S t a r s 2   { 
 
 	 l e t   d i r   =   0 ; 
 
 	 l e t   k l e u r   =   1 9 4 ; 
 
 	 a s c e n t ( i   i n   0 . . 2 0 )   { 
 
 	 	 a s c e n t ( j   i n   0 . . 8 )   {   
 
 	 	 	 l e t   s t a r S h o t 0 0   =   C r e a t e S h o t A ( G e t E n e m y X , G e t E n e m y Y , 1 5 ) ; 
 
 	 	 	 S e t S h o t D a t a A ( s t a r S h o t 0 0 , 0 , 2 , d i r , 0 , 0 , 2 , k l e u r ) ; 
 
 	 	 	 S e t S h o t D a t a A ( s t a r S h o t 0 0 , 2 5 , 0 , d i r , 0 , 0 , 0 , k l e u r ) ; 
 
 	 	 	 S e t S h o t D a t a A ( s t a r S h o t 0 0 , 1 2 0 , 3 , d i r , 0 . 1 , 0 . 0 5 , 3 , k l e u r ) ; 
 
 	 	 	 d i r - = 3 6 0 / 8 ; 
 
 	 	 } 
 
 	 	 k l e u r + + ; 
 
 	 	 i f ( k l e u r   >   2 0 0 )   {   k l e u r   =   1 9 4 ;   }   
 
 	 	 w a i t ( 1 0 ) ; 
 
 	 	 d i r - = 8 ; 
 
 	 } 
 
 } 
 
 
 
 / /   D i s c o   S p a r k 
 
 t a s k   d i s c o S p a r k   {   
 
 	 w a i t ( 3 0 ) ; 
 
 	 l e t   d i r   =   9 0 ; 
 
 	 P l a y S F X ( S F X _ C A T 0 0 ) ; 
 
 	 P l a y S F X ( S F X _ C I R C S T A R T ) ; 
 
 	 C r e a t e S t r a i g h t L a s e r A 1 ( b o s s X + 2 4 , b o s s Y - 3 2 , d i r - 6 4 , 6 4 0 , 3 2 , 0 , 2 , 6 0 ) ; 
 
 	 C r e a t e S t r a i g h t L a s e r A 1 ( b o s s X + 2 4 , b o s s Y - 3 2 , d i r , 6 4 0 , 3 2 , 0 , 2 , 6 0 ) ; 
 
 	 C r e a t e S t r a i g h t L a s e r A 1 ( b o s s X + 2 4 , b o s s Y - 3 2 , d i r + 6 4 , 6 4 0 , 3 2 , 0 , 2 , 6 0 ) ; 
 
 	 f a k e L a s e r S h o t ( b o s s X + 2 4 , b o s s Y - 3 2 , d i r - 6 4 , 6 0 ) ; 
 
 	 f a k e L a s e r S h o t ( b o s s X + 2 4 , b o s s Y - 3 2 , d i r , 6 0 ) ; 
 
 	 f a k e L a s e r S h o t ( b o s s X + 2 4 , b o s s Y - 3 2 , d i r + 6 4 , 6 0 ) ; 
 
 	 q u a k e C a m 2 D ( 5 , 3 0 ) ;   q u a k e C a m 3 D ( 5 , 3 0 ) ; 
 
 	 w a i t ( 6 0 ) ; 
 
 	 P l a y S F X ( S F X _ N E P 0 0 ) ; 
 
 	 a s c e n t ( i   i n   0 . . 1 5 )   { 
 
 	 	 q u a k e C a m 2 D ( 3 , 4 5 ) ;   q u a k e C a m 3 D ( 3 , 4 5 ) ; 
 
 	 	 f a k e L a s e r S h o t ( b o s s X + 2 4 , b o s s Y - 3 2 , d i r + r a n d _ i n t ( - 6 4 , 6 4 ) , 6 0 ) ; 
 
 	 	 w a i t ( 1 3 ) ; 
 
 	 } 	 
 
 	 w a i t ( 3 0 ) ; 
 
 	 b o s s A t t a c k   =   0 ; 	 
 
 } 
 
 
 
 / /   I n v i s i b l e   l a s e r   
 
 t a s k   f a k e L a s e r S h o t ( x , y , d i r , d e l a y )   {   
 
 	 l e t   o b j   =   O b j S h o t _ C r e a t e ( O B J _ S T R A I G H T _ L A S E R ) ; 
 
 
 
 	 O b j S h o t _ R e g i s t ( o b j ) ; 
 
 	 O b j S h o t _ S e t G r a p h i c ( o b j , 1 ) ; 
 
 	 O b j R e n d e r _ S e t A l p h a ( o b j , 2 5 5 ) ; 
 
 	 O b j M o v e _ S e t P o s i t i o n ( o b j , x , y ) ; 
 
 	 O b j S t L a s e r _ S e t A n g l e ( o b j , d i r ) ; 
 
 	 O b j L a s e r _ S e t L e n g t h ( o b j , 5 1 2 ) ; 
 
 	 O b j L a s e r _ S e t R e n d e r W i d t h ( o b j , 3 2 ) ; 
 
 	 O b j L a s e r _ S e t I n t e r s e c t i o n W i d t h ( o b j , 3 2 ) ; 	 
 
 	 O b j S h o t _ S e t D e l a y ( o b j , 6 0 ) ; 	 
 
 	 O b j S h o t _ S e t S p e l l R e s i s t ( o b j , f a l s e ) ; 	 
 
 	 O b j S h o t _ S e t D e l e t e F r a m e ( o b j , d e l a y - 1 5 ) ; 
 
 	 w a i t ( d e l a y ) ; 
 
 	 P l a y S F X ( S F X _ G U N 0 0 ) ; 
 
 	 s c a t t e r M a s t e r S p a r k L a s e r E x ( x , y , d i r ) ; 
 
 } 
 
 
 
 t a s k   f a k e L a s e r S h o t 2 ( x , y , d i r , d e l a y )   {   
 
 	 l e t   o b j   =   O b j S h o t _ C r e a t e ( O B J _ S T R A I G H T _ L A S E R ) ; 
 
 
 
 	 O b j S h o t _ R e g i s t ( o b j ) ; 
 
 	 O b j S h o t _ S e t G r a p h i c ( o b j , 1 ) ; 
 
 	 O b j R e n d e r _ S e t A l p h a ( o b j , 0 ) ; 
 
 	 O b j M o v e _ S e t P o s i t i o n ( o b j , x , y ) ; 
 
 	 O b j S t L a s e r _ S e t A n g l e ( o b j , d i r ) ; 
 
 	 O b j L a s e r _ S e t L e n g t h ( o b j , 5 1 2 ) ; 
 
 	 O b j L a s e r _ S e t R e n d e r W i d t h ( o b j , 7 2 ) ; 
 
 	 O b j L a s e r _ S e t I n t e r s e c t i o n W i d t h ( o b j , 6 4 ) ; 	 
 
 	 O b j S h o t _ S e t D e l a y ( o b j , 6 0 ) ; 	 
 
 	 O b j S h o t _ S e t S p e l l R e s i s t ( o b j , f a l s e ) ; 	 
 
 	 O b j S h o t _ S e t D e l e t e F r a m e ( o b j , 6 0 ) ; 
 
 	 w a i t ( d e l a y ) ; 
 
 	 P l a y S F X ( S F X _ G U N 0 0 ) ; 
 
 	 s c a t t e r M a s t e r S p a r k L a s e r E x 2 ( x , y , d i r ) ; 
 
 } 
 
 
 
 / /   M a r i s a ' s   s p e l l   c a r d   a t t a c k 
 
 t a s k   s c a t t e r M a s t e r S p a r k L a s e r E x ( x , y , d i r )   { 
 
 	 l e t   o b j   =   O b j P r i m _ C r e a t e ( O B J _ P R I M I T I V E _ 2 D ) ; 
 
 	 
 
 	 l e t   a l p h a V a l u e   =   2 5 0 ; 
 
 	 l e t   f o l d   =   3 2 ; 
 
 	 
 
 	 / /   A n i m   l a s e r 
 
 	 O b j P r i m _ S e t V e r t e x C o u n t ( o b j , 4 ) ; 
 
 	 O b j P r i m _ S e t P r i m i t i v e T y p e ( o b j , P R I M I T I V E _ T R I A N G L E S T R I P ) ; 
 
 	 O b j R e n d e r _ S e t P o s i t i o n ( o b j , x , y , 0 ) ; 
 
 	 O b j P r i m _ S e t T e x t u r e ( o b j , m s p a r k T e x ) ; 
 
 	 O b j R e n d e r _ S e t B l e n d T y p e ( o b j , B L E N D _ A D D _ A R G B ) ; 
 
 	 O b j _ S e t R e n d e r P r i o r i t y I ( o b j , 4 0 ) ; 
 
 	 O b j R e n d e r _ S e t P o s i t i o n ( o b j , x , y , 0 ) ; 
 
 	 O b j R e n d e r _ S e t A n g l e Z ( o b j , d i r ) ; 
 
 	 O b j R e n d e r _ S e t S c a l e X Y Z ( o b j , 2 , 2 , 0 ) ; 
 
 	 O b j S p r i t e 2 D _ S e t S o u r c e R e c t ( o b j , 1 , 1 , 2 5 6 , 1 2 8 ) ; 
 
 	 O b j S p r i t e 2 D _ S e t D e s t R e c t ( o b j , 1 6 , - 3 2 , 2 5 6 , 3 2 ) ; 
 
 
 
 	 c o l o r M i x e r ( o b j , a l p h a V a l u e , 2 5 5 , 2 5 5 , 2 5 5 ) ; 
 
 
 
 	 w h i l e ( ! O b j _ I s D e l e t e d ( b o s s O b j ) )   { 
 
 	 	 O b j P r i m _ S e t V e r t e x P o s i t i o n ( o b j ,   0 ,   0 ,   - f o l d , 0 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x U V T ( o b j ,   0 ,   1 ,   1 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x P o s i t i o n ( o b j ,   1 ,   4 0 0 ,   - f o l d , 0 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x U V T ( o b j ,   1 ,   2 5 6 ,   1 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x P o s i t i o n ( o b j ,   2 ,   0 ,   f o l d , 0 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x U V T ( o b j ,   2 ,   1 ,   1 2 8 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x P o s i t i o n ( o b j ,   3 ,   4 0 0 ,   f o l d , 0 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x U V T ( o b j ,   3 ,   2 5 6 ,   1 2 8 ) ; 
 
 
 
 	 	 f o l d - = 0 . 5 ; 
 
 	 	 i f ( f o l d   <   0 )   {   O b j _ D e l e t e ( o b j ) ;   b r e a k ;   } 
 
 	 	 y i e l d ; 
 
 	 } 
 
 	 O b j _ D e l e t e ( o b j ) ; 
 
 } 
 
 
 
 t a s k   s c a t t e r M a s t e r S p a r k L a s e r E x 2 ( x , y , d i r )   { 
 
 	 l e t   o b j   =   O b j P r i m _ C r e a t e ( O B J _ P R I M I T I V E _ 2 D ) ; 
 
 	 
 
 	 l e t   a l p h a V a l u e   =   2 5 0 ; 
 
 	 l e t   f o l d   =   6 4 ; 
 
 	 
 
 	 / /   A n i m   l a s e r 
 
 	 O b j P r i m _ S e t V e r t e x C o u n t ( o b j , 4 ) ; 
 
 	 O b j P r i m _ S e t P r i m i t i v e T y p e ( o b j , P R I M I T I V E _ T R I A N G L E S T R I P ) ; 
 
 	 O b j R e n d e r _ S e t P o s i t i o n ( o b j , x , y , 0 ) ; 
 
 	 O b j P r i m _ S e t T e x t u r e ( o b j , m s p a r k T e x ) ; 
 
 	 O b j R e n d e r _ S e t B l e n d T y p e ( o b j , B L E N D _ A D D _ A R G B ) ; 
 
 	 O b j _ S e t R e n d e r P r i o r i t y I ( o b j , 4 0 ) ; 
 
 	 O b j R e n d e r _ S e t P o s i t i o n ( o b j , x , y , 0 ) ; 
 
 	 O b j R e n d e r _ S e t A n g l e Z ( o b j , d i r ) ; 
 
 	 O b j R e n d e r _ S e t S c a l e X Y Z ( o b j , 2 , 2 , 0 ) ; 
 
 	 O b j S p r i t e 2 D _ S e t S o u r c e R e c t ( o b j , 1 , 1 , 2 5 6 , 1 2 8 ) ; 
 
 	 O b j S p r i t e 2 D _ S e t D e s t R e c t ( o b j , 1 6 , - 3 2 , 2 5 6 , 3 2 ) ; 
 
 
 
 	 c o l o r M i x e r ( o b j , a l p h a V a l u e , 2 5 5 , 2 5 5 , 2 5 5 ) ; 
 
 
 
 	 w h i l e ( ! O b j _ I s D e l e t e d ( b o s s O b j ) )   { 
 
 	 	 O b j P r i m _ S e t V e r t e x P o s i t i o n ( o b j ,   0 ,   0 ,   - f o l d , 0 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x U V T ( o b j ,   0 ,   1 ,   1 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x P o s i t i o n ( o b j ,   1 ,   4 0 0 ,   - f o l d , 0 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x U V T ( o b j ,   1 ,   2 5 6 ,   1 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x P o s i t i o n ( o b j ,   2 ,   0 ,   f o l d , 0 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x U V T ( o b j ,   2 ,   1 ,   1 2 8 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x P o s i t i o n ( o b j ,   3 ,   4 0 0 ,   f o l d , 0 ) ; 
 
 	 	 O b j P r i m _ S e t V e r t e x U V T ( o b j ,   3 ,   2 5 6 ,   1 2 8 ) ; 
 
 	 	 f o l d - = 0 . 5 ; 
 
 	 	 i f ( f o l d   = =   0 )   {   O b j _ D e l e t e ( o b j ) ;   } 
 
 	 	 y i e l d ; 
 
 	 } 
 
 } 
 
 
 
 / /   D o l l   o b j   ( f u n c t i o n   r e t u r n   i d ) 
 
 t a s k   s h a n g h a i D o l l ( x , y , d i r )   { 
 
 	 l e t   o b j   =   O b j P r i m _ C r e a t e ( O B J _ S P R I T E _ 2 D ) ; 
 
 	 l e t   r   =   0 ; 
 
 	 l e t   c   =   0 ; 
 
 	 
 
 	 l e t   c o l S e t   =   [ [ 2 5 5 ,   1 6 ,   1 6 ] , [ 1 6 , 2 5 5 , 1 6 ] , [ 1 6 , 1 6 , 2 5 5 ] , [ 1 6 , 2 5 5 , 2 5 5 ] , [ 2 5 5 , 1 6 , 2 5 5 ] , [ 2 5 5 , 2 5 5 , 1 6 ] , [ 2 5 5 , 1 2 8 , 1 6 ] ] ; 
 
 	 l e t   c o l K i e s   =   0 ; 	 
 
 	 
 
 	 O b j P r i m _ S e t T e x t u r e ( o b j , m s p a r k T e x ) ; 
 
 	 O b j R e n d e r _ S e t B l e n d T y p e ( o b j , B L E N D _ A L P H A ) ; 
 
 	 O b j R e n d e r _ S e t A l p h a ( o b j , 2 5 5 ) ; 
 
 	 O b j _ S e t R e n d e r P r i o r i t y I ( o b j , 4 0 ) ; 
 
 	 O b j R e n d e r _ S e t A n g l e Z ( o b j , 0 ) ; 
 
 	 O b j R e n d e r _ S e t S c a l e X Y Z ( o b j , 1 , 1 , 0 ) ; 	 
 
 	 O b j S p r i t e 2 D _ S e t S o u r c e R e c t ( o b j , 0 , 2 0 8 , 3 3 , 2 5 5 ) ; 
 
 	 O b j S p r i t e 2 D _ S e t D e s t C e n t e r ( o b j ) ; 
 
 	 O b j R e n d e r _ S e t P o s i t i o n ( o b j , x , y , 0 ) ; 
 
 	 
 
 	 d o l l A n i m ( o b j , d i r ) ; 
 
 	 m a g i c C i r c l e M i n i E x ( o b j ) ; 
 
 	 s h a n g h a i F i r e ( o b j ) ; 
 
 	 
 
 	 w h i l e ( ! O b j _ I s D e l e t e d ( o b j ) )   { 
 
 	 	 i f ( r   <   6 4 )   {   r + + ;   }   
 
 	 	 O b j R e n d e r _ S e t P o s i t i o n ( o b j , b o s s 2 X + r * c o s ( d i r ) , b o s s 2 Y + r * s i n ( d i r ) , 0 ) ; 
 
 	 	 i f ( t o s s )   {   r + + ;   c + + ;   }   
 
 	 	 
 
 	 	 / /   b o e m 
 
 	 	 i f ( c   = =   1 0 0 )   {   
 
 	 	 	 P l a y S F X ( S F X _ S H A N G H A I B O O M ) ;   
 
 	 	 	 c o l o r M i x e r ( o b j , 2 5 5 , 2 5 5 , 2 5 5 , 2 5 5 ) ;   
 
 	 	 	 c o n c e n E f f e c t ( o b j , 5 , 4 , 2 5 5 , 2 5 5 , 6 4 ) ; 
 
 	 	 	 c o n c e n E f f e c t ( o b j , 5 , 4 , 6 4 , 6 4 , 2 5 5 ) ; 	 	 	 
 
 	 	 } 
 
 	 	 i f ( c   = =   1 2 0 )   {   
 
 	 	 	 P l a y S F X ( S F X _ E X P L 0 0 ) ; 
 
 	 	 	 q u a k e C a m 2 D ( 2 , 3 0 ) ; 
 
 	 	 	 q u a k e C a m 3 D ( 1 , 3 0 ) ; 
 
 	 	 	 a s c e n t ( i   i n   0 . . 8 )   { 
 
 	 	 	 	 c o l K i e s   =   r a n d _ i n t ( 0 , 7 ) ; 
 
 	 	 	 	 b r e a k E f f e c t G l i t t e r ( O b j R e n d e r _ G e t X ( o b j ) , O b j R e n d e r _ G e t Y ( o b j ) , r a n d ( 1 , 3 ) , r a n d _ i n t ( 0 , 3 6 0 ) , 5 , 2 5 5 , c o l S e t [ c o l K i e s ] [ 0 ] , c o l S e t [ c o l K i e s ] [ 1 ] , c o l S e t [ c o l K i e s ] [ 2 ] ) ; 
 
 	 	 	 } 	 
 
 	 	 	 d i r   =   G e t P o i n t T o P o i n t A n g l e ( G e t P l a y e r X , G e t P l a y e r Y , O b j R e n d e r _ G e t X ( o b j ) , O b j R e n d e r _ G e t Y ( o b j ) ) ; 
 
 	 	 	 a s c e n t ( j   i n   0 . . 5 )   {   
 
 	 	 	 	 C r e a t e S h o t A 1 ( O b j R e n d e r _ G e t X ( o b j ) , O b j R e n d e r _ G e t Y ( o b j ) , 2 , d i r , r a n d _ i n t ( 2 3 0 , 2 3 4 ) , 0 ) ; 
 
 	 	 	 	 d i r + = 3 6 0 / 5 ; 
 
 	 	 	 } 
 
 	 	 	 O b j _ D e l e t e ( o b j ) ;   b r e a k ; 
 
 	 	 } 
 
 	 	 y i e l d ; 
 
 	 } 
 
 } 
 
 
 
 / /   S h a n g h a i   f i r e 
 
 t a s k   s h a n g h a i F i r e ( o b j )   { 
 
 	 w a i t ( 9 0 ) ; 
 
 	 l e t   d i r   =   0 ; 
 
 	 a s c e n t ( i   i n   0 . . 4 0 )   {   
 
 	 	 P l a y S F X ( S F X _ T A N 0 0 ) ; 
 
 	 	 C r e a t e S h o t A 2 ( O b j R e n d e r _ G e t X ( o b j ) , O b j R e n d e r _ G e t Y ( o b j ) , 0 . 5 , d i r + 9 0 , 0 . 0 2 , 3 , 5 6 , 5 ) ; 
 
 	 	 C r e a t e S h o t A 2 ( O b j R e n d e r _ G e t X ( o b j ) , O b j R e n d e r _ G e t Y ( o b j ) , 0 . 5 , - d i r + 9 0 , 0 . 0 2 , 3 , 5 6 , 5 ) ; 
 
 	 	 d i r + = 3 6 0 / 2 3 ; 
 
 	 	 w a i t ( 2 ) ; 
 
 	 } 
 
 } 
 
 
 
 / /   D o l l   a n i m a t i o n 
 
 t a s k   d o l l A n i m ( o b j , d i r )   { 
 
 	 l e t   a n i m L   =   0 ; 
 
 	 w h i l e ( ! O b j _ I s D e l e t e d ( o b j ) )   { 
 
 	 	 O b j S p r i t e 2 D _ S e t S o u r c e R e c t ( o b j , 0 + a n i m L , 2 0 8 , 3 3 + a n i m L , 2 5 5 ) ; 
 
 	 	 a n i m L + = 3 2 ; 
 
 	 	 i f ( a n i m L   = =   2 5 6 )   {   a n i m L   =   1 6 0 ;   }   
 
 	 	 w a i t ( 1 0 ) ; 
 
 	 } 
 
 } 
 
 
 
 
 
 / /   S p i n n i n g   s t a r   i m a g e   u n d e r   s h a n g h a i   d o l l s .   S t a t i c . 
 
 t a s k   m a g i c C i r c l e M i n i E x ( o b j )   { 
 
 	 l e t   o b j 2   =   O b j P r i m _ C r e a t e ( O B J _ S P R I T E _ 2 D ) ; 
 
 	 l e t   c i r c S p i n   =   0 ; 
 
 
 
 	 O b j P r i m _ S e t T e x t u r e ( o b j 2 , m s p a r k T e x ) ; 
 
 	 O b j R e n d e r _ S e t B l e n d T y p e ( o b j 2 , B L E N D _ A D D _ A R G B ) ; 
 
 	 O b j _ S e t R e n d e r P r i o r i t y I ( o b j 2 , 2 0 ) ; 
 
 	 O b j R e n d e r _ S e t S c a l e X Y Z ( o b j 2 , 1 , 1 , 0 ) ; 
 
 	 O b j S p r i t e 2 D _ S e t S o u r c e R e c t ( o b j 2 , 0 , 1 3 6 , 6 8 , 2 0 4 ) ; 
 
 	 O b j S p r i t e 2 D _ S e t D e s t C e n t e r ( o b j 2 ) ; 
 
 
 
 	 c o l o r M i x e r ( o b j 2 , 2 5 5 , 2 5 5 , 2 5 5 , 2 5 5 ) ; 
 
 
 
 	 w h i l e ( ! O b j _ I s D e l e t e d ( o b j ) )   { 
 
 	 	 O b j R e n d e r _ S e t P o s i t i o n ( o b j 2 , O b j R e n d e r _ G e t X ( o b j ) , O b j R e n d e r _ G e t Y ( o b j ) , 0 ) ; 
 
 	 	 O b j R e n d e r _ S e t A n g l e Z ( o b j 2 , c i r c S p i n ) ; 
 
 	 	 c i r c S p i n + = 5 ; 
 
 	 	 y i e l d ; 
 
 	 } 
 
 	 O b j _ D e l e t e ( o b j 2 ) ; 
 
 } 
 
 
 
 
 
 t a s k   s c r i p t E n d i n g   { 
 
 	 w h i l e ( O b j E n e m y _ G e t I n f o ( b o s s O b j ,   I N F O _ L I F E )   >   0 )   { 
 
 	 	 y i e l d ; 
 
 	 } 
 
 
 
 	 D e l e t e S h o t A l l ( T Y P E _ A L L ,   T Y P E _ I T E M ) ; 
 
 	 O b j _ D e l e t e ( b o s s O b j ) ; 
 
 
 
 	 C l o s e S c r i p t ( G e t O w n S c r i p t I D ( ) ) ; 
 
 } 
 
   