Adobe Animate UI elements unidentifiable by IntelliJ from ActionScript 3 code - actionscript-3

I am trying to use IntelliJ for scripting in ActionScript (instead of default editor present in Adobe Animate), however the UI elements (tags/objects) present within the FLA files which are interpreted by the default editor are unidentifiable by intellij. Does anyone know a guide, or can someone explain to me the workflow for scripting in AS3 with intellij?

Each object drawed/created in Animate is a MovieClip objetc, If you want to create all only with code you must create each object programatically
var circle:MovieCLip = new MovieClip();
this.addChild(circle);
The best option to create AIR (as3) aplications is using the framework Starling (https://gamua.com/)

Related

How to use MXML mx.controls.Label in ActionScript

I have one AS3 application which was developed entirely in AS3 without using single line of code in MXML. Of late I am realizing that MXML has some rich controls which are not provided in open source Apache Flex SDK. One library which is of most interest to me in mx.controls, it includes Label, DataGrid etc.
Now, I want to extend my AS3 application to call mxml compiled into swf file. I tried to import mx.controls inside my AS3 programs but it does not sense that. Please tell me if I am doing anything wrong. If I am able to import mx.controls inside as3 class it would save me a lot of time. Can I do this?
Alternatively, I am trying to write a few applications in mxml and then call (.swf) in AS3. Is it possible?
I tried Googling but all examples are pointing to using ActionScript inside MXML with [CDATA[]]. But I want the inverse. Calling MXML from ActionScript.
Please explain me at nuts and bolts level as I am struggling with this a lot.
thanks in advace
You can't do that because Flex, that uses MXML, is framework built on top of the Actionscript. But you can do reverse. In Flex MXML you can use Actioscript code, and you can also use Flash components like Sprite, MovieClip... by using UIComponent or SpriteVisualElement as their parent container.

Controlling Sound / Volume

I added a sound to the Flash Professional CC library and had the program convert it to MP3. If I create a layer and drag-and-drop the sound onto the stage the sound plays fine (even after passing it through Swiffy), however that is all I am able to do so far.
I need some way to control when the sound plays as well as volume. I tried the giving the sound a class (Sound Properties -> ActionScript -> Export for ActionScript and assigned a class name mySound).
Then added this ActionScript to the first frame:
var myAudio:Sound = new mySound();
myAudio.play();
However, after passing it through Swiffy, I get the following errors:
The ActionScript class flash.media.Sound is not supported.
The ActionScript method flash.media.Sound.play() is not supported.
So I can't use the base Sound class in Flash? Is there another base class that can be used and is it compatible with the flash.media.Sound class? Is there some other way to control playback so that it can be played at a specific time -- such as on mouse roll-over or when something is clicked?
You could try using SoundJS. BTW, Flash Pro CC does have an HTML Canvas document type that uses CreateJS (which SoundJS is part of) under the hood. It won't convert AS3 to JS, though, you have to write the JS code yourself.

google doubleclick studio. video component

im bulding a flash banner where I'm using the components that double-click studio offers for free use in rich media banners.
Im the VideoPlayerAdvanced.
API documentatio here: http://www.google.com/doubleclick/studio/docs/sdk/flash/as3/en/com_google_ads_studio_video_VideoPlayerAdvanced.html
My question is how i dynamically can add a video player like the to the stage by addChild() or something like that. I also want to be able to set the urls for the player to play by code. That part seems quite straight forwards. But i can't figure out how to create an instance of the player dynamically by code.
Anyone that knows this?
Thanks!
Solved it by adding the component itself to a container movie clip and exported it with a classname for action script.
var video:Video = new Video();
addChild(video);
"video" holding the component.

Using vector shapes from FLASH PRO in FLASH BUILDER (Shapes/Graphic Symbol -> SWC?)

How to use simple vector shapes from FLASH PRO in FLASH BUILDER?
I'm already using SWC method to export buttons and movieclips, but i cant find a way to export simple shape assets. I've converted them to Symbol-Graphic, but it does not work. I've tried to convert them to button/movieclip changing base class to shape, but it generates compilation errors :(.
I don't want to use hundrets of movieclips just to export simple icons for FLASH Builder (memory usage would be huge), is there any solution for exporting simple shapes to SWC and use them in FLEX?
Edit: I'm using CC versions.
If thosse desired shapes are simple, the best method would be to generate them with actionscript code. Just create custom classes whitch extends Shape class and then you can import them from compiled swc file or straight from included folder.
Maybe this can hel you too: link

Problems implementing a Timline Editor in my level editor in Adobe AIR.

I'm currently working on an Adobe AIR project to pump out my level editor but I'm running into an issue. I basically need to implement an interactive movie editor. My question is how would you recommend I get the timeline editing started? Functionality wise it needs to be able to set tween key frames for position, scale, and alpha. Any ideas?
I've also been trying to look into pulling tween data from a swf. I'm not entirely sure how applicable this would be.
I'm not sure what you mean by movie editor - movie as in a sequence of images(bitmaps) or movie as in flash MovieClip ?
If it's the later, you could use a tweening engine like TweenLite to do the hard lifting and then it's up to you how you organize the scrollable GUI for the timeline (plenty of examples out there, starting with Flash/After Effectts/Blender/etc.) Feedback from your designer/animator is crucial I presume.
Pulling data from Flash could also be possible. If you'd like to parse the swf you can try Claus Wahlers' awesome as3swf library. Be sure to check some of his posts:
SWF Timeline Reconstruction with as3swf
Flash IDE Inspired Flex 4 Timeline Component
Another option would be to use jsfl (JavaScript scripting in the Flash IDE) and parse the tweens your designer/animator creates. It should be a matter of parsing a XML for the tween(be it old/classic or new/motion). If you go the JSFL route, you might also find the xJSFL project useful.
Also, for inspiration on game/animation tools check out Spriter