Groups | Blog | Home
all groups > flash actionscript > february 2004 >

flash actionscript : Cant rezise loaded jpg's!!


jony_calavera
2/7/2004 10:32:36 PM
two add things happen : i cant rezise the movieclips and rotation sets itself
to 90
here is the code

lista_xml = new XML()
lista_xml.load("lista.xml")
lista_xml.ignoreWhite = true

lista_xml.onLoad =function (success)
if (success == true)
at = new Array()
bt = new Array()
rootNode = lista_xml.firstChild
blahxml = rootNode.firstChild
var i
i=0
while(i<Number(rootNode.attributes.num))
at[i] = blahxml.attributes.psrc
bt[i] = blahxml.firstChild.nodeValue
blahxml = blahxml.nextSibling
i++

textXML.text = "XML load Succsessful!"
construlle()



function construlle()
var i,n,pix:String
n=Number(rootNode.attributes.num)
for(i=0;i<n;i++)
pix=String(at[i])
_root.strip.createEmptyMovieClip("pic"+i,i+1)
loadMovie(pix,_root.strip['pic'+i])
with (_root.strip['pic'+i])
_x = i*110
_y=0
_width = 100; // doesn't wor
_height = 50; // doesn't wor



for(i=0;i<n;i++)
pix=String(at[i])
_root.strip.createEmptyMovieClip("pic"+String(n+i),n+i+1)
loadMovie(pix,_root.strip['pic'+String(n+i)])
with (_root.strip['pic'+String(n+i)])
_x= n*110 + i*110
_y=0
_width = 100; // doesn't wor
_height = 50; // doesn't wor





any help would be greatly apreciated


chris
2/8/2004 7:12:50 PM
[quoted text, click to view]
well to resize you have to wait for the image to load. but if you use
_xscale and _yscale you can set the size of your holder clip before you
load it.
CesareRocchi
2/9/2004 12:28:27 PM
Exactly, if the image is not there you can't resize it!
AddThis Social Bookmark Button