How do I MP game?

0 favourites
  • 4 posts
From the Asset Store
five golem elements Sprites Sheet.Best for enemy or villain game characters.
  • I download the MP game example and add it: "Touch | On touched sprite | Sprite destroy" so if I click on "sprite" it will disappear and it works but since it is MP I tried 2 phones so that all 2 phones But this does not disappear.

    If I clicked, I just clicked on the click on the other.

    If this is MP, why does not the "sprite" disappear on all 2 phones? Is it not the case if you connect to the server then put them in a layout? Why does not the sprite disappear on the other phone?

    Even trying a multiplayer game I do not really understand it.

  • You need Synchronized objects and associate the objects with the peers.

    When the peer disconnects from the host/room, the host automatically destroys the objects, which in turn destroys the objects on the other peers.

    Adding a touch event on the host side, to destroy a player associated object will destroy the given object on the peers as well.

    But the other way around will fail:

    Adding the touch event on a peer (not host) to destroy any of the player objects ... the object in question would simply be recreated.

    You can however, from the peer end, send a message to the host, with a reference to the object you want to destroy, and have the host destroy the object for the peer.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • I added:

    System on start of layout :Multiplayer sync "sprite" (with position and angle,precision Normal (float, 4 bytes) at Normal bandwidth (unpredictable)

    Multiplayer associate "Sprite" with peer Myusername.

    But this only shows sprite on both sides if only the "host" is clicked on sprite.

    Screenshot: prntscr.com/ff1itp

  • Needs to be associated with the correct peers.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)