macro StartPACO fileName, whereAt, preload, center
global pacoRefNum,command
updatestage
when mousedown then nothing
put word 1 of fileName&word 2 of fileName&word 3 of fileName&word 4 of fileName&word 5 of fileName into fileName
put (chars(fileName,1,3)&chars(fileName,length(fileName)-3,length(fileName)))&".cv" into filename
if the machineType=256 then startpaco2 (fileName, whereAt, preload)
if the machineType=256 then exit
put XPlayPACo("openfile",string(GoUpALevel(the pathName))&"PACOS:"&string(fileName)) into pacoRefNum
if pacoRefNum contains "error" then exit
XPlayPACo("set",pacoRefNum,"posX", integer(value((item 1 of whereAt) + (the stageLeft))),"posY",integer(value((item 2 of whereAt) + (the stageTop))),Â
put "playfile"&&drive&":\HCDEMO\DEMO\PACOS\"&chars(fileName,1,length(filename)-2)&"bk"&&"-ctr 0 -posx"&&integer(value((item 1 of whereAt) + (the stageLeft)))&&"-posy"&&integer(value((item 2 of whereAt) + (the stageTop)))&&"-ni "&ni&" -pfd"&&(abs(preload-1))&&"-acm 1 -window"&&windowhandle into command
paco(mnew,command)
put "playfile"&&drive&":\HCDEMO\DEMO\PACOS\"&(fileName)&&"-ctr 0 -posx"&&integer(value((item 1 of whereAt) + (the stageLeft)))&&"-posy"&&integer(value((item 2 of whereAt) + (the stageTop)))&&"-ni "&ni&" -pfd"&&(abs(preload-1))&&"-acm 1 -window"&&-1 into command