Syncing Global Variables, what am I missing here?

  • Scorekeeper has the instance variables to sync up to the peers global variables. When someone is killed the host adds it to the player kills and the scorekeeper. However in-game it doesn't update the global variables.

  • remove the tags for marinekills and monsterkills on the synch variable action and remove setting their input state on the peers action.

    If the host sets the variables, they should get synched.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • remove the tags for marinekills and monsterkills on the synch variable action and remove setting their input state on the peers action.

    If the host sets the variables, they should get synched.

    Still not working for me, do I need to add something here?

  • Is it not updating for the host either ?

    I mean, when you check the debugger, on the host, is the Scorekeeper's MonsterKills variable increasing ?

  • It works for host. Everything I've tried has worked fine for host, but it's something with the peer. On the debugger scorekeeper's kills raises for host, but on peer it looks there's 2 scorekeepers. When I click on the scorekeeper option it shows

    #0

    #1

    On host it only shows #0 which gets updated. #1 is getting updated on peer, but not #0.

  • It works for host. Everything I've tried has worked fine for host, but it's something with the peer. On the debugger scorekeeper's kills raises for host, but on peer it looks there's 2 scorekeepers. When I click on the scorekeeper option it shows

    #0

    #1

    On host it only shows #0 which gets updated. #1 is getting updated on peer, but not #0.

    http://i.imgur.com/NXDrDPl.png

  • And is one of the Scorekeepers for the peer increasing ?

    If so, its something in your logic or setup causing there to be 2 scorekeepers.

    If you have a scorekeeper on the layout by default, make sure to destroy that one for the peer on start of layout, the hosts Scorekeeper should get synched and created on the peer side.

  • And is one of the Scorekeepers for the peer increasing ?

    If so, its something in your logic or setup causing there to be 2 scorekeepers.

    If you have a scorekeeper on the layout by default, make sure to destroy that one for the peer on start of layout, the hosts Scorekeeper should get synched and created on the peer side.

    Yup I had one on default. Thanks so much for your help, it's working perfect now

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