dop2000's Forum Posts

  • If you make sure that there is always the same symbol separating words (space may be the obvious choice), then you can use tokenat and tokencount expressions.

    variable currentWord=0
    
    Keyboard on Enter pressed:
     Text set text to trim(tokenat(fileData, currentWord, " "))
     Add 1 to currentWord
    

    You can also use tokenat() with newline separator to break text into paragraphs, and then break paragraphs into words.

  • SnipG We've actually discussed this with you here:

    github.com/Scirra/Construct-3-bugs/issues/1639

    I believe this bug is not really isolated to the TouchID, TouchIndex is affected as well. The problem is that sometimes "touch end" event is not triggered on certain devices, and that particular touch becomes "stuck" and is never cleared. As a result, any new touch will have TouchIndex>=1. You can add events to recognize these "stuck" touches and ignore them.

  • You can achieve something similar with a new "Drawing Canvas" plugin in C3 runtime.

  • Use instance variables. For example, add "isSelected" variable. When the first card is picked, set isSelected=true. When computer needs to select another card, search for a card that has the same animation name and isSelected=false.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • SnipG Could you elaborate on this? I suppose TouchID can be re-used on some devices (therefore may not be unique). But it's very unlikely that any device will allow having multiple touches with the same TouchID active at the same time. So it still should be a good way to identify and track different touches.

  • What's the problem?

    Spawn one bullet, set its angle of motion to (character.angle-30), spawn another bullet, set angle of motion to (character.angle), spawn third bullet set angle of motion to (character.angle+30)

  • AllanR OP never explained what he needed. And if you look at his previous posts, you'll probably lose any interest in helping him.

    It's possible to add a couple of additional events into my version to prevent the situation you described - save TouchID of the finger which is touching the movement buttons, and if this ID is no longer touching the buttons, ignore it. Same with the touch controlling the beacon.

  • AllanR Yeah, sorry, must be Firefox - it doesn't like multi-touch. Your project works fine in Chrome. The same can actually be done much easier if you loop through all active touches, in just 6 events.

  • AllanR I don't think your version is working correctly. If you touched any of the ControlsFamily squares first, you can't rotate the ship with the second touch. If you started rotating the ship, you can't move it..

    I'm guessing this is how it's supposed to work (open in Chrome):

    doptrix.com/C2/ahmtd

  • Depends on what you want this movement to look like.

    If you just need constant speed, you can do this without any behaviors:

    On every tick 
    Character X<15 : Character move N*dt pixels
    

    You can use lerp (very fast start, slows down as it gets closer to position):

    Character set X to lerp(self.x, 15, dt)

    Or try the new Tween behavior in C3 runtime, with it you can make different cool effects - acceleration, deceleration, bounce, etc.

  • dropbox.com/s/rsjjrysqt3vc9v5/InfiniteParallaxBG.capx

    See the last two events. Your background should be at least 2 times wider than window size.

  • Maybe you should lose the attitude and stop being an a-hole to people who are trying to help. You can create perfectly working multi-touch controls in C2/C3, good luck figuring this out on your own.

  • See this demo (sorting array by "HP" in column 1):

    dropbox.com/s/88wse8qyrr3ysgs/arraySort.capx

  • Did you set animation speed to 0?? It works for me. Normal mode - light blue shadow, hard mode - dark blue.

  • Instead of ranting for 2 pages you should've clearly explained what exactly are you trying to make. It's impossible to understand what's going on in your project.

    You want to move the ship with those blue and green squares (right hand), and aim by touching anywhere on the screen (left hand), correct? Why don't you use a "virtual joystick" or thumbstick? There are plenty of examples on this forum, I made one just yesterday:

    construct.net/en/forum/construct-2/how-do-i-18/how-do-i-multi-control-for-and-139160