User Tag List

Page 1 of 2 1 2 LastLast
Results 1 to 10 of 11

Thread: Pong Tutorial - Ball direcction respect from paddle zone

  1. #1
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export Module
    Matriax's Avatar
    Join Date
    Dec 2012
    Posts
    224
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Pong Tutorial - Ball direcction respect from paddle zone

    I finished the pong game tutorial by Kjetil Nossum (Popcorn) without problems.

    But the tutorial no mentioned how to launch the ball in various directions depending in what zone of the paddle bounce like in the original pong. i know that when the ball touch the very corner change the direcction but is to extreme and hard to achieve this in the game.


    I want to get 2 things:

    1- Ball bounce in diferent direcction depending on what zone of the paddle collide.
    2- The paddle movement direction. If the ball goes to me to the top zone of the paddle but i'm moving the paddle down the ball will need to go down.


    Any advanced pong tutorial that explain this or anybody can tell me how to do it? Yes, I know this can be more difficult and i'm starting but well i want to complete exactly the full original game .

  2. #2
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleiOS Export Module
    rubes's Avatar
    Join Date
    May 2011
    Posts
    364
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    One approach to take to get the ball to bounce in a different direction depending on the zone of the paddle collision, is to use 3 actives for the paddle, corresponding to the zones. I have attached an example of this, with each end of the paddle a different color, just for ease of viewing. The end portions of the paddles have limited directional options, while the middle middle paddle has a different set of directional options. I'm sure there are some trig functions to do this as well, but this is a simple built in way to do this.
    Attached files Attached files

  3. #3
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUniversal Windows Platform Export ModuleSWF Export ModuleMac Export ModuleInstall Creator Pro
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Tisnart's Avatar
    Join Date
    Feb 2008
    Location
    On, Canada
    Posts
    1,031
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    I have an unfinished tutorial that would at least give you some good ideas on how to achieve what your asking. If you want to PM me as a reminder (I'm at work right now) I can send you what I have done so far.

  4. #4
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export Module
    Matriax's Avatar
    Join Date
    Dec 2012
    Posts
    224
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by rubes View Post
    One approach to take to get the ball to bounce in a different direction depending on the zone of the paddle collision, is to use 3 actives for the paddle, corresponding to the zones. I have attached an example of this, with each end of the paddle a different color, just for ease of viewing. The end portions of the paddles have limited directional options, while the middle middle paddle has a different set of directional options. I'm sure there are some trig functions to do this as well, but this is a simple built in way to do this.
    Thanks, after investigate in the options i was arrived at the same solution as you! but discarded to find a more elegant with only one graphic paddle.

    Quote Originally Posted by gerald999 View Post
    I have an unfinished tutorial that would at least give you some good ideas on how to achieve what your asking. If you want to PM me as a reminder (I'm at work right now) I can send you what I have done so far.
    Hey! this be interesting! ok i will wait.

    -----

    Now i added a menu, credits, a graphics with "Player 1 Wins" when one reaches lives=0 and set more speed to the ball each time that hit the paddle and restore the speed when loses by left or right, only searching with the options and testing all, i hope all will be easy and fun as this .

    But my first idea was add acceleration to the Bouncing Ball looking in the "movement" secction(The paddles have acceleration) but only have speed and decceleration and my question is... Why the bouncing ball not have the acceleration option? BTW, if i want add acceleration to the ball constantly without touch the paddles, How i get it?

    Here an image of my pong:

  5. #5
    Clickteam Clickteam
    Danny's Avatar
    Join Date
    Aug 2007
    Location
    United Kingdom
    Posts
    3,006
    Mentioned
    21 Post(s)
    Tagged
    2 Thread(s)
    Constant ball acceleration can be achieved like this:
    Every 2 seconds: Set Ball Speed: ("Ball Speed")+1
    Want to learn Clickteam Fusion 2.5?




  6. #6
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export Module
    Matriax's Avatar
    Join Date
    Dec 2012
    Posts
    224
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Danny View Post
    Constant ball acceleration can be achieved like this:
    Every 2 seconds: Set Ball Speed: ("Ball Speed")+1
    Ops, forgot the timer, obviously, thanks!

  7. #7
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUniversal Windows Platform Export ModuleSWF Export ModuleMac Export ModuleInstall Creator Pro
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Tisnart's Avatar
    Join Date
    Feb 2008
    Location
    On, Canada
    Posts
    1,031
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Tutoriod

    Here ya go, Like I said it's unfinished.
    This is a breakout (Bat-n-Ball) tutorial but you may gets some ideas from it as this first part talks about the Paddle and Ball and could be applied to a pong game.
    Cheers!
    Gerald

  8. #8
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleiOS Export Module
    rubes's Avatar
    Join Date
    May 2011
    Posts
    364
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    That's a very clever way to deal with how the ball bounces based on where it is hitting the paddle. Excellent tute

  9. #9
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export Module
    Matriax's Avatar
    Join Date
    Dec 2012
    Posts
    224
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by gerald999 View Post
    Tutoriod

    Here ya go, Like I said it's unfinished.
    This is a breakout (Bat-n-Ball) tutorial but you may gets some ideas from it as this first part talks about the Paddle and Ball and could be applied to a pong game.
    Cheers!
    Gerald
    Wow! i only see some pages but seems to be all very good detailed and explained step by step, Congratulations and thanks for the tutorial!

    I see your solution for that and i think is the best solution, but maybe seems too complicated to add into a pong now with my skills . I think i will finish the pong game today with some sounds and other things and i will start your arkanoid tutorial and when i learn the solution i will apply to the pong game.

    I see this is the first part, the others have some release date? BTW, i see an arkanoid example created by ┐Nivram? that explain the powerups, bricks and particles for that i can continue working on it while wait for the other parts.

    Again, Thanks for all!

  10. #10
    Clicker

    Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUniversal Windows Platform Export ModuleSWF Export ModuleXNA Export ModuleInstall Creator Pro
    nivram's Avatar
    Join Date
    Jul 2006
    Location
    Bandon, Oregon
    Posts
    6,730
    Mentioned
    9 Post(s)
    Tagged
    0 Thread(s)
    Hi Matriax. That example was not made by me.

    Marv
    ​458 TGF to CTF 2.5+ Examples and games
    http://www.castles-of-britain.com/mmf2examples.htm

Page 1 of 2 1 2 LastLast

Similar Threads

  1. Pong: How to have ball stick to paddle and launch when left click of mouse
    By rubes in forum Multimedia Fusion 2 - Technical Support
    Replies: 26
    Last Post: 14th June 2016, 04:10 PM
  2. Ball / Round object physics (ball won't stop)
    By LemonyWeasel in forum Multimedia Fusion 2 - Technical Support
    Replies: 12
    Last Post: 30th November 2015, 11:59 PM
  3. The ball... (in pong)
    By RickyRombo in forum Lacewing
    Replies: 3
    Last Post: 20th April 2009, 01:26 AM
  4. Ball and paddle example
    By nivram in forum File Archive
    Replies: 0
    Last Post: 9th December 2008, 12:11 AM
  5. Water Paddle Tennis
    By Jaffob in forum File Archive
    Replies: 8
    Last Post: 1st September 2008, 12:39 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •