ome6a1717's Forum Posts

  • GenkiGenga - I figured it out! I made a test cap3 file and tried everything. It all worked - synced absolutely fine until....I changed the variable to a string. Apparently (doesn't say this in the manual, it seems) you cannot sync a string variable, only a number variable.

    Makes my job a bit harder having to redesign, but at least it works.

    UPDATE - Wow, this is even more limiting than I thought...you can only sync numbers below 255 (anything above will just return 255). Just curious, is there a reason for this, Ashley?

  • Ashley - I'm wondering if you could shed some light on this?

    TLDR version:

    I'm syncing the position of a family (which is working perfectly for each individual enemy), and then syncing an "instance" instance variable on the start of the first layout. On enemy created, I'm setting the instance var to str(X) & str(Y) on ONLY the host machine. But the instance is never being set on the peer machine (it's always "").

  • GenkiGenga - thanks for the help. I'll try that and see if it tells me anything.

    I wonder if you can only sync an object if the object is on-screen?

  • GenkiGenga

    Thanks for the quick response!

    Okay, I've confirmed that changing the family to a sprite does not sync the variable. It must be a bug, then. I'll probably have to try it on a blank session and report it.

    I like the idea of the enemy count, but yeah, I'm not sure in what order the enemies are created. It might be worth a try since nothing else seems to be working...

  • GenkiGenga - no problem at all.

    I'm a bit confused, though. Doesn't the objects get destroyed on layout change?

    Basically, the way I'm creating my enemies is by using "spawner" objects that then create the enemy on the start of the layout (I do this strictly to disable enemy groups that aren't being used, and in case I change something, I can change the single sprite on my main spritesheet and it will change for everyone that's spawned). For the peer, I do the same thing but instead of creating an enemy I delete the spawner.

    I am, however, trying to sync a variable for a family. That could be why it's not working.

    So here's a possible better question (because this would save the syncing bandwidth if I could figure out a better way to do this) - Instead of setting an instance to the X and Y position of an enemy, what is something I could set a text variable for each enemy on both the Host and Peer sides that would be 100% fool proof?

    And if there is none, I'll try syncing every enemy individually with the instance variable and see how that goes.

  • Another new title on Steam!

    Loyalty and Blood: Viktor Origins

    http://store.steampowered.com/app/62432 ... r_Origins/

  • GenkiGenga - sorry to bring you back into this, but I can't find any appropriate documentation on syncing variables. Any idea on the best way to do this?

    Sorry for the shameful bump

  • donald Cela - I, personally spent anywhere from 1-4 hours a day working on it (with various days of NOT working on it). I can't vouch how long it took the artist, but he did everything incredibly quickly. The music took me a couple weeks, and the sfx a few days.

    angelo - thank you! We're very proud of it. And honestly, Ashley and Tom, we couldn't have done this without such an amazing piece of software. Working in Construct makes things so easy.

    We've talked about buying an apple pc to export a mac build, but just haven't got around to it.

  • Sorry to reprise this, but I'm now getting some interesting issues with Syncing the enemies.

    On start of the game, it has a single event that syncs the enemy family. Once you're in the game, you can connect to a room via menus, and join in. Once you start a new game, the enemies seem fine. As you continue on through new layouts, the enemies start having weird behaviors (ie some of the positions overlap each other on the peer machine until the peer attacks an enemy). Then the enemies created weren't being created on an exact X and Y, so when I call an "on created" event for the enemies, I set an "instance" variable so I can call each enemy on both machines. However, due to the nature of the enemies being created, the X and Y start to differ the more the game goes on.

    So I thought I'd sync the instance "instance" variable for the enemy family. Then on enemy created, I set the "instance variable" to the X and Y position if you're the host. However, that's not syncing to the peer player, and the instance is just forever "".

    Am I using sync variable incorrectly? And more importantly, why are some of the enemies being created on each other instead of their original position?

  • facecrime - thanks! It was mostly me and an artist. I hired a writer to do the story and some dialogue, and my business partner took care of some of the backend (steam achievements, mouselock, etc.). Overall it took us a little over a year, I believe.

    Was good fun, though

  • Hi all,

    Just wanted to let everyone know our new title "Loyalty and Blood: Viktor Origins" has just been released on steam.

    http://store.steampowered.com/app/62432 ... r_Origins/

    This is a prequel from the first Viktor title (which was ALSO done with C2). Would love to hear what you guys think.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • GenkiGenga - I have a feeling there's going to have to be a LITTLE compromise with a MP game. I'm okay with the host dictating that. I'll let you know how the rest turns out!

  • GenkiGenga

    That's a really good point - I hadn't considered collisions like that.

    I could always sync an upgrade, thought, couldn't I? (ie Upgrade.isTaken = 0, if overlap set to 1). I'll have to play around with that, for sure though. The game will be limited in that regard, anyway, so it won't be TOO much to figure out.

    Thanks for all your help, and I'll definitely keep you posted!

    Steve

  • GenkiGenga

    Actually I only have ~150 with JUST peer input. I'm not syncing the player objects due to lag on the input of the peer side. I'm basically setting variables on a player object to 0 or 1 based on whether a button is DOWN or UP, and then sending a message to the other player that "this player just pressed this button". When you let go of a button, I'm syncing the player position, as well. This way both players have absolute control of their character without having to worry about lag.

    That's good to know about the kb thing! I might be able to keep this idea then

  • raz2002 - truthfully, you can't really see what breaks and bends in multiplayer. I live in the US - our internet is nearly unparalleled. Most people here have incredibly fast connections. It makes it hard to know what other people who aren't so fortunate will deal with when playing our games.