Iam using the following command...to capture the key and move the object,
now i want to move it only on certain area,
for now its moving out of the scen,
i want to restrict it to certain area.
the code i use on the movie clip to move is onClipEvent (keyDown) {
if (Key.isDown(key.LEFT)) {
_x -= 4;
}
}
onClipEvent (keyDown) {
if (Key.isDown(key.RIGHT)) {
_x += 4;
}
}
onClipEvent (keyDown) {
if (Key.isDown(key.UP)) {
_y -= 4;
}
}
onClipEvent (keyDown) {
if (Key.isDown(key.DOWN)) {
_y += 4;
}
}
can some one help in this
thankx...