Sliding background image in

Discussion and feedback on Construct 2

Post » Thu Aug 15, 2013 12:55 pm

Hi folks!
I am working on an interactive story book for kids. Please can someone tell me what is the best way to slide a new page into the background and ensure that the previous background image is destroyed so as to avoid memory bloat. I have a next page button and prev button. Clicking on either loads (slides) main background image in from left or right. I might consider other effects like fade in if it's easier.
Any help appreciated thanks!
B
9
S
1
Posts: 61
Reputation: 929

Post » Thu Aug 15, 2013 11:40 pm

check (search) for a thread about "jimi hendrix timeline", there's a capx I think could help
B
12
S
3
G
1
Posts: 347
Reputation: 2,866

Post » Fri Aug 16, 2013 7:52 pm

Thanks Ghost but couldn't find anything under that search.
B
9
S
1
Posts: 61
Reputation: 929

Post » Fri Aug 16, 2013 8:45 pm

Could you give the page a bullet behavior? When it gets within a few pixels of the edge, turn off the bullet and snap it to 0,0.

(a few pixels because when it's moving it may be jumping several pixels at a time. you woul dhave to adjust so it didn't snap backwards.)

Edit: Oh, and when you perform the snap, you also delete all the old page underneath.Paradox2013-08-16 20:47:33
B
230
S
62
G
33
Posts: 902
Reputation: 40,319

Post » Fri Aug 16, 2013 11:15 pm

found it:

http://www.scirra.com/forum/slideshow-lerp-how-to-reposition-canvas-On-start_topic72634.html
B
12
S
3
G
1
Posts: 347
Reputation: 2,866


Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 8 guests