home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Sverigejakten
/
sverigejakten.iso
/
SUCCESS.DIR
/
00039_Script_f_highscore
< prev
next >
Wrap
Text File
|
2003-08-12
|
2KB
|
55 lines
on exitFrame
set exit=0
set temp_mousedown=the mousedown
repeat while rollover (22)=1
set the forecolor of member "done"=255
if temp_mousedown < the mousedown then set temp_mousedown=1
if temp_mousedown > the mousedown then
global movie_time
global crimeno
global level
set crimes=crimeno
set temp_time=(movie_time)
set hours = (temp_time/60)
set minutes=abs(temp_time-(hours*60))
set temp_value=(crimes*2)+hours+(6*(3-level))
set points=((10-crimes)*350) + (4000-movie_time) + (600*level)
set title=9
if temp_value<45 then set title=9
if temp_value<40 then set title=8
if temp_value<35 then set title=7
if temp_value<30 then set title=6
if temp_value<25 then set title=5
if temp_value<20 then set title=4
if temp_value<16 then set title=3
if temp_value<11 then set title=2
if temp_value<7 then set title=1
set temp_text=the text of member "highscore" of castlib "savegame"
set temp_counter=12
repeat while temp_counter>0
put line temp_counter of temp_text into line (temp_counter+1) of temp_text
if points < value (item 3 of line (temp_counter-1) of temp_text) or temp_counter=1 then
set temp_text2=line 1 of the text of member "name"
put item 1 of temp_text2 into item 1 of line temp_counter of temp_text
put line title of the text of member "titles" into item 2 of line temp_counter of temp_text
put points into item 3 of line temp_counter of temp_text
set temp_counter=-1
end if
set temp_counter=temp_counter-1
end repeat
set the text of member "highscore" of castlib "savegame" = temp_text
save castlib "savegame"
set exit=1
exit repeat
end if
end repeat
set the forecolor of member "done"=130
if exit=0 then go to the frame
else go to "list"
end