home *** CD-ROM | disk | FTP | other *** search
- global glang, gDel, tabsprites, gtabCode, gtabActive, regPoints, gsubtxt, gchosenTab, closePoints, gfirstTime, pdfFolderRoot, acobatPath
-
- on prepareMovie
- BuddyReg = baRegister("North Creative", 3705836)
- dropZones = []
- if voidp(glang) then
- glang = "pol"
- end if
- gDel = the last char in the pathname
- castLib("text").fileName = the pathname & "langs" & gDel & glang & ".cst"
- member("trailer").fileName = the pathname & "mov" & gDel & glang & "-trailer.mov"
- tabsprites = [38, 36, 34, 32, 30, 28]
- gtabActive = 0
- gtabCode = EMPTY
- submenutext()
- acobatPath = baFindApp(".pdf")
- pdfFolderRoot = moveUpDirectory(the pathname, 1, "PDFs")
- end
-
- on buttonClick but
- case but of
- "skip":
- go(#next)
- "enter":
- gfirstTime = 0
- go(#next)
- "quit":
- go("exit")
- end case
- end
-
- on tabButtonOver code
- spNum = tabsprites[code]
- if (gtabActive = 0) or (gtabActive = spNum) then
- gtabCode = code
- sprite(spNum + 1).ink = 35
- cursor(280)
- end if
- end
-
- on tabButtonOut code
- spNum = tabsprites[code]
- if (gtabActive = 0) or (gtabActive = spNum) then
- cursor(0)
- gtabCode = EMPTY
- end if
- sprite(spNum + 1).ink = [8, 35][1 + (gtabActive = spNum)]
- end
-
- on tabSelect
- if gtabCode <> EMPTY then
- if (gtabActive = 0) or (gtabActive = tabsprites[gtabCode]) then
- gchosenTab = gtabCode
- gtabActive = tabsprites[gchosenTab]
- dropheight = count(gsubtxt[gchosenTab]) * 2.14290000000000003
- put dropheight
- sendAllSprites(#dropDown, gtabActive, dropheight)
- end if
- end if
- end
-
- on queSounds
- soundList = ["hit1", "hit2", "hit3", "hit4", "menuSound", "navslide"]
- repeat with x = 1 to count(soundList)
- sound(x).queue([#member: member(soundList[x])])
- end repeat
- end
-
- on tabClosed
- gtabActive = 0
- end
-
- on closetab
- sprite(gtabActive + 1).ink = 8
- sendAllSprites(#dropDown, gtabActive, 17)
- end
-
- on showSubmenu
- itemCount = count(gsubtxt[gchosenTab])
- mcLoc = sprite(gtabActive).getVariable("mytextreg", 1)
- textReg = point(sprite(gtabActive).left + item 1 of mcLoc, sprite(gtabActive).top + item 2 of mcLoc)
- repeat with x = 1 to itemCount
- sendSprite(40 + x, #itemSetUp, gsubtxt[gchosenTab][x])
- sprite(40 + x).loc = textReg + point(0, 19 * (x - 1))
- end repeat
- mcLoc = sprite(gtabActive).getVariable("myclosereg", 1)
- sprite(50).loc = point(sprite(gtabActive).left + item 1 of mcLoc, sprite(gtabActive).top + item 2 of mcLoc + 10)
- end
-
- on hideSubmenu
- repeat with x = 1 to 8
- sprite(40 + x).loc = point(79, -200)
- end repeat
- sprite(50).loc = point(79, -200)
- end
-
- on submenuSelect id
- case gchosenTab of
- "1", "2", "3":
- play movie ["assembly", "circuits", "programme"][gchosenTab]
- "4":
- go("pause")
- openPDF(["Worksheet1.pdf", "Worksheet2.pdf", "Worksheet3.pdf", "Worksheet4.pdf", "Worksheet5.pdf", "Worksheet6.pdf", "Worksheet7.pdf", "Worksheet8.pdf"][id])
- "5":
- case id of
- "1":
- play movie "pairs"
- "2":
- gtabActive = 0
- go("trailer")
- "3":
- gotoNetPage("http://www.robotsmovie.com")
- "4":
- openIntaller()
- end case
- "6":
- go("pause")
- openPDF(["Synopsis.pdf", "CurrLinks.pdf"][id])
- end case
- end
-
- on openIntaller
- BuddyReg = baRegister("North Creative", 3705836)
- intallerpath = moveUpDirectory(the pathname, 1, EMPTY)
- file = intallerpath & "autorun.inf"
- FileOK = baFileExists(file)
- if FileOK then
- play movie intallerpath & "installer"
- else
- alert("Please install from the original ROBOTS CD ROM")
- end if
- end
-
- on openPDF whichfile
- open(pdfFolderRoot & whichfile, acobatPath)
- end
-
- on moveUpDirectory currentPath, stepNum, newfolder
- gDel = the last char in the pathname
- the itemDelimiter = gDel
- maxItems = currentPath.item.count - stepNum - 1
- newPath = currentPath.item[1..maxItems] & gDel
- if newfolder <> EMPTY then
- newPath = newPath & newfolder & gDel
- end if
- the itemDelimiter = ","
- return newPath
- end
-
- on DirectoryList
- gDirpath = moveUpDirectory(the pathname, 1, "PDFs")
- put baFileList(gDirpath)
- end
-