as2

JSON vs. XML parsing speed in Flash AS2

All, I'm working on a Flash AS2 project in which I have a choice of receiving a dataset in either XML or JSON. The dataset is probably about 100-1,000 rows of data; each row has roughly 50 fields; most values are numeric. If I use XML, I'll be able to define the XML myself, to make sure it's as compact as possible. So, I could use so...

What's the AS3 equivalent for MovieClip.CreateEmptyMovieClip?

I have some older AS2-style Haxe code which uses flash.Lib.Current.CreateEmptyMovieClip() to create a slideshow of disk-based images. It creates a new clip for holding each image and simply fades each image in and out with alpha levels. Compiling it with -swf -swf-version 8 creates an SWF file fine and this works in the browser. Howeve...

As2 jpg preloader pulled from xml

Hi All, I am trying to build a simple preloader. I have 4 movieclips on stage and on each one i am adding an image that comes from an xml file theMap = new XML(); theMap.ignoreWhite = true; theMap.onLoad = function(success){ if (success) { theNodes = theMap.firstChild.childNodes; for (i=0;i < theNodes.length;i++) {...

Is there a Loader.loadBytes() equivalent or solution for AS2?

If I have a handcrafted sequence of bytes, can I load them an AVM1 (flash8) swf using AS2, as I could do with Loader.loadBytes() in AS3? (Without roundtripping it to a server and loading it remotely). ...

Flash AS2 post request across domain not allowed

Hi guys, I have my flash application hosted on a 3rd party domain (flash.example.com )and i'm trying to post data and redirect to my local server. (www.example.com) It will not allow me to do this. I've used the flash debugger and it IS finding the crossdomain see output below. OK: Searching for <allow-access-from> in policy files t...

AS2 Inventory System

Hello, I'm attempting to create an Inventory System written in action script 2 (flash as2) I'm trying to create one that has inventory spots dynamically created and a movie clip remotely loaded into the mc in the inventory spot. I cannot find any online guide on how to do this (Only manual ones which you have to create the inventory sp...

attach a symbol over the xml slide gallery in actionscript 2.0

Hello, i'm editing an actionscript 2.0 file, i have a xml files with images urls in the nodes and it works. I have a symbol with id='mysymbol' in the library and it would be great to attach 'mysymbol' over the gallery while other images slide. i have an empy scene, just this AS 2.0 script and the xml: import mx.transitions.Tween; imp...

Problem with setting dynamic text in Macromedia Flash Pro 8

Firstly, sorry if I'm missing something obvious, but after looking over the same line of code and settings over and over and not being able to find a solution, I thought it better to just ask on the off chance that it'd be an easily resolvable problem. I've tried googling it, but end up with basic tutorials on how to use dynamic text in ...

Simple as2 load into an as3 movie

Hey guys I'm loading an as2 game into a as3 movie. No communication other than to play the game in the movie. I'm using a loader class. function startLoad() { var mRequest:URLRequest = new URLRequest(correctURL.toString()); mLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, onCompleteHandler); mLoader.contentLoaderI...

AS2: Are functions declared in a class stored as separate instances taking up more memory on each object instantiated?

My question is about memory use and objects in actionscript 2. If I have a class definition: class test1{ public function one(){trace("Hello");} public function two(){trace("World");} } And a second class definition: class test2{ static public function one(){trace("Hello");} static public function two(){trace("Worl...

loadmovie into _level0, all others _levels will reset?? (as2)

I have a simple swf file, it load three movie movie(swf) in to 3 different _level : loadMovieNum("test1.swf", 0); loadMovieNum("test2.swf", 1); loadMovieNum("test3.swf", 2); test2.swf just have a button with script : on (release) { loadMovieNum("test2.swf",0); } test3.swf have a button with script : on (release) { loadMovieNum("...

How to get a byte stream from a url link?

I'm currently trying to open a stream using AS2 and parse the incoming data. How can I do such thing using strictly AS2, flash 8 or lower? Essentially I want to read the incoming data from a radio station from SHOUTcast and parse it's meta data. I don't need to playback this station. Thanks! -Jona ...

AS2 movieClips combining unexpectedly and in unexpected ways

I have a grid based game with eight bots each moving under their own instruction set, I have set them to return their ID and location when clicked, the game as it stands now is over 2k lines so I wont post it all here :) on occasion two of the bots are merging into the same MC, clicking on either one or between the two merged ones will ...

HTML text in xliff file

I need a way to have text that may include bullets in a XLIFF file (so that it is translateable and load it in a dynamic text field using as2. I was informed that using CDATA in the XLIFF file was a bad idea so I came up with a work around where in place of <li> tags I have [*] & [/*] In the flash I am replacing these with list item...

Controlling as2 swf playback in as3

I am embedding a swf built in flash 8 into an as3 project. When I call stop() or gotoAndStop(0); on the MovieClip that represents an instance of the embedded swf it stops for a sec and then continues. Trying to call removeChild on the mc removes it from the display but the audio in the swf keeps playing. The swf, in this case must be emb...

OpenSSL smime verify failed with right certificate and signature

I receive encrypted and signed smime message. Decrypting is ok, data seems to be correct. openssl.exe smime -decrypt -in %1 -out %1_signed.txt -inkey myPrivate.pem But on verifying signature stage I get error. openssl.exe smime -verify -CAfile senderCACert.pem -certfile senderCert.pem -in %1 -out %1_plain Verification failure 7600:...

Disabling setfocus for a stage in AS2

Hi, How to Disable setfocus for a stage in AS2 ...

Flash AS2 show text one by one from array

Hi, I want to dynamically display some text from an array one after another in a dynamic textfield. var wordList:Array = new Array('one','two','three'); for (var i = 0; i < wordList.length; i++) { this.text_mc.txt.text = wordlist[i]; // Pause for 3 seconds and then move next } its the "Pause for 3 seconds and then move next"...

Is it possible to add a request header to a LoadVars when using GET (Flash AS2)

I'm working on a project built in Flash AS2. One of the things I need to do is load JSON data. In the past, I've had no problem with this - LoadVars works just fine. However, on this project, the JSON service that I'm calling requires the http request to include an ACCEPT header with "application/json". LoadVars has an addRequestHea...