skiper = false;

function ActionsJump ()
   if frame==4 then
    speciale_action(2,1100);
  end;
  temno = false;
  DarkScreen1(true);     
end;

function WasTimer()
end;

function gameinput (sender,obj_id,attachedID)
Block_Show_Cur(false);

-----------------------------------------------------------------------------------------------------------------------
    
    if sender == 100 then
      if skiper then
        neighbors.street.lock=false;  
    LoadLocation("street");    
        flags.comics_run=false;
 
        -- fromcomics3=true        
        -- flags.is_comics=false    
        -- StopTimer(12542)
        -- PlayMusic()
        neighbors.comics.lock=true; 
        flags.is_comics=false    
        skip_comics=false
    startgame=true
    windowtutorial=true
        jump("comics","kabinet",0,0)
        flags.hint_cur=true;
      return; end;
    WriteToConsole("scaling \n")
      if frame == -2 then
        speciale_action(2,1);
        speciale_action(2,11);
        temno = true;
        DarkScreen1(false); 
        Block_Show_Cur(false);
    setcolor(1100,1,1,1,1,1); 
	set_text(1100,"184");
        ScaleObject(11,1.7,1,time_scaling,1030,0);
        AlternateTimer("ActionsJump",(time_scaling-2)*1000)
      return; end;    
      if frame == -1 then
        speciale_action(2,11);
        speciale_action(2,12);
        temno = true;
        DarkScreen1(false); 
        Block_Show_Cur(false);
        set_text(1100,"185");
    MoveObjectX(12,0,-200,time_scaling)
       -- ScaleObject(11,2.3,1,time_scaling,766,384);
        AlternateTimer("ActionsJump",(time_scaling-2)*1000)
      return; end;      
      if frame == 0 then
        speciale_action(2,12);
        speciale_action(2,2);
        temno = true;
        DarkScreen1(false); 
        Block_Show_Cur(false);
        set_text(1100,"186");
        ScaleObject(2,1.7,1,time_scaling,766,384);
        AlternateTimer("ActionsJump",(time_scaling-2)*1000)
      return; end;
      if frame == 1 then
        speciale_action(2,2);      
        speciale_action(2,8);
        temno = true;
        DarkScreen1(false);    
        Block_Show_Cur(false);
        playeffect("shoot")
        set_text(1100,"187");
        ScaleObject(8,1,1.7,time_scaling,900,100);
        AlternateTimer("ActionsJump",(time_scaling-2)*1000) 
      return end;
      if frame == 2 then
        speciale_action(2,8);
        speciale_action(2,3);
        
        temno = true;
        DarkScreen1(false);    
        Block_Show_Cur(false);
        set_text(1100,"987");
        ScaleObject(3,1.7,1,time_scaling,600,566);
        AlternateTimer("ActionsJump",(time_scaling-2)*1000)    
      return; end;
      if frame >= 3 then
        -- speciale_action(2,3);
        -- speciale_action(2,4);
        -- temno = true;
        -- DarkScreen1(false);    
        -- Block_Show_Cur(false);
        -- set_text(1100,"187");
        -- ScaleObject(4,1,2.3,time_scaling,421,340);
        -- StartTimer(8881,time_scaling-2);
      -- return; end;
      -- if frame == 4 then
        -- speciale_action(2,4);
        -- speciale_action(2,5);
        -- temno = true;
        -- DarkScreen1(false);    
        -- Block_Show_Cur(false);

        -- setcolor(1100,0,0,0,1,1); 
        -- ScaleObject(5,1.5,1,time_scaling,482,200);
        -- StartTimer(8881,time_scaling-2);
      -- return; end;
      -- if frame >= 5 then
        skiper=true
        Block_Show_Cur(true)
        WaitRender()
      return; end;      
    return; end;
    
    if sender == 33 then 
      --if obj_id~=8777778 then
        
          if not skiper then
          end;
          if ztm then
            ztm = false;
          return; end;
          if skiper then
            WaitRender();
          return; end;      
         if not temno then
      WriteToConsole("delete and load \n")
            frame=frame+1
            if frame == -2 then
                del_object_from_game(1)
                DeleteResource("com1cadr1_7" );    
        loadresource("data\\0\\50\\2\\0003.jpg","com1cadr2_4",3 );
        addstaticobjecttogame(11,"com1cadr2_4",0  ,0  ,""); --фон
                speciale_action(2,11);
            end;    
            if frame == -1 then
                del_object_from_game(11)
                DeleteResource("com1cadr2_4" );    
        loadresource("data\\0\\50\\3\\1.jpg","com3cadr1",3 );
        addstaticobjecttogame(12,"com3cadr1",-100 ,-150  ,""); --фон
                speciale_action(2,12);
            end;      
            if frame == 0 then
                del_object_from_game(12)
                DeleteResource("com3cadr1" );    
                loadresource("data\\0\\50\\5\\1.jpg","com1cadr2_5",3 );
                addstaticobjecttogame(2,"com1cadr2_5",0  ,0  ,""); --кадр2
                speciale_action(2,2);
            end;
            if frame == 1 then
            del_object_from_game(2)
                DeleteResource("com1cadr2_5" );    
                loadresource("data\\0\\50\\6\\1.jpg","com1cadr2_6",3 );
                addstaticobjecttogame(8,"com1cadr2_6",0  ,0  ,""); --кадр3
                speciale_action(2,8);            
            end;
            if frame == 2 then
            del_object_from_game(8)
                DeleteResource("com1cadr2_6" );    
                loadresource("data\\0\\50\\7\\1.jpg","com1cadr2_7",3 );
                addstaticobjecttogame(3,"com1cadr2_7",0  ,100  ,""); --кадр3
                speciale_action(2,3);
            end;            
            if frame == 3 then
            del_object_from_game(3)
                DeleteResource("com1cadr2_7" );    
            end;
            -- if frame == 4 then
            -- del_object_from_game(4)
                -- DeleteResource("com3cadr4" );    
                -- loadresource("data\\1\\50\\5.jpg","com3cadr5",1)
                -- addstaticobjecttogame(5,"com3cadr5",0  ,0  ,""); --кадр5
                -- speciale_action(2,5);
            -- end;            
            WaitRender();
     --    return; end;    
      return;end;
    return;end;
---------------------------------------------------------------------------------------------------------------    
    if sender==28 then---- объект доехал

    return;end;    
    
    if sender==36 then
        if obj_id==8881 then
            if frame==4 then
                speciale_action(2,1100);
            end;
            temno = false;
            DarkScreen1(true);            
        return;end;
    return;end;
    
---------------------------------------------------------------------------------------------------------------
    if sender==29 then -- отработал скейл
     
    return; end;
    
    if sender == 1 then --кликнули левой кнопкой мыши на активный объект
      if obj_id == 6 then
        skiper = true;
        Block_Show_Cur(true)
        DarkScreen1(true);
      return; end;
    return;end;

    
    if sender == 6 then    
      Block_Show_Cur(true)
      DarkScreen1(true); temno = false;
      
    return; end;
end
function SheetSwitched(nCount)
end;