broknecho's Forum Posts

  • kmsravindra you rock!

    Definitely a case where I was staring at this problem for too long and missed that the Layers were out of sync. Thank you so much.

    Also thanks for the tip on Go to Layout! Will update that.

    Thanks again!

  • The attached CAPX has 3 layouts: Login, Lobby, Game.

    The Login -> Lobby works as expected. Once all players are ready and the host clicks start game, that's where it goes weird. The "Game" layout has some random tests in it that can be disabled if needed. Things like just trying to "Create Object" to see if something would be created.

    Also, the "Signalling" group in both the Lobby and Game event sheet are very similar. I'm not sure where it's valid to use the Multiplayer -> Sync Object action if you are moving across Layouts.

    The "Peer" object is the main object from the lobby that is associated with each client and follows the real time multiplayer sample's pattern

  • Thanks for the Reply DickFace although I had no luck with the Global setting. Setting it to Yes is definitely working for my "Peer" object that is holding some properties of each player, but what's weird is that as soon as I go to the 3rd layout, the HOST can no longer create anything (even non synced local objects). It's almost like the System -> Create Object has been hijacked and is now broken.

    With Global set to true, objects that were spawned definitely carry over to the new layout. I'll post a CAPX of what I have right now to see if anyone can show me the errors of my ways

  • Hey Saf!

    Page 7 of the platformer tutorial describes a concept of "EdgeMarkers": https://www.scirra.com/tutorials/253/ho ... ame/page-7

    You could use those to trigger the enemies Jump so that they clear gaps and try to continue to follow you.

  • Furthermore, I have now just changed my GAME (3rd layout) to have nothing but some CREATE OBJECT calls and that is not working at all. These objects are new objects and are not sync'ed with the multiplayer.

    Looks to me that moving to a new layout is causing an issue with the multiplayer state. This affects the host's ability to create objects (synced or NOT synced)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hi!

    I'm trying to setup a 3 layout multiplayer design where it goes from a LOGIN -> LOBBY -> GAME.

    All the multiplayer samples just show a 2 layout design going from LOGIN -> GAME. The problem I'm running into is that as soon as I go from LOBBY to the GAME, a lot of things start to go wacky:

    • I can no longer create objects on host and have them sync to clients
    • the On Created on the client doesn't seem to be work like the samples any more

    1- Does anyone know what the correct practice is for setting up SYNC objects when going across a few layouts?

    2- Should we be able to add new SYNC objects after the first "Connect to signalling server" call?

    Anyone else have an issue with moving to new layouts?

    Please let me know if there is any more information I can provide.

  • codah looks to have a solution there.

    I would also agree that a single sprite would be better here. Then you could just make 4 animations based on the 4 directions. Once a direction is chosen, you can then use the Set Animation action to change what direction animation is playing.

    Also for smaller lists, an easier expression for random lists of things is the choose() function:

    i.e.: choose(1,2,3,4) - for direction

    OR

    choose ("SWalkUp","SWalkDown","SWalkLeft","SWalkRight") - For random animation (but keep in mind you have to then move in the correct direction as well)

  • Well technically that code you have there should run against all instances of enemy_sml_f regardless if they are created manually in the layout or using the System -> Create Object.

    Are you not noticing any of the code running?

    I do notice that you increment enemy_sml_f_count when the enemy spawns but do NOT decrement it when they die.....this might be intentional though.

    When debugging, you can use the Debug Layout tools built in construct to see some deeper information or when that isn't enough, I tend to add the Browser plugin to the layout and then use the action Browser -> Log to send my own debug text to the browsers console.

  • One way you could try is to:

    for each enemy:

    1- Set a local variable direction to a random number from 1-4 to pick a direction

    2- Compare that variable to pick the direction for each enemy.

    Depends if you want the enemy to just turn 90 degrees or possibly turn right around for a 180.

    I'll make a sample capx to illustrate.

  • Hey jminfantem!

    What movement behavior are you using on your enemies?

  • Hello!

    It seems that the Tilemap TMX importing doesn't like it if multiple Tilesets are included in the TMX file. You get the "Error parsing XML file. Check the file is a valid Tiled TMX file." message.

    Here's a sample TMX with two tilesets and it errors out as soon as you drag the TMX into construct. The second tileset isn't even used in the TMX file other than a reference to the file.

    skydrive.live.com/redir

    Given that a tilemap represents one layer which would in turn only represent one tileset, I'm pretty sure this is by design but I think it should possibly handle multiple tilesets. One idea would be if if asked:

    1- What layer you would like to Import (This is current functionality)

    2- Ask what tileset you would like to assign as the image for the above inserted layer => tilemap construct object.

    I'm just getting into heavily testing out workflow with the tilemap feature and it's an amazing timesaver!

    Any thoughts on this?

    Thanks <img src="smileys/smiley1.gif" border="0" align="middle" />