11
« on: May 27, 2014, 12:28:27 AM »
С 28 строки начинается этот цикл, но на 6 итерацию уходит на sub(voskres). Почему на 6-ой?
Сори за длинный код.
$summ_glav=38
$count_glav=1
$day=1
$glava=22
$shet_glava=1
$chast=2
$shet_chast=1
$chast_dva=1
$abzac=1
$shet_abzac=1
$abzac_dva=3
$abzac_tri=4
$abzac_chetyr=3
$abzac_pyat=14
$screen=0
while($screen<1)
getscreen
IF_PICTURE_IN(0,0,$_xmax,$_ymax, "day1.bmp")
$screen=1
$xtemp=$_return1+10
$xday=$_return1+10 //1
$yday=$_return2+10 //1
END_IF
gosub(budni)
end_cyc
sub(budni)
for($day, $day<8)
if($count_glav=38)
traysay("Все главы записаны!")
halt
end_if
if($day=7)
$day=1
gosub(voskres)
end_if
dblclick($xday,$yday) // on day
$xday=$xday+23
wait(3)
vvod:
if((shet_glava=29)|(shet_glava=30)|(shet_glava=31)|(shet_glava=32)|(shet_glava=33)|(shet_glava=34)|(shet_glava=35)|(shet_glava=36)|(shet_glava=37)|(shet_glava=38))
inc($chast)
KEYSTRING($glava, 100)
keypress(190) // .
keystring($chast)
goto(no_abzac)
end_if
if((shet_glava=25)|(shet_glava=26)|(shet_glava=27)|(shet_glava=28))
inc($chast)
KEYSTRING($glava, 100)
keypress(190) // .
keystring($chast)
goto(no_abzac)
end_if
KEYSTRING($glava, 100)
keypress(190) // .
keystring($chast)
keypress(190) // .
keypress($abzac)
inc(abzac)
wait(1)
no_abzac:
KEYSTRING(" Харви", 100)
wait(1)
keypress(#enter)
wait(3)
if($shet_glava=28) //perehod na 23 glavu
inc($glava)
end_if
if($shet_glava=3) //22.3.1
inc(chast)
$abzac=1
end_if
if($shet_glava=7) //22.4.1
inc(chast)
$abzac=1
end_if
if($shet_glava=10) //22.5.1
inc(chast)
$abzac=1
end_if
$count_glav=$count_glav+1
inc($shet_glava)
end_cyc
end_sub
sub(voskres)
rclick($xday,$yday)
wait(2)
getscreen
IF_PICTURE_IN(0,0,$_xmax,$_ymax, "new_event.bmp")
lclick($_return1,$_return2)
END_IF
wait(3)
$xday=$xtemp
$yday=$yday+23
goto(vvod)
end_sub