flags.load_secret_room = true;

SetActivLeaf("secret_room");
Spirit_Particles()
AddObjForCur()

To_Mayor_Room={
122,184,
230,184,
230,435,
122,435
}

Pedestal={
605,381,
724,381,
724,535,
605,535
}

Secret_hole={
836,348,
902,348,
902,433,
836,433
}

Secret_pile={
809,469,
962,469,
962,618,
809,618
}

Flame={
376,234,
422,234,
422,367,
376,367
}

Poly_For_Flame={
2000,2000,
2001,2000,
2001,2001,
2000,2001
}

--addactivobjecttogame(40,"secret_room40" ,5000,5000,"","82"); --
CreatePolygon(34,4,"To_Mayor_Room")
speciale_action(2,34)
CreatePolygon(1012,4,"Poly_For_Flame")
CreatePolygon(1010,4,"Poly_For_Flame")
CreatePolygon(1011,4,"Poly_For_Flame")
CreatePolygon(11,4,"Poly_For_Flame")

addstaticobjecttogame(1 ,"secret_room0" ,0  ,0  ,""); --зтм
speciale_action(10,1);
NewObj("metla","metla" ,2000,2000,"146"); --метла
--if not obj.metla.is_collapsed then
NewObj("metal","secret_room_big" ,535,310,"146",413,148,45,196); --метла
--end;
addstaticobjecttogame(50,"secret_room_big",795,-100,"",0+295,0,30,34);
addstaticobjecttogame(51,"secret_room_big",889,-100,"",30+295,0,39,27);
addstaticobjecttogame(52,"secret_room_big",823,-100 ,"",69+295,0,35,21);
addstaticobjecttogame(53,"secret_room_big",858,-100 ,"",0+295,34,40,114);
addstaticobjecttogame(54,"secret_room_big",798,-100 ,"",43+295,34,61,106);


addstaticobjecttogame(6 ,"secret_room_big" ,589,409,"",154,391,132,58); --паутина

CreatePolygon(39,4,"Secret_hole")


addstaticobjecttogame(8 ,"secret_room_big" ,587,408,"",295,148,118,63); --книга
speciale_action(10,6)
speciale_action(10,8)


CreatePolygon(14,4,"Flame")
CreatePolygon(9,4,"Pedestal")



addstaticobjecttogame(29,"secret_room_big",841,422,"",363,391,22,17); --свеча
speciale_action(2,29);



addstaticobjecttogame(32,"secret_room_big",207,169,"",154,0,141,391); --картина рядом
speciale_action(2,32);
addactivobjecttogame(33,"secret_room_big",102,159,"","",0,0,0,0,154,427); --картина на проходе


CreatePolygon(35,4,"Secret_pile")


addactivobjecttogame(36,"secret_room_big",428,267,"","",0,0,286,391,77,78); --выпуклость



addstaticobjecttogame(38,"secret_room11",0  ,0  ,""); --бг,;

addfade(501,0);

pautinka=false
portrait=false
svecka=false

if flags.pjatnashki then --------------------------------------------------------
  speciale_action(2,36);
  speciale_action(2,1);
  speciale_action(2,16);
  speciale_action(2,19);
  speciale_action(2,22);
  speciale_action(2,25);
end;

if flags.pautina_loc then
  pautinka=true;
  speciale_action(2,6);
end;

if flags.portr_loc then
    portrait=true;
    speciale_action(2,8);
end;

if flags.cvecha_main then
    svecka=true;
    speciale_action(2,29); 
end;

if flags.fakel then
  ActivateObject(14,false);
end;


if flags.nisha then
  speciale_action(2,39);
  if not svecka then
  svecka=true;
  speciale_action(2,29);
  end;
end;

if flags.portret_mini then
  speciale_action(2,32);
  speciale_action(2,33);
speciale_action(2,34)  
end;



if flags.secret_book then
    speciale_action(2,9);
  flags.help_secret_book = true;
  if not pautinka then
  pautinka=true;
  speciale_action(2,6);
  end;
  if not portrait then
  portrait=true;
  speciale_action(2,8);
  end;

end;



