Jump to content
Search Community

dragontail

Members
  • Posts

    2
  • Joined

  • Last visited

dragontail's Achievements

0

Reputation

  1. Thanks mate~ It works, but how about this. What if i want it to be random data? Here are the XMl. <?xml version="1.0" encoding="UTF-8" ?> 400 100 120 And this is part of the AS file private function completeHandler(event:LoaderEvent):void { var xList:XMLList=new XMLList(event.target.content.LoaderMax); var o:Number=Math.ceil(Math.random()*3); var energyo="energy"+o var value1:Number=xList.energyo; var value1_per=Math.ceil(Math.random()*20)+value1; trace(value1); trace("this is energy "+value1_per); } The result is value1 = 0; Any solution?
  2. I have been trying loaderMax sometime. There are alot of example of how to load image, swf and xml. but no loading for text. The only text i can load is using xml to get url of a text file. But what if, i want it to be dynamic, like i have 5 question set in xml. <?xml version="1.0" encoding="utf-8"?> This is question 1. This is question 2. This is question 3. This is question 4. This is question 5. And i can use a array to get all the text from xml, and use it in flash. Thank for helping.
×
×
  • Create New...