PDA

View Full Version : Flash Lite 1.1


Um Design
10-28-2005, 08:52 PM
Yesterday I have tried 100 times to insert script to move, lets say to move one circle, I have named circle "Hero". This is the script for Flash 8:

_root.onEnterFrame = function ()
{
moveHero(5);
}
function moveHero(speed)
{
//check if key is down
if( Key.isDown(Key.UP))
{
_root.hero._y -=speed;
}
else if( Key.isDown(Key.LEFT))
{
_root.hero._x -=speed;
}
else if( Key.isDown(Key.DOWN))
{
_root.hero._y +=speed;
}
else if( Key.isDown(Key.RIGHT))
{
_root.hero._x +=speed;
}
}

Now, the question is how to insert code (Actionscript), I mean how to replace this actionscript that my cirlcle (Hero) move in Flash Lite 1.1.?

Thanks in advance

imodejon
12-02-2005, 03:57 AM
you are using the wrong code for Flash Lite ( i believe). You need to check your codes with this link to make it work. Also, left doesnt work unless its "soft Key"
http://www.scottjanousek.com/downloads/fl_onesheet/fl_onesheet.pdf