-
Help With object movment
Hi I'm fairly new to Swishmax, my current version if Swishmax 3. I wanted to try something simple;
Moving an object w/ arrow keys, or any key. I saw some guides on swishzone and some other crappy sites, but itwas all for Swish1.
-
Carpe Diem - Moderator
...it doesn't matter if it's for SWiSH Max1 or SWiSH Max3 - the action is still the same -
on (keyPress("<Space>")) {
}
on_keypress.jpg
wolf
Last edited by wolfgross; 09-18-2012 at 08:50 PM.
-
Carpe Diem - Moderator
...here's a swi the works on the space key -
on_keypress.swi
wolf
-
See, thats what the hell I thought, seen many many guides on this same thing, saying the same thing.
Basically I created a square, have in different SWI's grouped it as a movie clip, & converted to movie clip, and added this code
on (keyPress("<Up>")) {
face._Y -= 20}
on (keyPress("<Down>")) {
face._Y += 20}
on (keyPress("<Left>")) {
face._X -= 20}
on (keyPress("<Right>")) {
face._X += 20}
And absolutely nothing
-
Ok. Now this is weirding me out a bit. I tried reimplenting this code:
on (keyPress("<Up>")) {
face._Y -= 20}
on (keyPress("<Down>")) {
face._Y += 20}
on (keyPress("<Left>")) {
face._X -= 20}
on (keyPress("<Right>")) {
face._X += 20}
It doesn't work, i accidentally clicked the "up function" to the object, not the parent. The up function doesn't work but all three others work, down, left, right. I change the up function back to parent, and the whole thing doesn't work. Strange
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|