Luigi Yoshi Mario Fans Forums

Welcome to all the nintendo fan! This is the place for all fans of nintendo
 
HomeHome  GalleryGallery  FAQFAQ  RegisterRegister  Log inLog in  

Share | 
 

 Yoshi Flash

View previous topic View next topic Go down 
AuthorMessage
xterra09
Global Moderators
Global Moderators


Posts : 8
Join date : 2008-07-16
Age : 23

PostSubject: Yoshi Flash   Thu 24 Jul - 10:41

I just started creating "Yoshi Flash" game. Its made with Flash CS3. And has so far 79 lines of scripting.. Its not done yet.
Here is a small example of the scripting i used while programming the game..

onClipEvent (enterFrame) { //This makes sure that the following actions will be repeated every time the game enters the frame this character is on.
_root.tiredness -= 0.01; //so, every time the game hits this frame the tiredness variable wil be reduced with 0,01.
_root.hunger -= 0.02; //and this variable will be reduced with 0,02
}//end of onClipEvent's block.

onClipEvent (enterFrame) {
if (Key.isDown(Key.RIGHT)) { //when right key is pressed
this._x += 5; //this movieClip will move 5 pixels to the right.
}
if (Key.isDown(Key.LEFT)) { //when left key is pressed
this._x -= 5; //this movieClip will move 5 pixels to the left.
}
if (Key.isDown(Key.UP)) { //when up key is pressed
this._y -= 5; //this movieClip will move up 5 pixels.
}
if (Key.isDown(Key.DOWN)) { //when down key is pressed
this._y += 5; //this movieClip will move down 5 pixels.
}
}

onClipEvent (enterFrame) { //This makes sure that the following actions will be repeated every time the game enters the frame this character is on.
_root.tiredness -= 0.01; //so, every time the game hits this frame the tiredness variable wil be reduced with 0,01.
_root.hunger -= 0.02; //and this variable will be reduced with 0,02
}//end of onClipEvent's block.

onClipEvent (enterFrame) {
if (Key.isDown(Key.RIGHT)) { //when right key is pressed
this._x += 5; //this movieClip will move 5 pixels to the right.
}
if (Key.isDown(Key.LEFT)) { //when left key is pressed
this._x -= 5; //this movieClip will move 5 pixels to the left.
}
if (Key.isDown(Key.UP)) { //when up key is pressed
this._y -= 5; //this movieClip will move up 5 pixels.
}
if (Key.isDown(Key.DOWN)) { //when down key is pressed
this._y += 5; //this movieClip will move down 5 pixels.
}
}

Thats is only 1 quarter of it... NOT EVEN..

// The game is about, 2 young yoshis wake up, and find themselves in a different galaxy.
You have to adventure the different planets, and fight the evil Browser.
Its like Mario Galaxy for Wii.
Its a really fun game so far, and i hope u guys like it more than i do.
Back to top Go down
View user profile http://yoshismart.co.nr
Tylerdx
Admin
Admin


Posts : 43
Join date : 2008-07-22
Age : 25

PostSubject: Re: Yoshi Flash   Thu 24 Jul - 18:44

Interesting codes that is made for movement.

=)

Remember people there are 2 ways of movement what I know of.

Angled Movement and Scroll Movement.

Angle Movement for an example
A = Angle (Radian Value, to convert from Dec to Rad: A * (PI / 180) and to convert from Rad to Dec: A * (180 / PI) )
D = Distance, how far will you go?

Remember Sine is 0 and 180 Degrees and Cosine is the corresponding sine that means it's 90 and 270 degrees.
X = X + sin(A) * D
Y = Y + cos(A) * D

Scroll Movement is like this:

D = Distance, how far will you go?

X = X + D
Y = Y + D
Back to top Go down
View user profile
xterra09
Global Moderators
Global Moderators


Posts : 8
Join date : 2008-07-16
Age : 23

PostSubject: reply   Sun 27 Jul - 14:16

yeah, i know. Its cool to know that u know too!
Back to top Go down
View user profile http://yoshismart.co.nr
Tylerdx
Admin
Admin


Posts : 43
Join date : 2008-07-22
Age : 25

PostSubject: Re: Yoshi Flash   Wed 30 Jul - 1:28

And what is this Yoshi game is about? santa

Can't wait to see what you made! =D
Back to top Go down
View user profile
Sponsored content




PostSubject: Re: Yoshi Flash   

Back to top Go down
 
Yoshi Flash
View previous topic View next topic Back to top 
Page 1 of 1
 Similar topics
-
» My Own Flash Based Arena Game
» Important - Adobe Flash Player Vulnerability
» What is flash flood?
» Yoshi's Island [NES] Stage Idea
» 'De Zombieweasel' Flash Animation Test

Permissions in this forum:You cannot reply to topics in this forum
Luigi Yoshi Mario Fans Forums :: General Development :: Programming,Graphic Designing, And Website Developement Centre-
Jump to: