El Constructorr: I don't know how to mention your special username.
Sebastian Ribis Ah yeah! The space is the middle doesn't let us refer. But just figured out, this button does the job!
Ribis First, learn how Multiplayer works, the concept, how to communicate with other players. Once you know this, it would be easy to add Multiplayer events in an existing game too. (But first, learn by making a simpler Multiplayer game from scratch, that's my advice).
I've prepared some basic examples for you to understand how Multiplayer works. Here's a VERY minimal working example, using Photon plugin in C3, on how two players can connect, and share their names with each other:
I presume if you read along the events, everything should be self-explanatory! Notice the first two events got you connected to a Room. (In C3 Multiplayer plugin, this alone takes you several events to do so).
The idea in Multiplayer game development is to Send signals/messages to communicate with other players. This can be done by "Raise Event" action. Example, in Event 3 above, the player sends a message with Code 1, and has his Name as the data sent. Likewise, Event 4 triggers whenever a Code number 1 is received, if so, it would display its data!
So if you run this on two browsers, both players will get to see each others name & Connected!
Similarly, if one player Solves a Puzzle (for example), and you want the other player to know that, you can do this:
If you got the idea, or understood everything I've said so far, you can continue reading. So sometimes, you need to send a LOT of data together, instead of creating many Events, you can type in the data separated by a Character. Then on receive, just decode it by splitting the data.
For example, if Player 1 wants to send their position (X,Y) every tick, they can Raise Event like this:
Notice, the # symbol is used as a separator (you can use a comma, or anything). This is how Player 2 would decode it and set Player 1's position on his screen:
The 0 and 1 above is the index. 0 to fetch the first portion of the data separated by "#", and so on.
Anyway! That's all from me.
All of that I just explained is not just to get you started, but it's literally everything you need to know to make a complete Multiplayer game! (Of course, there are more features, some really handy events and actions you must look into when exploring Photon).
Hope this helps!