home *** CD-ROM | disk | FTP | other *** search
- on startMovie
- repeat with f = 13 to 15
- sprite(f).blend = 0
- end repeat
- put EMPTY into field "prodb"
- put EMPTY into field "themes"
- put EMPTY into field "prod"
- put EMPTY into field "rubrique"
- sprite(13).visible = 1
- sprite(14).visible = 1
- sprite(15).visible = 1
- sprite(16).visible = 1
- sprite(17).visible = 1
- sprite(30).visible = 1
- visiblesprite()
- end
-
- on visiblesprite
- put EMPTY into field "des"
- put EMPTY into field "texte"
- put EMPTY into field "version"
- put EMPTY into field "auteur"
- put EMPTY into field "contact"
- put EMPTY into field "titre"
- sprite(8).visible = 0
- sprite(9).visible = 0
- sprite(10).visible = 0
- end
-
- on ReFile
- global recep, filenam
- myfile = new(xtra("fileio"))
- openFile(myfile, filenam, 1)
- thefile = readFile(myfile)
- put thefile into field recep
- closeFile(myfile)
- myfile = 0
- if the machineType = 256 then
- CleanFile()
- end if
- end
-
- on CleanFile
- global AdLin, totali, recep
- AdLin = 2
- totali = member(recep).lineCount
- repeat while (totali - 1) > 0
- delete char 1 of line AdLin of field recep
- AdLin = AdLin + 1
- totali = totali - 1
- end repeat
- end
-
- on assem
- global recep, filenam, categO
- if the machineType = 256 then
- filenam = the pathname & "srce" & categO & ".gfp"
- recep = "prodb"
- ReFile()
- else
- filenam = the pathname & "srce" & categO & ".gfm"
- recep = "prodb"
- ReFile()
- end if
- end
-
- on themes
- global categO, totaline, nline, carac, themes, listhem, nbprod
- put " " into field "themes"
- listhem = []
- nbprod = []
- totaline = member("prodb").lineCount
- nline = 1
- themes = 1
- repeat while nline <= totaline
- carac = char 1 of line nline of field "prodb"
- if carac <= 9 then
- put line nline of field "prodb" into line themes of field "themes"
- add(listhem, nline)
- add(nbprod, value(char 1 to 2 of line nline of field "prodb"))
- delete char 1 to 2 of line themes of field "themes"
- themes = themes + 1
- end if
- nline = nline + 1
- end repeat
- end
-
- on prod
- global indicthem, nprod, pline, listhem, linethem, nbprod, nbchar, nach, Achar, listprod, IChar, lili
- linethem = getAt(listhem, indicthem)
- nprod = getAt(nbprod, indicthem)
- listprod = []
- pline = linethem + 1
- lili = 1
- repeat while lili <= nprod
- nach = 1
- IChar = 1
- nbchar = length(line pline of field "prodb")
- Achar = char nach of line pline of field "prodb"
- check()
- pline = pline + 1
- lili = lili + 1
- end repeat
- end
-
- on check
- global IChar, nbchar, pline, nach, listprod, lili
- repeat while IChar < nbchar
- Achar = char nach of line pline of field "prodb"
- if the machineType = 256 then
- if Achar <> "§" then
- nach = nach + 1
- else
- add(listprod, nach)
- put char 1 to nach - 1 of line pline of field "prodb" into line lili of field "prod"
- IChar = nbchar + 1
- end if
- IChar = IChar + 1
- next repeat
- end if
- if Achar <> "ß" then
- nach = nach + 1
- else
- add(listprod, nach)
- put char 1 to nach - 1 of line pline of field "prodb" into line lili of field "prod"
- IChar = nbchar + 1
- end if
- IChar = IChar + 1
- end repeat
- end
-
- on descript
- global listprod, charprod, linethem, prodline, indicprod, filenam, chem, recep, drive, sep, chara, xcha
- prodline = linethem + indicprod
- xcha = length(line prodline of field "prodb")
- charprod = getAt(listprod, indicprod)
- chara = charprod + 1
- chem = char chara to xcha of line prodline of field "prodb"
- if the machineType = 256 then
- drive = char 1 to 3 of the pathname
- sep = "\"
- else
- drive = the applicationPath
- sep = ":"
- end if
- filenam = drive & chem & sep & "filedesc.des"
- recep = "des"
- ReFile()
- pingpong()
- end
-
- on pingpong
- global enil, inst, exe, capt, drive, chem, sep
- enil = member("des").lineCount
- if line 1 of field "des" = "NA" then
- sprite(8).visible = 0
- else
- sprite(8).visible = 1
- inst = line 1 of field "des"
- end if
- if line 2 of field "des" = "NA" then
- sprite(9).visible = 0
- else
- sprite(9).visible = 1
- exe = line 2 of field "des"
- end if
- if line 3 of field "des" = "NA" then
- sprite(10).visible = 0
- else
- capt = line 3 of field "des"
- importFileInto(member(39), drive & chem & sep & capt)
- sprite(10).visible = 1
- end if
- put "Version : " & line 4 of field "des" into field "version"
- put "Auteur : " & line 5 of field "des" into field "auteur"
- put "Contact : " & line 6 of field "des" into field "contact"
- put line 7 of field "des" into field "titre"
- put line 8 to enil of field "des" into field "texte"
- end
-