Visualing a finger swipe effect?

Get help using Construct 2

Post » Mon Aug 19, 2013 10:16 am

Hello again,

I've been trying to replicate the effect of visualizing a swipe across the screen like the ones you might have seen in Cut the Rope and Fruit Ninja:



While i was trying to figure out how these effects might have been done i came to the conclusion of two different approaches. Either you use vector graphics with a filled/stroked line with a variable sized stroke around it, OR, you use a succession of raster images tightly packed:



There are probably other, better, ways to go about this and i was hoping to get some input on the matter. Are any of these ways valid or is it better to try and calculate the distance between each two points and draw a line? If so, how can i get those lines as sloping graphics as you can see in the "blade" shapes of the above games?

Since Construct 2 doesn't have any support for vectors i decided to try out the raster approach with this example:

Swipe.capx

While doing so i got the trail wrap-up effect to work as i wanted but the objects placed in succession are way to far apart as you can see with the large gaps in between them. This got me wondering about the frame rate that C2 can perform since, while touch down, i create a new object and place it at the touch X/Y.

Anyway, please take a look at the attached file and give me your thoughts about how to approach this. Thanks!
B
7
S
2
Posts: 38
Reputation: 555

Post » Mon Aug 19, 2013 10:39 am

From another topic (not made by me):

slash effect
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Mon Aug 19, 2013 10:46 am

Wow! Less code and works much better... kinda disappointed of myself right now. =(

Thanks for the link though. ^^
B
7
S
2
Posts: 38
Reputation: 555

Post » Thu Aug 17, 2017 6:46 pm

@LittleStain Hey any chance you could upload the capx again? :)
Image
B
28
S
7
G
1
Posts: 105
Reputation: 2,676


Return to How do I....?

Who is online

Users browsing this forum: lukewasthefish, marc254, Mayfly, tarek2 and 18 guests