# Moveing with KEYS

**URL:** <https://forum.kirupa.com/t/moveing-with-keys/16678>\
**Category:** Uncategorized\
**Created:** [March 27, 2003, 12:09pm UTC](https://forum.kirupa.com/t/moveing-with-keys/16678 "2003-03-27T12:09:42Z")\
**Posts on this page:** 5\
**Page:** 2

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [March 28, 2003, 10:29pm UTC](https://forum.kirupa.com/t/moveing-with-keys/16678/21 "2003-03-28T22:29:40Z")

</div>

You seem to like the tertiary operator, Lost, but here it’s not really useful as you don’t do anything when the condition is false.

```auto
Key.isDown(Key.LEFT) ? yourClip.easeTo(slideSpeed, 0) : null;

```

longer than

```auto
if (Key.isDown(Key.LEFT)) yourClip.easeTo(slideSpeed, 0);

```

😛

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [March 28, 2003, 10:33pm UTC](https://forum.kirupa.com/t/moveing-with-keys/16678/22 "2003-03-28T22:33:33Z")

</div>

I got used to that method of if statement with Javascript, so I tend to use it a lot in Flash (I am so happy it works).

The problem with  
[AS]if (Key.isDown(Key.LEFT)) yourClip.easeTo(slideSpeed, 0);[/AS]

Is that I tend to hit the code auto-format button a lot on the actions panel. And when I do that, it automatically puts the curly brackets in, and spaces it just the way the if statement should be, so it beings to make me angry, so I would rather just null out the else.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [March 28, 2003, 10:54pm UTC](https://forum.kirupa.com/t/moveing-with-keys/16678/23 "2003-03-28T22:54:05Z")

</div>

I didn’t even know there was an auto-format button :-\

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [March 28, 2003, 11:04pm UTC](https://forum.kirupa.com/t/moveing-with-keys/16678/24 "2003-03-28T23:04:48Z")

</div>

Yep, its in the actions panel, it looks like rows of text with a white white faded background on the top half and no background on the bottom half.

Right next to the checkmark for Check Syntax.

Therse also Find, Replace, and Insert Target Path, and Show Code Hint.

I rarely use any of them, except sometimes I use the auto-format JUST IN CASE, but I am usually good with that.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [March 29, 2003, 2:22pm UTC](https://forum.kirupa.com/t/moveing-with-keys/16678/25 "2003-03-29T14:22:36Z")

</div>

so… to continue this i need to make like this effect but bu keys…  
now i can handle it with keys but how to do this ?  
when you click in the name of city or place, it’s move and zoom to the target.  
here is the [Link](http://www.msnbc.com/news/877174.asp?0cb=-318115686) then click on Target Baghdad :skull:

thanx

[Previous page](https://forum.kirupa.com/t/moveing-with-keys/16678.md?page=1)
