iwontnamemyself's Recent Forum Activity

  • LittleStain - I didn't explain things properly. Sorry about that.

    There are 2 different objects involved.

    The first overlap picks the "enemy" sprites that are overlapping a "laser" sprite. Then the second overlap picks the "enemy" sprites that are overlapping other "enemy" sprites that are overlapping the "laser" sprite.

  • Is there an way of checking if a sprite is overlapping a sprite, which is overlapping a different sprite? What I'm trying to do is pick the sprites that contain a specific variable and check if those sprites are overlapping each other and if they are, then check if they also overlapping this one other sprite. Right now I have:

    System->pick all, is overlapping

    Subevent->System->pick all, is overlapping

    but it doesn't work all the time AND it keeps the original overlapped sprites picked and I don't want that.

  • Setting the position wreaks less havoc on the cpu. The more objects you create throughout the life of the program, the more negative the more the cpu is bogged down. You obviously won't see a difference with only one object, but when you have more than 20 spawning and being destroyed, over and over again, you can see a major difference.

    If you're looking to move it to another place on screen that's visible, you can always set it to invisible on collision, move the sprite, then when it's time, set it to visible.

  • R0J0hound - How would I accomplish your pick in all directions example for an entire row or column? The game I'm working on allows the user to shift a whole row or column at a time and the sprites wrap at the edges of the board, sort of like a 2D rubix cube. I haven't been able to figure out the matching system for it yet though and your pick in all directions example has given me the most guidance of anything I've found thus far, but I haven't been able to figure out how to get it to do exactly what I need it to.

    I'm pretty sure what I need it to do is start checking the first sprite in the row/column that has been moved, check for matches, then move on to the next sprite in the row/column. If the sprite has already been visited, skip it and move on to the next. Do you have any idea how I would go about doing that cuz I've been hacking at it for days now and haven't gotten anywhere.

  • shirogr - I'm also working on a match-3 game right now. I've actually chosen to make 2 versions to work on simultaneously; 1 with an array and 1 without an array. Each time I get stuck, I hop over to the other one and catch it up to where I was in the other one and then work on advancing with that one until I get stuck again. It's helped me get unstuck in multiple situations and has really helped me understand how things work in C2 and its idiosyncrasies.

    With that said, as far as I know, you can't "merge" arrays indices. Visually, you'll be able to, but not logically within the array.

    You may need to try something on the lines of - Once a match is detected, visually merge the cells together to create the new sprite, then delete the old values from the array and insert the new "merged" sprite value, as well as the new falling sprite values in the appropriate array indices.

    [edit] My brain starting hurting when I was attempting to make my match 3 with an array, so I downloaded the Board plugin from rexrainbow and it made things a whole lot easier. There's a small learning curve for his plugins, but the time spent learning them is far less than the time you spend being stuck. [/edit]

  • BinaryPanda - How do you resolve this?

  • Thank you rexrainbow

  • R0J0hound - Omg, that's amazing!!!! It works perfectly and it cut out 8 events. Thank you so much!!!

  • R0J0hound - It's actually a masking system. I didn't like how the sprites couldn't be in 2 opposing sides of the grid at the same time. This way it looks like the sprite is in 2 places at once.

    I've tried including an offset, like you suggested, but it still shows uneven gaps between the spawned sprites. I thought it had something to do with the amount of time it takes for the function to end and the pin action to trigger, but even when I tried putting a pin action in this function and it still did the same thing.

    Is there any way to set the max speed of a Touch gesture? Maybe to allow a swipe to move the sprites up to a certain speed, but if there's a swipe that's faster, it still only moves the sprites at the speed defined?

    I tried using lerp and, which slows it down, but if you giggle the swipe back and forth fast, it screws the entire selection up.

  • rexrainbow - good call! thank you

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • rexrainbow - I looked into slgMovementa little bit and it definitely looks like I could use it. Is there a way to get the match to ignore the sprites on the other side of the board though? I don't want the match itself to be wrapped.

  • I have an 8x8 grid full of sprites. When the user swipes the screen, the sprites in the row or column the user swiped get pinned to a clear sprite that uses drag drop. As this sprite is moved on the appropriate axis, the sprites below move with it. Once one of the pinned sprites reaches the edge of the board, it is unpinned and wraps to the other side and is re-pinned to the clear sprite and begins moving with the rest of them again.

    The problem is, when the swipe is somewhat fast, the sprites get pinned further down on the clear sprite, so there are random sized spaces between the sprites and sometimes they overlap each other.

    Does anyone know how to fix this?

iwontnamemyself's avatar

iwontnamemyself

Member since 10 Nov, 2013

None one is following iwontnamemyself yet!

Connect with iwontnamemyself

Trophy Case

  • 11-Year Club
  • Email Verified

Progress

12/44
How to earn trophies