0% found this document useful (0 votes)
3 views2 pages

ActionScript 3: Animación Gráfica

The document discusses loading images and swf files in ActionScript 3. It shows code for adding a click event listener to a button to trace "hola" when clicked. It also shows code for loading an image file called "pato1.png" using a Loader when another button is clicked, and adding the loaded image to the "ver" display object container. The code examples demonstrate how to load and display external assets in response to user interactions like button clicks in ActionScript 3.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views2 pages

ActionScript 3: Animación Gráfica

The document discusses loading images and swf files in ActionScript 3. It shows code for adding a click event listener to a button to trace "hola" when clicked. It also shows code for loading an image file called "pato1.png" using a Loader when another button is clicked, and adding the loaded image to the "ver" display object container. The code examples demonstrate how to load and display external assets in response to user interactions like button clicks in ActionScript 3.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

FERSYSTEM Animación de Gráficos

Action Script 3

Dibujamos el escenario

Nos ubicamos en el primer fotograma y agregamos en la ventana de acciones

Cargando eventos

import [Link];
[Link]([Link],playf);
function playf (Event:MouseEvent):void
{//play();
trace("hola")
}
stop();

ahora cargar imágenes o swf


var ldr:Loader=new Loader();
var url:String="[Link]"
var urlReq:URLRequest=new URLRequest(url);
[Link](urlReq);
[Link](ldr)
FERSYSTEM Animación de Gráficos

Editamos la acción

import [Link];
[Link]([Link],playf);
function playf (Event:MouseEvent):void
{
trace("hola")
}
[Link]([Link],verimagen);
function verimagen(Event:MouseEvent):void
{
var ldr:Loader=new Loader();
var url:String="[Link]"
var urlReq:URLRequest=new URLRequest(url);
[Link](urlReq);
[Link](ldr)
}
stop();

You might also like