How do I turn off interpolation in multiplayer?

0 favourites
  • 11 posts
From the Asset Store
Turn Based RPG Template
$12.50 USD
50% off
A well commented RPG game template to learn from or use as a base for your own game!
  • I have object that Sync with posiition only and with very low bandwidth. In my game mechanics it object must change position on some actions. from (-100,-100) to some other an instant without interpolation.

    Example:

    Backpack on ground synced (backpack on player is only visual anims on peer side). When backpack picked its on (-100,-100) position. When player initiates backpack drop its "set position to player X,Y" Built in interpolation makes sub positions and it causes this visual flying backpack bug:

    Deleting backpack and creating another one in new position is not an option for my gmeplay mechanics.

    Ashley is it possible to add in multiplayer "Sync object" — interpolation mode on\off?

  • Did you sync the backpack? If yes, you shouldn't do that, you're wasting bandwidth. Use send message to pin/unpin the backpack, this will guarantee pin point accuracy in placing the backpack. All dependent object should be dependent to "main referenced position", not independently synced position.

  • Did you sync the backpack? If yes, you shouldn't do that, you're wasting bandwidth. Use send message to pin/unpin the backpack, this will guarantee pin point accuracy in placing the backpack. All dependent object should be dependent to "main referenced position", not independently synced position.

    Other players must see this backpack, without sync its bad. Make it via broadcast message with position is bad too, because on start all loot generates randomly, and it will destroy bandwith by sending for each player postions of created objects.

  • Other players must see this backpack, without sync its bad. Make it via broadcast message with position is bad too, because on start all loot generates randomly, and it will destroy bandwith by sending for each player postions of created objects.

    That is why you need to pin the backpack to your referenced position which is the character. Broadcast message is used like function/trigger which you have to send it only one time, unpin the backpack and set the position according the message.

  • > Other players must see this backpack, without sync its bad. Make it via broadcast message with position is bad too, because on start all loot generates randomly, and it will destroy bandwith by sending for each player postions of created objects.

    >

    That is why you need to pin the backpack to your referenced position which is the character. Broadcast message is used like function/trigger which you have to send it only one time, unpin the backpack and set the position according the message.

    And how in this case other players will see backpack on connect(if backpack not sync)?

  • And how in this case other players will see backpack on connect(if backpack not sync)?

    If the host is the one who created the backpack, the backpack will also created on all peer, but set the position manually and pin them. This is how you sync backpack position by piggyriding the position value of the character.

    Ashley also mentioned this before.

  • Where is it interpolating to? It sounds like you might be trying to position it on the peer, but that will be overridden by 'sync object', you have to make sure it's created on the host.

  • Where is it interpolating to? It sounds like you might be trying to position it on the peer, but that will be overridden by 'sync object', you have to make sure it's created on the host.

    Ashley No, its repositioned on host, when recieved message "drop" from peer. When backpack repositioning from -100,-100 to Player.X,Player.Y its drawn with inertion(interpolation) Peer side thinks that its slighty move and starts "smooth" it with interpolation. And we get what we see on gif above. I need just simple replace it from one position to another without sliding effect.

  • > And how in this case other players will see backpack on connect(if backpack not sync)?

    >

    If the host is the one who created the backpack, the backpack will also created on all peer, but set the position manually and pin them. This is how you sync backpack position by piggyriding the position value of the character.

    Ashley also mentioned this before.

    New items\backpacks respawns\erases with time and in case of it new players connects you propose to send for everyone newcomer messages about every loot positions?

  • New items\backpacks respawns\erases with time and in case of it new players connects you propose to send for everyone newcomer messages about every loot positions?

    Yes, doable in the form of array.asjson . However to set it up, it is not as direct as syncing the position, rather quite tedious but it'll save you bandwidth.

    If you don't mind about the bandwidth at all you can still go with syncing positions, but you have to live with the interpolation issue that you show, unless Ashley provide the "no interpolation" option for sync object.

    I think the other syncing way you can try is using instance variable. They have no-interpolation mode, so basically record you x and y in the host and have an event in common group to position to instance variable every tick, or every1/30 second depends on what you prefer but the drawback is, the object movement might look choppy, jerky or stuttery.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • > New items\backpacks respawns\erases with time and in case of it new players connects you propose to send for everyone newcomer messages about every loot positions?

    >

    Yes, doable in the form of array.asjson . However to set it up, it is not as direct as syncing the position, rather quite tedious but it'll save you bandwidth.

    If you don't mind about the bandwidth at all you can still go with syncing positions, but you have to live with the interpolation issue that you show, unless Ashley provide the "no interpolation" option for sync object.

    I think the other syncing way you can try is using instance variable. They have no-interpolation mode, so basically record you x and y in the host and have an event in common group to position to instance variable every tick, or every1/30 second depends on what you prefer but the drawback is, the object movement might look choppy, jerky or stuttery.

    Better way is optionable interpolation for sync object ofcource Ashley can you just say will it be in nearest updates or not?

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