R0J0hound's Forum Posts

  • The tilemap doesn't split up it's image into seperate images, so you'd need to consider the total size of the image not the tile size. That size limit has to do with what webgl and your graphic card supports.

  • There's a system condition that will tell you if the game is being run on a mobile device or not. Look in the manual for more details about it.

  • Well, assuming you have all the words in a dictionary you should be able see if any word is in the dictionary with a simple "has key" condition.

    You then can roughly find all six letter words with:

    var letters="abcdef"
    var count= len(letters)
    for l1=0 to count-1
      for l2=0 to count-1
      if l2 <> l1
        for l3=0 to count-1
        if l3 <> l1
        if l3 <> l2
          for l4=0 to count-1
          if l4 <> l1
          if l4 <> l2
          if l4 <> l3
            for l5=0 to count-1
            if l5 <> l1
            if l5 <> l2
            if l5 <> l3
            if l5 <> l4
              for l6=0 to count-1
              if l6 <> l1
              if l6 <> l2
              if l6 <> l3
              if l6 <> l4
              if l6 <> l5
                var word= mid(letters,l1,1)&mid(letters,l2,1)&mid(letters,l3,1)&mid(letters,l4,1)&mid(letters,l5,1)&mid(letters,l6,1)
                if dictionary has key: word
                  add word to wordlist[/code:2i99mh1e]
    Different length words can be done similarly.
    
    Now that's an easy to understand solution it just can be tedious.  There are ways to simplify it quite a lot, and here's an example using a recursive function to make that much more compact.  I probably won't be able to explain it well enough to be helpful.
    [url=https://dl.dropboxusercontent.com/u/5426011/examples35/dict.capx]https://dl.dropboxusercontent.com/u/542 ... /dict.capx[/url]
  • You have it correct, but looking at the algorithm I think a and b need to be both greater than zero.

    As it is with a=0 and b=9

    the "while" starts with 0 <> 9

    and since "a>b" isn't true with "0>9" then the else is run that subtracts 0 from 9

    And it repeats the while. Notice a and b are unchanged for the second iteration so you have an infinite loop.

  • Search for "gesture recognition" there's some examples and a plugin that may be useful.

  • boulerzzz

    It's different, when you type it in C2 it's a expression and when you put it in your json data it's text, which is the same as if you put your expression in quotes. So basically json is just data and not expressions.

    I guess I'm not understanding the purpose of the dictionary and how you want to use it, since this seems overly complicated.

    My guess is you want to lookup if "abcd" is in the dictionary so you'd need to convert that to " l1&l2&l3&l4" first before looking. Surely there's a simpler approach?

  • It probably could be improved by just having the box match the player's speed. next maybe refining when to start pushing.

    I seem to recall some examples posted before. Maybe they would help?

  • The keys are just text so maybe you could just set the key's to be like "abcd" to begin with?

    I mean you could convert the text "l1&l2&l3&l4" to "abcd" using the replace() expression, or even the reverse. Would that help?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Irbis

    This doesn't split up the texture to separate frames and you could use spritesheets where images aren't arranged in a grid if you want with this.

  • If you google "spritesheet" you'll see the type of images this could be used for. Typically you'd need to split those images up to use. This plugin just lets you specify a rectangle of the image and use that instead of the whole image at once.

  • Ken95

    The process? It's basically just finding the intersection between lines a bunch of times. The objects have a border made up of lines and the ray is a line. You can just place the lines of the objects manually or use math to place them.

    It finds all the lines that intersect the ray, then uses the intersection closest to the start of the ray. From there you can calculate the normal of where the lines intersect and in turn calculate the reflection angle. Then it's just a matter of setting the ray to be from the intersection going at the reflection angle and repeating the process a number of times.

    The calculating of the line intersections and reflection angles is easily found in a search engine.

  • You could check the value of number%1. If it's 0 it's an integer, otherwise it's a float. Alternatively you could convert the number to a string and use a find to see if there's a point in it.

  • There has been a topic on webgl2 before where Ashley indicated what could be used by C2 from webgl2. That texture thing was the main useful thing as I recal but otherwise nothing much else. I'd have to find the topic to get a better explanation.

  • Looking at the pseudo code for that algorithm it looks like it's done with just 32bit variables, so there's no issue there. Beyond that you'll need to use a plugin that provides bit operations or just use js directly. But if you were to use a plugin isn't there one that does sha256 already?

  • Pretty much just a improvement with tiling non power of two (npot) textures. By improvement I mean it'll look better. Right now npot textures are stretched onto power of two textures before it can be tiled.