// This file was decompiled using VCSCM.ini published on 2021-01-30
{$CLEO .cs}

03A4: script_name 'SWIM' 
   
0006: 10@ = 0 // @ = int         
0006: 11@ = 0 // @ = int
:SWIM_10
0001: wait 0 ms  



00D6: if 
0256:   player $PLAYER_CHAR defined   
then
04D8: set_actor $PLAYER_ACTOR drown 1     
end     
00D6: if 
0039:   10@ == 1 // @ == int
then 
0372: set_actor $PLAYER_ACTOR anim 0 wait_state_time 10 ms
0006: 11@ = 0 // @ = int
018E: stop_sound 6@               
0006: 10@ = 0 // @ = int 
0001: wait 100 ms  

end

00D6: if and
0256:   player $PLAYER_CHAR defined 
80DF:   not actor $PLAYER_ACTOR in_any_car 
04AD:   actor $PLAYER_ACTOR in_water
8118:  not actor $PLAYER_ACTOR dead
004D: jump_if_false @SWIM_10 

04D8: set_actor $PLAYER_ACTOR drown 0
0006: 0@ = 0 // @ = int   

:SWIM_101  
000A: 0@ += 1 // @ += int

04C4: create_coordinate 1@ 2@ 3@ from_actor $player_actor offset 0.0 0.0 -1.0 


0494: get_joystick 0 data_to 12@ 7@ 8@ 9@
00D6: if or
001B:   0 > 7@ // int > @   
00E1:   player 0 pressed_button 8 
then  
    00D6: if    
    0039:   10@ == 0 // @ == int
    then          
        0006: 11@ = 0 // @ = int
        018D: 6@ = create_sound 51 at 1@ 2@ 3@            
        0006: 10@ = 1 // @ = int
    end
    0437: scatter_particle 26 0.8 at 1@ 2@ 3@ 0.0 0.0 0.0 
    00D6: if    
    00E1:   player 0 pressed_button 16 
    then                        
    0437: scatter_particle 26 1.0 at 1@ 2@ 3@ 0.0 0.0 0.0 
    0437: scatter_particle 26 0.52 at 1@ 2@ 3@ 0.0 0.0 0.0 
    0437: scatter_particle 26 0.8 at 1@ 2@ 3@ 0.0 0.0 0.0 
    end
end


000A: 11@ += 1 // @ += int
 
00D6: if and 
0039:   11@ == 25 // @ == int  
0039:   10@ == 1 // @ == int
then  
0006: 11@ = 0 // @ = int
018E: stop_sound 6@               
0006: 10@ = 0 // @ = int
end

0170: 5@ = player $PLAYER_CHAR z_angle

0494: get_joystick 0 data_to 12@ 7@ 8@ 9@
00D6: if or
001B:   0 > 12@ // int > @   
00E1:   player 0 pressed_button 10 
then   
    000B: 5@ += 2.0 // @ += float
    0171: set_player $PLAYER_CHAR z_angle_to 5@
end   
00D6: if or  
0019:   12@ > 0 // @ > int 
00E1:   player 0 pressed_button 11 
then     
    000F: 5@ -= 2.0 // @ -= float
    0171: set_player $PLAYER_CHAR z_angle_to 5@
end
0001: wait 0 ms   


00D6: if and
0256:   player $PLAYER_CHAR defined 
80DF:   not actor $PLAYER_ACTOR in_any_car 
04AD:   actor $PLAYER_ACTOR in_water
8118:  not actor $PLAYER_ACTOR dead
004D: jump_if_false @SWIM_10 




00D6: if 
001B:   500 > 0@ // int > @
004D: jump_if_false @SWIM_10 

0002: jump @SWIM_101 


0002: jump @SWIM_10 
