# A simple animation with action script

**URL:** <https://forum.kirupa.com/t/a-simple-animation-with-action-script/184536>\
**Category:** Uncategorized\
**Created:** [April 5, 2006, 7:48pm UTC](https://forum.kirupa.com/t/a-simple-animation-with-action-script/184536 "2006-04-05T19:48:09Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![krizinxgren](https://avatars.discourse-cdn.com/v4/letter/k/ed8c4c/32.png) [@krizinxgren](https://forum.kirupa.com/u/krizinxgren)\
**Post date:** [April 5, 2006, 7:48pm UTC](https://forum.kirupa.com/t/a-simple-animation-with-action-script/184536/1 "2006-04-05T19:48:09Z")

</div>

Good day F-MX 2004 peoples i have one simple question to do with FLASH MX 2004 ACTION SCRIPT

Yes i just want to know what kind of code would i use if i was trying to move an object 4 example i want to animate a triangle without using the the traditional tween

that is i want this triangle to move from the left side of the stage to the right side and also to know how i can stop this triangle just were i want it to stop or for the animation to loop when it reaches it target point without using tween i trust …A-S… can control images just any how one may want so please peoples help help help anyone out there

thanks  
kg

---

<div class="post-metadata">

**Author:** ![hybrid101](https://avatars.discourse-cdn.com/v4/letter/h/7993a0/32.png) [@hybrid101](https://forum.kirupa.com/u/hybrid101)\
**Post date:** [April 6, 2006, 5:54am UTC](https://forum.kirupa.com/t/a-simple-animation-with-action-script/184536/2 "2006-04-06T05:54:49Z")

</div>

```auto
onClipEvent (load) {
moveright = true;
}
onClipEvent (enterFrame) {
if (moveleft) {
_x -="speed you want
_xscale = 100;
}
if (_x<0) {
moveleft = false;
moveright = true;
}
if (_x>"right boundary _x") {
moveright = false;
moveleft = true;
}
if (moveright) {
_x += "speed you want "
_xscale = -100;
moveleft = false;
}
}

```
