MP Variable sync capped at 255

0 favourites
  • 5 posts
From the Asset Store
Sync animations, animation frames, mirror state, sounds and anything else using these methods.
  • Hey all,

    I am coming along in leaps and bounds with my MP game, and noticed that variables over 255 get set to 255 for the peer. Also, it does not support decimals (so 120.25 = 120). Is this intended or is this a bug? I tried looking through the manual again, but it seems the whole section on syncing variables has been removed?

    For my game it's not too big a deal for me to work around this, but I would just like to know what's going on exactly before I make any hasty alterations.

  • uhh. Depends on what sync level your setting your value and rate at.

    8 bit's of information is 0 to 255 and is often INT in nature(ie no decimal value)

    16 bit is apx 65k and can also handle decimle.

    If your using on the lesser data values/rates at 8 bit. then that's what will happen. SI u;n guessing your using

    So i'm guesing your using Low(int, 2bytes).

    first it's an INT. No decimals.

    I'm als going to assume that C2 use of 2bytes is -255 to 255 rather than 0 to 255 for 1byte.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • jayderyu - ah, right you are! Thanks for clearing that up for me.

  • AHHHH that's a golden information, I almost thought the plugin is having a bug, some of my string/text on multiplayer were incomplete and I wondered why. Thanks!

    Ashley I would like to suggest this kind of information to be included in the manual, describing the coverage of the bit information just like how explained above, and go a bit further on giving example of the effect of the bit size on numbers/integers/text/etc. This might seems like ABC for programmers, but for a non-programmer alike it's an absolute new thing.

  • DuckfaceNinja - Yes it is very helpful! But also for your text: it does not sync! I had issues with it before and Ashley told me that text variables are not meant to sync at all by design, but it had been forgotten in the manual. You need to use messages to rely text.

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