VikasSanstha's Recent Forum Activity

  • Yes, I want to run through the values, compare them to len, and use only certain ones, but I have not been able to figure out how to make this work in my project. I only want to have one list. Many thanks for any assistance.

  • Thanks for the reply.

    I only want to have one list. There is one list with hundreds of words, and I would like to have settings for 3 letters, 4 letters, 5 letters, etc. up to 10 letters eventually, so using separate lists would be very inefficient and time-consuming and complicated for me to manage. Plus the default state of the game is to draw entries from the entire list, utilizing all lengths of words.

    Is it not possible to filter an array based on character count, using len or some other method? If so, I will abandon this idea.

    If this kind of filtering is possible, it opens many possibilities for me, like presenting only the words that begin with a certain letter. It's also relevant to many other educational activities that I've been creating, so I'm very keen to understand how array filtering works, if it is possible. Thanks.

  • Hello friends,

    I have a spelling game where the words are being drawn from an array, and the words vary in length from 3-8 characters. I would like to create two different modes - normal and easy, based on character counts - without creating two separate projects or arrays.

    dropbox.com/s/5bbsm5gveebmm0a/spell.c3p

    I stripped out the pictures just to make it smaller. I've included a text box with the target word for testing purposes.

    I am imagining that I could invoke a mode using a variable, that reloads the array and filters entries based on character length. I would like to have a "normal" mode that uses all entries, and an easy mode that uses only entries up to 4 characters long. I would provide the user with a couple icons for normal and easy, and they could switch between the two modes. It would just invoke the filtering.

    I would much prefer to stay with the same one array for both modes, filtering the same contents rather than creating additional arrays.

    I tried to set a len condition, but I don't understand how to tell the system to only use array entries that fit a certain criteria.

    Currently the letter blocks are baked into the layout. I would much prefer if the blocks were created dynamically, the same way that the slots are. Ideally there would be two options for how to handle it, either backend options for me for how to configure things for export, and/or user-selectable options during game play:

    1) The number of letter blocks matches the character count of the target word, and...

    2) I explicitly declare the number of letter blocks

    I have now spent more than six hours trying to do only this, without success. I know how to make the boxes and do the offset, but the resulting boxes don't get tied into the rest of the mechanic properly.

    Thanks very much for any guidance. Much appreciated.

  • I was able to get the picture version working myself. Thanks again!

  • Thanks so much! I am very grateful for your generosity.

  • Hello friends,

    I have this spell-the-word game that I purchased from Envato. I have customized it quite a bit, changing the appearance and some functionality, and adding other functionality.

    It was originally made using two text files for the questions and answers. I would much prefer to use an array, and I wanted to conquer the challenge of converting it to an array to learn from it. Many hours and versions later my attempts have been fruitless, so I would greatly appreciate some help.

    My array is already in place, and I have it working fine using the first question and answer, but no advancing. It does advance fine, but since I explicitly declared the question/answer (array.at with an index number instead of variables), it just repeats.

    I would also really like ability to use an image file in place of a text question - a separate version, not both functionalities in one. I envision a column in my array with the name of the image file to be used, matched to the answer. Then I put those images under "files". There would be no text questions. This would be extremely helpful if anyone could help. The version I've uploaded here, using sentences, is good for children who can read, but I really want to have another version where there is just a simple visual cue - e.g. a picture of a dog, and the student has to spell dog.

    Thanks again!

    Here is the project file. I have added all the groups and comments, so they may not be 100% accurate.

    dropbox.com/s/0deftpe1gvuyln0/Speller%20v7.c3p

  • First thing, don't call randomize after a wait action on start of layout. Move it to event 2 instead, as you have no way of knowing for certain if the Ajax request will complete in .0001 seconds or 10 seconds.

    What is your default array size? From what I can see, your randomize loop will delete all your array x indexes after being run once. The second time, the loop will run for 0 to -1, since your array width will be 0 by then.

    Thanks, it's x=5. now I understand, I'm deleting everything from the array, so if I want to refresh it with the same content, I will need to recreate that content first, right? Make a sub-function that repopulated the array?

    That's not what I really want to do in any case. I will just move on to the next y row after the user has satisfied some requirement.

  • I have it working fine when the function is called at startup, but it doesn't work when triggered by a button click. I don't understand. Thanks for any assistance.

    dropbox.com/s/oqdj6m2xjlf0zti/random.c3p

    I would also really like to put each letter into it's own text box, but I have failed miserably in my attempts to do this. Any guidance would be appreciated.

  • Thanks to both of you for the help. I think I can run with this. Very much appreciated!

  • It's quite simple. Add Timer behavior to some static object on the layout, or create an invisible sprite for that.

    Run this action once, for example in "On start of layout" event:

    Sprite Start timer "spawn" for 1s (regular)

    If will trigger "Sprite On Timer" event every second, which you can use to spawn hearts.

    Thanks very much. I have it working. When I do it this way, with create as opposed to spawn, am I not creating instances? When I set it to spawn it was making copies as they were falling.

    I can see it's much more effective than every x seconds, easy to pause, etc.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Allan, I have really been struggling trying to figure out how to execute the "create a heart every X seconds" by using a timer object instead of the every x seconds action. I would greatly appreciate any assistance.

    This is part of a bigger game where I'm using a lot of the every x seconds commands, and they are not behaving well with game restarts, etc. I know I need to be using timers, but I've struggled with it, and I haven't found good examples as it relates to spawning.

    Many thanks for any assistance.

  • this is how I would do it...

    https://www.rieperts.com/games/forum/onlyHearts2.c3p

    I made it so that you can only select each color once, but it doesn't have to be that way.

    Thanks so much Allan! This is fantastic, and so much more concise than I even thought possible. Pick by evaluate was exactly the kind of functionality that I was saying to myself "this is what I need - a combined pick instance and compare state." I've never used it or frankly even noticed it, so that's a revelation, I will have to become much more familiar with it. Even more awesome is the picked count, which is a system expression I take it. That will be incredibly useful for the kind of content I create (educational games). Thanks again.

VikasSanstha's avatar

VikasSanstha

Member since 24 Jul, 2021

None one is following VikasSanstha yet!

Trophy Case

  • 3-Year Club
  • Forum Contributor Made 100 posts in the forums
  • RTFM Read the fabulous manual
  • Email Verified

Progress

6/44
How to earn trophies