The Enchanted Cave 2
Delve into a strange cave with a seemingly endless supply of treasure, strategically choos
4.34 / 5.00 31,296 ViewsGhostbusters B.I.P.
COMPLETE edition of the interactive "choose next panel" comic
4.07 / 5.00 10,082 ViewsYup. Probably the most basic question ever.
I need to be able to move my VCAM with the arrow keys, and zoom in and out using z and x with AS2.
My username sucks.
Easiest way to move a vcam is when a user presses either key, move _root._x and _root._y.
At 11/7/08 10:14 AM, DarkSkyForever wrote: Easiest way to move a vcam is when a user presses either key, move _root._x and _root._y.
Mind giving me more info?
I'm AS-retarded. D:
Like, I get what _root._x and _root._y are, they change the coordinates, but I don't know the actual scripts to use.
My username sucks.
onClipEvent(enterFrame){
if(Key.isDown(Key.UP)){
_y-=5;
}
if(Key.isDown(Key.DOWN)){
_y+=5;
}
if(Key.isDown(Key.RIGHT)){
_x+=5;
}
if(Key.isDown(Key.LEFT)){
_x-=5;
}
if(Key.isDown(90)){
_xscale--;
_yscale--;
}
if(Key.isDown(88)){
_xscale++;
_yscale++;
}
}
Put that on the vcam.
"Whoever said 'winners never quit' obviously never considered addicts." - Hoeloe
onClipEvent(enterFrame){
if(Key.isDown(Key.UP)){
_y-=5;
}
if(Key.isDown(Key.DOWN)){
_y+=5;
}
if(Key.isDown(Key.RIGHT)){
_x+=5;
}
if(Key.isDown(Key.LEFT)){
_x-=5;
}
if(Key.isDown(90)){ // or any outher key...
this._hight -= 5;
this._width -= 5;
}
if(Key.isDown(88)){ // or any outher key...
this._hight += 5;
this._width += 5;
}
}
something like this..
At 11/7/08 01:21 PM, uyersuyer wrote: Put that on the vcam.
That worked. Thanks a lot. :3
My username sucks.