oosyrag's Forum Posts

  • Interesting... looks like there are a lot more spaces in your file. I disabled the check for json file so it should work fine now. Can you confirm?

    Edit, used another method to perform the check. Should still work fine.

  • Completely up to you, and there should be absolutely no discernible impact in terms of efficiency or performance.

    Events give you more control, should you require it.

    You can also use includes to organize event sheets and get rid of clutter as an option.

  • Any data you wish to share among all peers must be communicated somehow, either via the built in sync or by messages.

    Once a peer receives the data, it is up to the local client how to store and display it.

    In the case of an MMO, depending on your scope, you might want to keep in mind the frequency and size of broadcasted updates as to not overload the host's bandwidth (remember that bandwidth loads scale exponentially with number of players).

    You can use global variables and layers to persist across layouts. Some objects are naturally global like array, others like sprites you can add the persist behavior to.

    This is when utilizing the built in multiplayer plugin. If you are using an external backend service, you have many different options available depending on the chosen provider. If you are trying to make an MMO, I would definitely suggest a backend service as optimal.

  • Good practice with asynchronous data retrieval is always to build in a timeout and error handling, with the option of (or automatic) retrying. The logic process of what happens in the event of an error is entirely up to you.

    I've never had problems with local storage, but my sample size is small. I wouldn't normally worry about it besides setting up an error/debug notification in case it fails, so that end users at least have some sort of idea what happened and can report back. If it becomes a common problem, then I would look into it more closely.

    Generally speaking, if you are unable to load your saved data, the game should probably treat it as if there was no saved data, and in that case progress would indeed be reset.

    Ideally you would have their progress saved on the cloud (Google play services can facilitate this) but that adds another layer of complexity.

  • Hm can you upload your json file for me to look at?

    I had it only accept arrays exported as the Array.Asjson expression, which tagged them as "c2array". Maybe if you saved directly from the new array editor the format may be slightly different. (I don't currently have access to it)

  • Honestly if you understand the implications and know what you are doing, there shouldn't be any harm. Although it is pretty standard and common among netcode implementations to have some sort of buffer, for the aforementioned smoothing out of latency issues for a more consistent experience for peers at low latency levels.

    It will seem more responsive under good conditions, but any intermittent packet loss or jitter will be more pronounced when it does occur.

  • Use Array - Delete Index - Array.Indexof(CardYouWantDeleted)

  • Had some time to burn so I put this together if you're still interested - https://www.dropbox.com/s/of8uwu07mx2iq ... r.c3p?dl=0

    Load a csv or json file from local drive to import into a C3 array, and you can export again to json or csv.

    Basically does what rex's plugin does, without needing the plugin.

    It only works with 2 dimensional arrays though.

  • It is for interpolation for smoothing out jitter and/or packet loss.

    https://www.scirra.com/tutorials/892/mu ... pts/page-6

    Roughly speaking you can think of it as the engine having 80ms worth of artificial latency - all peers under 80ms will percieve the same level of responsiveness from the host, and the player/host ideally won't notice any network lag unless the actual ping (or time between updates) becomes greater than 80ms.

  • The simplest (recommended) way would be to use rex's plugin.

    The manual way to do it would be to make a few events to export and import csv yourself.

    You can use a loop for each element and the browser object's append to a file action, inserting commas and newlines in your loops where appropriate. To import it back in, you can parse the csv back in with tokenat. It is fairly straightforward, but probably not the easiest thing for a beginner.

  • It is indeed x>y>z (or z>y>x, depending on your point of view)

    It will start at X=0, Y=0, go through all the Zs. Then Y=1, and all the Zs again.

    So: (xyz order, 3x3x3 array)

    000

    001

    002

    010

    011

    012

    020

    021

    022

    100

    101

    102

    110

    111

    ect...

    If you want to see for yourself, try the following:

    + System: On start of layout

    + Array: For each XYZ element

    -> Text: Append newline&?Array.?CurX&?Array.?CurY&?Array.?CurZ

  • Here is an example I had for a simple stepping/grid movement system. I just added an additional condition to each movement key to constrain or set limits for the movement. In this case it is 3x3 space like the game example you mentioned.

    https://www.dropbox.com/s/j5ghk49epzo5k ... .capx?dl=0

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Choose is limited to a fixed set of numbers. If you need a flexible set, an array is the best choice.

  • One solution for this is to have your spaceship actually static in terms of position, and have your controls actually move all the other objects around it and rotate the entire layout.

    Another involves setting up a custom pathfinding system that allows for node positions to be pinned/updated with movement of your ship. This can be done in conjunction with the built in pathfinding behavior, as that allows you to access the node coordinates. Basically use the pathfinding behavior to calculate the path, then your own movement system by creating invisible helper objects at each node that are pinned to the ship, and have your NPC's ( which are also pinned to the ship) move towards each node object in succession.

    Third way is just to recalculate pathfinding every tick. Definitely not recommended, unless the scope of your game is very, very, small.