home *** CD-ROM | disk | FTP | other *** search
- on enterFrame
- global g_memEntry, g_memlocH
- if (g_memEntry = 1) and (voidp(g_memlocH) = 0) then
- repeat with i = 0 down to g_memlocH
- set the locH of sprite 4 to i
- updateStage()
- set i to i + (g_memlocH / 20)
- end repeat
- set the locH of sprite 4 to g_memlocH
- updateStage()
- end if
- set g_memEntry to 0
- end
-
- on exitFrame
- global g_detect_zone, g_selected, gCurseurDoigt, gCurseurMainUp, gOwnPlayList, gStitchCast
- set gOwnPlayList to []
- set curcur to -1
- set pt to point(the mouseH, the mouseV)
- set orgx to the locH of sprite 4
- set orgy to the locV of sprite 4
- if the mouseCast = gStitchCast then
- set curcur to gCurseurMainUp
- repeat with i = 1 to 17
- set r to offset(getAt(g_detect_zone, i), orgx, orgy)
- if inside(pt, r) then
- set g_selected to i
- puppetSprite(9, 1)
- set the castNum of sprite 9 to member ("Titre_" & i & ".RTF")
- set the locH of sprite 9 to 17
- set the locV of sprite 9 to 40
- set curcur to gCurseurDoigt
- exit repeat
- end if
- end repeat
- if i > 17 then
- set g_selected to 0
- puppetSprite(9, 0)
- end if
- else
- set g_select to 0
- puppetSprite(9, 0)
- end if
- if rollOver(7) then
- set curcur to gCurseurDoigt
- end if
- if rollOver(8) then
- set curcur to gCurseurDoigt
- end if
- if rollOver(47) then
- set curcur to gCurseurMainUp
- end if
- cursor(curcur)
- go(the frame)
- end
-
- on mouseDown
- global g_selected, gCurseurFlecheDroite, gCurseurFlecheGauche, gCurseurMainDown, was_scrolling, gStitchCast
- if the mouseCast = gStitchCast then
- set was_scrolling to 1
- cursor(gCurseurMainDown)
- set orgx to the mouseH
- repeat while the mouseH = orgx
- if the mouseDown = 0 then
- exit
- end if
- end repeat
- set g_selected to 0
- repeat while the mouseDown = 1
- set x to the mouseH
- if x < orgx then
- rightscroll(orgx - x)
- cursor(gCurseurFlecheGauche)
- else
- if x > orgx then
- leftscroll(x - orgx)
- cursor(gCurseurFlecheDroite)
- else
- cursor(gCurseurMainDown)
- end if
- end if
- updateStage()
- end repeat
- else
- set was_scrolling to 0
- set g_selected to 0
- end if
- end
-
- on mouseUp
- global g_selected, gPathBoot, g_memlocH, was_scrolling, g_call_param, g_exit, g_next_movie
- set g_memlocH to the locH of sprite 4
- if g_selected <> 0 then
- put "clic oeuvre " && g_selected
- set g_call_param to -1
- set g_exit to 1
- puppetSprite(4, 0)
- if the machineType = 256 then
- set g_next_movie to gPathBoot & "jingles\" & numToChar(64 + g_selected)
- else
- set g_next_movie to gPathBoot & "jingles:" & numToChar(64 + g_selected)
- end if
- unpuppet()
- go("sortie")
- exit
- end if
- if was_scrolling = 0 then
- if rollOver(7) then
- set g_call_param to -1
- set g_exit to 1
- set g_next_movie to gPathBoot & "themes"
- unpuppet()
- go("sortie")
- exit
- end if
- if rollOver(8) then
- set g_call_param to -1
- set g_exit to 1
- set g_next_movie to gPathBoot & "visite"
- unpuppet()
- go("sortie")
- exit
- end if
- end if
- end
-
- on leftscroll speed
- set speed to speed / 5
- if (the right of sprite 4 - speed) < 541 then
- set speed to the right of sprite 4 - 541
- end if
- set xp to the locH of sprite 4
- set the locH of sprite 4 to xp - speed
- end
-
- on rightscroll speed
- set speed to speed / 5
- if (the locH of sprite 4 + speed) > 0 then
- set speed to -(the locH of sprite 4)
- end if
- set xp to the locH of sprite 4
- set the locH of sprite 4 to xp + speed
- end
-