My first coded game using Multimedia Fusion 2

Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • I follow the Pong tutorial for beginners created by Kjetil Nossum (Popcorn).

    Finish the tutorial only took me less than a hour and i decided improve the game to test all the possible conditions searching in these forums and asking in some of them.

    You can play here:
    Please login to see this link.

    Added:
    Fades In/Out
    External Links
    Moving Buttons and images to start the frame
    Used a Qualifier for Hand Cursor
    Use Behaviors to "Mouse Over a button" to change the image(Only in the first screen)
    Ball acceleration
    Game Pause
    Images to show who won the match
    Play Again
    ESC key back to menu during gameplay
    And other minus features...

    Next steep is add Mochiads but seems easy.


    And well, thanks a lot to all the people in Clickteam forum for his help! In Special to: Rubes, Gerald999 and Danny!


    Sincerely i never imagine that i will learn any day to program videogames, for this thanks also to the Multimedia Fusion 2 team! ;D

    iOS Device: iPad 4
    Android Device: Kindle Fire HD 8,9"

    Developer Website: Please login to see this link.
    Flash Games Site 1: Please login to see this link.
    Flash Games Site 2: Please login to see this link.

  • Congratulations! Awesome first MMF2 title!

    Perhaps add a one player mode... Check out the example for a bit of brainspiring on how you could start to do it, my example is super simple, their is probably simpler ways even, but maybe this will get you thinking about it!

  • Congratulations! Awesome first MMF2 title!

    Perhaps add a one player mode... Check out the example for a bit of brainspiring on how you could start to do it, my example is super simple, their is probably simpler ways even, but maybe this will get you thinking about it!

    Hey! great, i can understand all the code, the unique is the expresion "set speed to (X("ball"))/16". I know you set a speed to the paddle depending in how much far/close is the ball respect them and follow the active to catch the ball but this expresion... i not understad exactly what is doing each parameter :S , Can you explain it a bit, please?

    iOS Device: iPad 4
    Android Device: Kindle Fire HD 8,9"

    Developer Website: Please login to see this link.
    Flash Games Site 1: Please login to see this link.
    Flash Games Site 2: Please login to see this link.

  • Well in this example, I wanted to show you variable speed, the close the ball is to the PC's paddle, the greater it's X position, then by dividing that value by 16 we get a reasonable speed increase, in the case of a paddle controlled by PC, you could always set its Y pos to that of the ball, but that would make it unbeatable, you want to be able to score points so you have to create "Variable" control, IE work in "error" into the PC's control of the paddle, Speed changes is a good way to do this. Think of other ways you can achieve.

    Please login to see this link.

    Clickteam on Please login to see this link. - Clickteam on Please login to see this link.

  • Well in this example, I wanted to show you variable speed, the close the ball is to the PC's paddle, the greater it's X position, then by dividing that value by 16 we get a reasonable speed increase, in the case of a paddle controlled by PC, you could always set its Y pos to that of the ball, but that would make it unbeatable, you want to be able to score points so you have to create "Variable" control, IE work in "error" into the PC's control of the paddle, Speed changes is a good way to do this. Think of other ways you can achieve.

    You give me an idea for a feature in a possible game but i don't know if this is the correct way or there are any other better options.

    With this code you say we can change a variable depending in how much far/close is an object respect other, right?

    Ok. Then, will be a good idea use this for the sounds depending in how much far/close is the player from other person, waterfall, clock, lava... or something? If I understand well, with this, each time the player is near an object with sound we can increase automaticaly the volume to get a real sound ambient. Is correct/possible? Is a good idea or there are better ways to achieve this?

    iOS Device: iPad 4
    Android Device: Kindle Fire HD 8,9"

    Developer Website: Please login to see this link.
    Flash Games Site 1: Please login to see this link.
    Flash Games Site 2: Please login to see this link.

    Edited 2 times, last by Matriax (January 4, 2013 at 8:47 AM).

  • Now you thinking Fusion style, yes indeed you could do that with your sounds, Simply decide the range, how quiet you want it, and how close for max volume, then use the Advanced direction calc object to return a value in px how far away a partiular object is, IE

    Direction between two objects(No Decimals) Object A(x,y) Object B(x,y) in expression editor it looks like

    LongDir( "Advanced Direction Object", X("Object 1"), Y("Object 1"), X("Object 2"), Y("Object 2"))

    This will return a value of how far you are from the object that you should be wanting the sound to generate from. of course this means the number is higher the further away you are, so to plug that in directly to a volume setting would mean it is louder further away you are so you would want to "Reverse" this number by doing something like this....

    100-LongDir( "Advanced Direction Object", X("Object 1"), Y("Object 1"), X("Object 2"), Y("Object 2"))

    Please login to see this link.

    Clickteam on Please login to see this link. - Clickteam on Please login to see this link.

  • Wow this is excellent! Well done Matriax!

    I was wondering, do the shadows of the bats make the ball bounce?

    You could separate the shadow and bat into separate objects, always positioning the shadow at the bat. That would take care of that if it's a problem. I can't actually tell, but it seems fishy.

    EDIT: Kisurgi, have you seen this? Please login to see this link.

    Please login to see this link. by KetchupMaster - A must have for any web developer!
    Please login to see this link.

    Edited once, last by RickyRombo: found a post for Kisurgi (January 5, 2013 at 8:56 AM).

  • Wow this is excellent! Well done Matriax!

    I was wondering, do the shadows of the bats make the ball bounce?

    You could separate the shadow and bat into separate objects, always positioning the shadow at the bat. That would take care of that if it's a problem. I can't actually tell, but it seems fishy.

    Yes, When i started i don't know how to fix this, the paddle and shadows are 1 graphic, but now i know to solve this separating the paddle-shadow in 2 graphics, order back the shadow to the paddle, without collisions and following the player-paddle with the same properties.

    But well i think i learn a lot improving the pong and i spent enouht time to create a decent/playable game. Now it's time to move and i go to start the Arkanoid tutorial with power-ups and other since 0 by me to apply all that i learned and all i will learn ;)

    iOS Device: iPad 4
    Android Device: Kindle Fire HD 8,9"

    Developer Website: Please login to see this link.
    Flash Games Site 1: Please login to see this link.
    Flash Games Site 2: Please login to see this link.

    Edited once, last by Matriax (January 5, 2013 at 9:15 AM).

  • I've always thought Pong was the perfect first project for someone new to MMF2, because you can start really simple (even using the dreaded built-in movements if you want), and then adding extra features will teach you many of the most important concepts in game coding.

    For example:

    #1: Create a simple two player Pong clone, using the built-in movements.
    This will teach you the real basics of MMF2 - how to use the different editors, etc and write an event.

    #2: Create a basic custom 360° movement for the ball, and another custom movement for the bats; Make the ball get faster each time it bounces.
    This will teach you how to code a custom movement, and possibly how to use fastloops.

    #2b: Improve the custom movements to handle realistic bouncing off non-rectangular bats, and awkward situations such as when the ball is squeezed between a bat and the edge of the playing area - completely glitch-free!
    This will teach you more about coding a solid custom movement, how to use fastloops, and possibly a little maths.

    #3: Create an AI opponent which tracks the ball at a constant speed; Create a menu system allowing the player to select opponents of varying difficulty (without using a different frame for each opponent).
    This will teach you a little about AI, global values, and menu systems.

    #3b: Improve the AI opponent so that it can predict the path of the ball, instead of just tracking it.
    This will teach you to think creatively about problem solving, and a little more about custom movements, etc.

    #4: Add a high scores table for each level of difficulty, using an ini object; Redo it using an array instead.
    This will teach you about saving and loading data in external files.

    #5: Add a multi-ball feature, where all the balls are duplicates of a single object type; Have the AI bat target the nearest ball.
    This will teach you about MMF2's object selection system, finding the nearest instance, and possibly how to use the ForEach extension.

    #5b: Improve the AI opponent so that it can target balls more intelligently. For example: Target the ball which will next reach the goalline, taking into account speed & direction; Don't target a ball if it can't be reached in time. Position the AI bat so as to aim the ball away from the player; If you're really ambitious, taking into account the speed & direction of all balls, target them in the order which will allow the maximum number to be returned.
    This will teach you more about problem-solving, AI, the ForEach extension, etc.


    If you can do all that, you'll have covered pretty much all the essentials (in a short space of time), and should be able to make most kinds of game. And if you can't do all that, then maybe you should learn before moving onto something more complicated.

  • Definitely needs a single player version. Just move the AI's paddle towards the ball. You won't want it always matching the Y, but move towards it, otherwise it would be impossible to beat. You could also maybe have a random value that determines if the AI misses it if you're really have an issue with it being unbeatable.

  • Thanks guys for the feedback! But the game was distributed on portals already. Was my first tutorial on i improved a bit adding some features but not much more.

    My idea is learn more in the nexts tutorials and try to finish the different games than improving again and again the same game, not is very motivational work in a Pong :) .

    When i get more skills i will develop another pong with all this including power-ups or special effect like particles or glow, singleplayer,etc... maybe something called "Retro Apongcalypse Nao!" :P .

    As i said now is time for an Arkanoid and a game made by me without tutorials help, finally i got a simply idea that can be works ;)

    iOS Device: iPad 4
    Android Device: Kindle Fire HD 8,9"

    Developer Website: Please login to see this link.
    Flash Games Site 1: Please login to see this link.
    Flash Games Site 2: Please login to see this link.

  • Is it a mouse controlled paddle? The easing algorithm I use to set the paddles position, instead of

    Always: Set Y( "Paddle" ) to ymouse

    is

    Always: Set Y("Paddle") to (9*Y("Paddle")+ymouse)/10.0

    For a list of my achievements, hit up Please login to see this link..com/
    Unless you want to party, then go to Please login to see this link.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!