Kalagaraz's Recent Forum Activity

  • It appears you have two questions:

    • Should I use WebRTC or WebSockets?
    • How do I modify default plugins?

    For the first question, we need to know what kind of game you're making. If it's a bullet-hell, use WebRTC. If it's a puzzle, use WebSockets. If it's a card game, use simple ajax.

    For the second question, let's go point by point:

    > Multiplayer plugin seems to only support peer-to-peer, even though WebRTC is capable of following a authoritative server approach. Upside I gain UDP support, downside I lose the entire IE audience.

    >

    Peer-to-peer can be coerced into "authoritative server" by simply adding special logic that treats some predefined peer as an authoritative server. It's really quite simple, and you get the benefit of also connecting to peers, so you can send them non-authoritative data for a latency boost (and a lower bandwidth fee on your server).

    > Websocket plugin only allows you to send strings which would be a bit inefficient. I'd like to modify it to add ability to send custom datatypes.

    >

    Regardless of the datatype you send, it will get converted to strings anyways. Besides, construct doesn't support types other than string/number/bool natively.

    Notice that you don't have to modify the plugins in either case.

    Interesting.

    Do you know of any examples using the mulitplayer plugin with an authoritative server (A non-construct2 server)?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Is there a way to modify default plugins?

    I haven't decided between WebRTC or WebSockets for my online game yet using a server programmed outside construct 2, but either options requires some changes to the base plugin.

    Multiplayer plugin seems to only support peer-to-peer, even though WebRTC is capable of following a authoritative server approach. Upside I gain UDP support, downside I lose the entire IE audience.

    Websocket plugin only allows you to send strings which would be a bit inefficient. I'd like to modify it to add ability to send custom datatypes.

Kalagaraz's avatar

Kalagaraz

Member since 16 Aug, 2014

None one is following Kalagaraz yet!

Trophy Case

  • 10-Year Club
  • Email Verified

Progress

11/44
How to earn trophies