Forum Topic: flash help

(135 views • 8 replies)

This topic is 1 page long.

<< < > >>
Sad

piggy123

Reply To Post Reply & Quote

Posted at: 4/9/09 03:02 PM

piggy123 NEUTRAL LEVEL 14

Sign-Up: 06/13/08

Posts: 925

onClipEvent (load) {
}

function newpos():Void {
ranx = Math.round((Math.random()*500));
rany = Math.round((Math.random()*500))
}


Happy

atomic-noodle

Reply To Post Reply & Quote

Posted at: 4/9/09 03:09 PM

atomic-noodle NEUTRAL LEVEL 14

Sign-Up: 05/17/05

Posts: 1,610

At 4/9/09 03:02 PM, piggy123 wrote: onClipEvent (load) {
}

function newpos():Void {
ranx = Math.round((Math.random()*500));
rany = Math.round((Math.random()*500))
}

How about telling the nice people what you need help with exactly? Posting some random code isn't helping anyone. Help us help you.

iamcoreyg.com // campnorth
Need a website? music? graphics? CONTACT ME.

BBS Signature

SorryItsAShortFlash LIGHT LEVEL 09

Sign-Up: 03/01/08

Posts: 18

Uhmm dont know if this will help but if your making a platformer its pretty cool

-SorryItsAShortFlash-


Expressionless

piggy123

Reply To Post Reply & Quote

Posted at: 4/9/09 04:56 PM

piggy123 NEUTRAL LEVEL 14

Sign-Up: 06/13/08

Posts: 925

How about telling the nice people what you need help with exactly? Posting some random code isn't helping anyone. Help us help you.

i need to make something move randomly


None

CaiWengi

Reply To Post Reply & Quote

Posted at: 4/9/09 05:06 PM

CaiWengi EVIL LEVEL 07

Sign-Up: 09/17/04

Posts: 1,518

onClipEvent(enterFrame) {
ranx = Math.round((Math.random()*500));
rany = Math.round((Math.random()*500))
}

?

Or change enterFrame to load if you want it to do it the once.

Sig by ApothicFlash <3

BBS Signature

Happy

piggy123

Reply To Post Reply & Quote

Posted at: 4/9/09 05:26 PM

piggy123 NEUTRAL LEVEL 14

Sign-Up: 06/13/08

Posts: 925

At 4/9/09 05:06 PM, CaiWengi wrote: onClipEvent(enterFrame) {
ranx = Math.round((Math.random()*500));
rany = Math.round((Math.random()*500))
}

?

Or change enterFrame to load if you want it to do it the once.

onClipEvent (load) {
ranx = Math.round((Math.random()*500));
rany = Math.round((Math.random()*500));
}

onClipEvent (enterFrame) {
if (this.hitTest(_root.player)) {
_root.gotoAndStop(3);

}
}

does not work


None

piggy123

Reply To Post Reply & Quote

Posted at: 4/9/09 11:35 PM

piggy123 NEUTRAL LEVEL 14

Sign-Up: 06/13/08

Posts: 925


None

TheBoob

Reply To Post Reply & Quote

Posted at: 4/9/09 11:41 PM

TheBoob NEUTRAL LEVEL 12

Sign-Up: 04/12/02

Posts: 373

you have to be more specific for what you are looking to do, right now you are setting some variables to random numbers, but you never actualy move anything. if you want it to move change the _x and _y properties.


None

Fion

Reply To Post Reply & Quote

Posted at: 4/9/09 11:42 PM

Fion LIGHT LEVEL 34

Sign-Up: 08/21/05

Posts: 2,367

At this point all you've done is set up variables that store random numbers for what would appear to be the x and y movement. For the object to move you actually have to change the properties. ie the _x and _y values need to be changed. Understand that creating a random number in ranx does not actually change anything except the value of a variable named ranx.


All times are Eastern Standard Time (GMT -5) | Current Time: 08:57 AM

<< Back

This topic is 1 page long.

<< < > >>
You need a Grounds Gold Account to post on the NG BBS! If you don't have one, click here to sign up now! It's fast, free, and easy — and opens up tons of great NG features!