husnv's Forum Posts

  • 9 posts
  • thanks

    I mean push like this, is it possible?

  • How do I see the contents of the 'players' array, my plan is to push a player object with properties into it, is that possible?

    This is an example of an array containing player objects↓

  • Thank You,

    No. 1. I tried it, and as far as I know, Json is a static format and its properties cannot be pushed like objects

  • actually I want to create an object that has properties and is pushed into an array if possible.

    then I tried it this way:

    create a sprite object and add some instance variables, then try to push this object using array> push: here I can't push the sprite object directly? then I tried entering the instance variable, it worked, the problem I had was that when I pushed it, it wasn't wrapped into one object, which in the end would be difficult for me,

    any help is greatly appreciated, thanks

    description of each object and property in the array

    Tagged:

  • no...I want to spawn sprites when the dictianory is filled with keys, let's assume this is a websocket multiplayer game that is set up using inputform,

    how many players?: not defined, depends on how many people are playing,

    The input form has been provided to manage the game in the form of filling in the username and value, "username" which will be entered into the key dictionary and "value" will be used for the "username" method.

  • I just want to spawn sprites from the key dictionary, for example the key dictionary is filled with keys "test1" then I want to spawn a sprite with the name "test1" which means spawning a sprite taking properties from the key dictionary,

    The sprite I mean is a player object that has information, such as a name or method

  • the problem is in the loop, sorry I explained simply and straight to the point I don't really know the whole thing because some of it was helped by chatgpt

  • thank you for responding,

    I've changed my code like this, and loop for each key, but what happens after the key dictinary is filled with one key, but it spawns a sprite/player infinitely?

  • hey all, please help I'm stuck,

    how to spawn each player from key dictionary?

    For example, look at the pic, how do you spawn a sprite/player every time the key dictionary is filled?

    Tagged:

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You do not have permission to view this post

  • You do not have permission to view this post

  • 9 posts