Bl4ckSh33p's Forum Posts

  • I thought about trying this, too

    But I have a problem with syncinc. I set it up the same for some objects but only half of them appear on the peers.

    e.g. Ships (players) are synced fine, same applies to the laser shots/bullets the server creates but the on collision spawned explosion (has the same sync object action like the other objects) never appears on the peers.

    Is there a way to check whats wrong with the synced objects or see if they are really synced?

    Here is an example:

    FXExplosion is never showing up on peers, only on the host. But why?

    The only difference I can think of is the FadeIn behavior set to disabled by default, set to fade out over 1 sec when activated. And its activated after Animation:Default is finished to remove the object. But that should not break syncinc?

    (laser is a bullet created every 0.5sec when holding down mouse1 and synced to everyone. Maybe this is too much to sync and bullets appear "laggy" sometimes even if I have only 30-60ms pings. I thought about creating them on the peer AND host but just check the hosts version for collisions but dont know if this would work.)

    As far as I can see from the ghostshooter example the lag compensation works for instant hit bullets/lasers - but does this work for bullets which fly a while before hitting anything? I dont know if it works or how to set it up. :/

  • Would be nice. I have a problem with syncinc. I set it up the same for some objects but only half of them appear on the peers.

    e.g. Ships (players) are synced fine, same applies to the laser shots/bullets the server creates but the on collision spawned explosion (has the same sync object action like the other objects) never appears on the peers.

    How can I check whats wrong with the synced objects or see if they are really synced?

    Here is an example:

    FXExplosion is never showing up on peers, only on the host. But why?

    The only difference I can think of is the FadeIn behavior set to disabled by default, set to fade out over 1 sec when activated. And its activated after Animation:Default is finished to remove the object. But that should not break syncinc?

    (laser is a bullet created every 0.5sec when holding down mouse1 and synced to everyone. Maybe this is too much to sync and bullets appear "laggy" sometimes even if I have only 30-60ms pings. Does lag compensation work for such bullets or is it ok to create them on the peer AND host but just check the hosts version for collisions?)

    As far as I can see from the ghostshooter example the lag compensation works for instant hit bullets/lasers - but does this work for bullets which fly a while before hitting anything?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hi! Just searched for selecting text in an input object and it seems the default object cant do this. I willt try your plugin but it would be great if Ashley could add this to the default plugin.

  • Right, but I added a keybinding to show/hide it for the Host to have some debug info and a input line to send/broadcast a message to all players.

  • Hi. I just added some debug objects for the Host in my new game and noticed there seems to be no check if form objects are visible.

    Is there some kind of workaround or is it possible to add this with an upcoming update maybe?

    Right now I check only a textobject (debuglog) and if it is not visible all elements (including the form elements with initial visibility=hidden) are shown. This seems to work but if you dont have/need a text object there is no way to do it?

  • I tried it with a simple rectangle and just used:

    On Arrow Collision with object HUD > Set Arrow Y to Arrow.Y-130 (the hud height). It seems to work fine in most cases, only sometimes a small "jumpy" behavior can be noticed. Do you know a "better" solution to keep the arrow out of the region at the bottom? (It will be more difficult if the hud is not just a rectangle like in the great paint image above)

  • Hi. I played around with blend modes for quite some time but could not manage to create the desired effect. Does anyone know or if this is even possible with blend modes?

    I have a background image, a tiled background with transparency in the middle and a text object which scrolls from bottom to top but it should be only visible if it is inside the area of the tiled bg and "cut off" below and above the tiled bg. Any ideas?

  • Thats it! Thank you very much!

    It works fine for the viewport (viewable area) and shows the indicator to let you know where you need to go to come back to Object1.

    I thought this would be way more complicated.

    Update: I played around with it a bit and changed the sprite origin for the indicator object to keep it more in the viewport when moving around but the edges (I used a arrow image >) are often outside of the screen. Is there something like "Bound to Layout" behavior for the viewport to keep it always on screen or does anyone know a simple way to keep it always in sight completely?

    /edit: If I add some kind of HUD at the bottom of the screen it would be great if the arrow could always stay in the "game" area above and not overlap the HUD/UI.

    Maybe with collision checks to keep it above?

    Example image:

  • Thanks for the hint with ctrl+alt to get alt working

    But it sounds like a bug that it does not work otherwise. Maybe Ashley could take a look at it?

  • Hi. I am working on a multiplayer game and added some "move to layer" actions to the common group (peer+host). But as soon as I move them to the layers the objects disappear. The layers are set to Visible and other objects on these layers can be seen. And if I disable the "move to layer" actions it works fine. Any ideas why they disappear if I move them to a layer?

    /Update: oops! I think I found the problem. The Layer#4 has 0,0 Parallax for the UI and all other layers have 100,100 (Default). When I set the UI Layer to 100,100 its working.

    So for moving UI Elements above players it seems I need another extra layer with the same parallax setting as the player object.

  • Me too, Beaverlicious!

    And I learned some more things about the Multiplayer Plugin and how to use setbit/getbit for controls.

  • Hi! I am working on a multiplayer game right now and added controls for peers and hosts. (copied many parts from the game tutorial and edited a few)

    I want the players to constantly shoot bullets when they hold down Mousebutton 1 and the host creates the bullets (synced object). Do they need some kind of lag compensation like in the example or is this only viable when using things like lasers/instant hit projectiles (like in the example game)?

    But if you should use it how is a good way to implement it for multiple bullets which may travel a while before they hit anything?

  • I tried my new game in preview mode in firefox and got this one when joining a room (chrome as host, firefox as peer & firefox as host + firefox peer):

    Javascript error!

    Error: RTCPeerConnection constructor passed invalid RTCConfiguration - missing url

    http://192.168.1.101:50000/c2mp-peer.js, line 127 (col undefined)

    This is likely a bug in Construct 2 or a third party plugin or behavior - please report it to the developer. Subsequent errors will be logged to the console.

    its not happening in chrome+chrome

  • Hi! I noticed something strange when testing my new game today. On the default debug page the viewport values for the layers are constantly changing and i have about 20-35% CPU Usage and around 40-45 FPS. But as soon as I switch to the "Profile" tab where no viewports are shown I have 0-3% cpu usage and 60 FPS (as expected). Its just a basic background, a few sprites and one sprite with rotate behavior.

    I did not notice this the last times I used debug mode, maybe its a new issue in r176?

  • Hi! May I ask how you made the minimap? Madguy