Battleship Ultimate goes multiplayer !

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.
  • Dear all,
    I started a battleship project in order to get the grasp of Fusion 2.5.

    I've learnt a lot, using fast-loops and for-each-loops, event grouping, collisions, and much more, trying to understand the logic - and the power - behind Fusion.

    I must say, I really enjoyed the whole development. Even if Fusion is not a "real" programming language - in fact, it's an engine - I find it really creative and the way I had to solve lots of challenging tasks has been a very effective training for my brain.

    Why a battleship ? Well, I decided to start easy in order to get accustomed to the lang.. ahem, to the logic of Fusion. But I ensure you, even if the game is "easy", the challenges it holds are really cute !

    There's still lot to do however. Sound an music for instance. As well as some other animation, and a more coloured and appealing graphic background.

    But I want to share with you the current status of it. I hope you enjoy it and have some nice suggestion for me.

    Thanks for your attention and have a nice day,
    Sergio

    The battleship game is online here: Please login to see this link.

    Edited 2 times, last by semar (March 7, 2024 at 3:42 PM).

  • Yes - it works !

    Now Battleship Ultimate can be played online with other players :)
    This was possible by using the LaceWing Blue Client from Phi ( Darkwire Software ). It works like a breeze, and I can only recommend it !

    This was another really nice journey with Fusion 2.5+.
    In the game I've changed the main buttons and made it more "intuitive". It may however looks child-ish - what do you think about ?

    Next step will be adding more sound effects and some music. Which will hopefully bring new life to the game.

    Fancy a game ?
    Please login to see this link.

    Take care,
    Sergio

  • Hello,

    good work , congratulations for that !

    if you decided to put the .mfa of this on clickstore ( when it is back online ), I would buy it to learn some of the concepts you mentioned ,especially the For Each loop and the implementation of multiplayer with bluewing ( which I have, but it's not easy for me to use .

    Please login to see this link.

  • you need someone to do gfx for it.

    Indeed danjo.
    I usually do first the logic of a game or application. This is useful for me because provides a "proof of concept". If the logic works as expected, then I go further with developing, and at some point of the process I take in consideration the graphic aspect.

    This way I don't "waste" time by doing gfx, just in case I don't get right with the game logic and gameplay.

    I have to admit, I'm not really good in doing gfx. I'm not a pixel artist. But this could be a motivation to improve in this department, even if the result is not so appealing at the beginning. I like coding the logic, and this is for me really satisfying.

    There is also a paradigm to take in consideration. Is good gfx but bad gameplay/logic better than bad gfx but good gameplay ?

    The best, of course, would be good gfx and good gameplay. In this forum there are really talented gfx artists which are also cute in programming. That makes this place a good resources from where gain a lot of motivation and learn !

    Thank you for your answer and have a nice day,
    Sergio

  • Hello,

    good work , congratulations for that !

    if you decided to put the .mfa of this on clickstore ( when it is back online ), I would buy it to learn some of the concepts you mentioned ,especially the For Each loop and the implementation of multiplayer with bluewing ( which I have, but it's not easy for me to use .

    Hello therickman !

    First of all, many thanks for your kind words - appreciated !

    I don't think that my code is clean enough to be sold, really ! And in this forum there are really good and talented coders, from which you can get much more comprehensive code than mine !

    About fast-loops, they are really powerful but you have to know when to use it and how. And yes, there are some pitfalls regarding collisions and object scoping. I'm not in any extent an expert about fast loops, but I've used them just to get the grasp of it. Basically I use it to create 2 times the 10X10 squares on the boards (player and opponent boards) and - if I recall correctly - to build the numbers on the top of the board (1-10) and the letters on the left side (A-J). I could have used for that just two images ( or one that surround both boards !) , thus avoiding to create 2 * 20 different text objects.
    You see, there are more ways to accomplish a task. This was my very first project with Fusion, that's why I didn't really care about performances. The game runs smooth anyway, and loads rather fast in the browser.

    About Lacewing Blue Client there's no magic here, I've just used the example provided in the documentation, and adapted to my needs. I've implemented a simple message protocol, in order to make the peers communicate between each other. But the main functionality about send and receive messages from/to peers is already well covered from within the Lacewing Blue Client itself.

    As an example, in the Batteship Ultimate the local peer sends an invitation to the remote peer by sending a text message "invitation". When this message is received, the buttons "accept" and "decline" will be enabled on the client who received the invitation. By pressing "accept", the client sends the text "accept" to the other client. This message will activate another part of the logic (a group of events). In this part, the message "play" will be sent, and the "battle" starts. On the other side, the client receives the message "play" and will start the same logic.

    I tell you, it's simpler as you may think. Just use the example provided in the docs, and you are set !

    I hope it helps, and I'm more than happy to help you if you have further questions :)

    Take care,
    Sergio

Participate now!

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