oosyrag's Forum Posts

  • Are you using the 'Load image from URL' action for your random sprites? There is a 'On image URL loaded' trigger you can keep track of to determine how many times it fires/how many times total you expect it to fire.

  • Besides organizationally, which is completely up to you and your own workflow, layouts are best used for memory management. If you're going to be using the same set of graphical assets and sprites in all your battles, then there is no performance advantage for using a different layout per battle.

    Actually I'm not completely sure if this applies anymore with the new C3 runtime. The first instance of sprite objects are no longer required to be placed on a layout manually, but I don't know if that has anything to do with the loading of sprites into memory per layout. Someone more familiar with the new runtime please correct me if I'm wrong.

    Global Variables and Global Objects will be useful for any information you need to transfer between layouts. Additionally, the Persist behavior will be useful for when you return to your map layout.

    Families are useful to let you pick many different sprite objects at once. You can use them to simplify your events a lot, but they aren't usually critical.

  • Regarding question 1,

    You're going to have to decide on one or the other. Here is the situation: in any multiplayer game where there is latency, given a moving object, where any person currently is, is not where any other person sees he is.

    So you have to pick. If PlayerA is shooting PlayerB, does PlayerA aim where he sees PlayerB on his own screen (commonly used), or where PlayerB actually is by leading the visible player and shooting at the empty space ahead of what they see depending on their ping. You can't have both at the same time!

    There is a third case that is highly not recommended, where you try to show PlayerA where PlayerB will be X ms in the future based on ping by guessing where PlayerB is going. But if PlayerB actually changed direction, PlayerA wouldn't know until later and PlayerB would teleport on PlayerA's screen. Also you'll still have the problem with PlayerA shooting and expecting to hit where PlayerB wasn't actually was, and then you'll have to decide again to register the hit or not.

    Resources for reading:

    X-Wing: gamasutra.com/view/feature/131781/the_internet_sucks_or_what_i_.php

    Half life: developer.valvesoftware.com/wiki/Latency_Compensating_Methods_in_Client/Server_In-game_Protocol_Design_and_Optimization

    Quake: reddit.com/r/QuakeChampions/comments/7iuhlc/tech_talk_rockets_and_lag_compensation_and_some

    Reflex: reddit.com/r/truegaming/comments/2ruqba/advances_in_fps_netcode

    General: gabrielgambetta.com/client-server-game-architecture.html

    This isn't an FPS, but an MMO bullet hell which made some interesting choices regarding lag that are not "standard"

    ROTMG: t-machine.org/index.php/2012/03/28/realm-of-the-mad-god-a-great-game-interesting-monetization

    A Video from GDC a while back

    Halo: gdcvault.com/play/1014345/I-Shot-You-First-Networking

    Last but not least

    construct.net/en/tutorials/multiplayer-tutorial-concepts-579

    Honestly, the Construct manual page is one of the best ones out there. You'll notice all the different developers talk about the same concepts over and over again, and the manual gives a very good summary. Regardless, there is no "simple" way to describe it all, so I recommend just reading over and over again until it makes sense and you can understand it and you won't be a n00b anymore. While the concepts are all the same, each person would present it differently so as you go through the links maybe you'll find one that clicks with you the most.

  • You can also see how max speed was done in this example from a while ago - construct.net/en/forum/construct-3/how-do-i-8/spaceship-movement-130957 (also by r0j0).

    It doesn't use any behaviors, but you can see how it works very clearly,. It would apply very similarly to custom movement's dx and dy.

  • Try both - Use an object to predict your future motion based on your current vector, and have a camera object with a lerp towards that one.

    dropbox.com/s/jkb52blsbte0ckh/Smoothcameraexample.c3p

  • dropbox.com/scl/fi/5sxwwny0e4x04y40zf87h/canvasexample.c3p

    Example using the drawing canvas plugin to draw the circle, and a timer to control the rate it grows.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Are you using the set animation action rather than set frame? Are your animations set up correctly? Speed not 0, correct frames?

  • The basis of a grapple in physics is the revolute joint. Here is an example.

    dropbox.com/scl/fi/7pmfnzdwtgqmoqvgnljly/Physics-revolutejoint.c3p

    To get it to wrap around solids, the most straightfoward way is to make a chain of revolute joints. Basically you break up the line into many segments, down to 1 pixel each, and make them all connect to each other in order. You can do this with families and instance variables to keep track of each segment to pick the correct ones to make joints with.

  • It depends on how you are going to set it up. If you're syncing an "isMoving" instance boolean variable.

    For all the peers and host:

    + PlayerObject: [X] Is isMoving

    -> PlayerObject: Set animation to "Idle" (play from beginning)

    + PlayerObject: Is isMoving

    -> PlayerObject: Set animation to "Walk" (play from beginning)

    Then all you need is for the host to properly toggle the isMoving variable for each peer when they are moving or not.

  • You need an event to trigger peer clients to update the animation of the host sprite. You can do it a few ways, like by message or by syncing a variable. Or have some other way for peers to detect if host is moving on their own, such as storing last position and compare with current position.

  • You can set up "states" for animation. On key press, change state to "attacking". Use trigger once while true to play the animation based on the state. Use another trigger event for when your animation completes or a timer to change your state back to idle.

  • IIRC, with R0J0's paster/canvas plugins, the method was to shift the viewport, paste it to the canvas, then move the viewport back, resulting in two views. Please correct me if I'm wrong, since I never actually tried that plugin myself.

    Is this not possible with C3's drawing canvas due to the paste object action only happening at the end of each rendering frame and outside of the normal order of events and actions?

  • Try using a larger z-elevation difference? The range is from 0-100. Maybe you can't see the parallax effect if the value is too small, and the 9patch is the size of the screen.

    Also, z-elevation won't visibly show anything besides a size change if you aren't scrolling.

    Another thing is to remember z-elevation is not the same as z-order, I had been confused about that before.

  • Are you using physics, platform, or a custom system for movement?

  • Alternatively you can have two behavior states, default is random motion, second triggers when distance is greater than range, move back towards center of constraint area.