Replay like Meatboy

Get help using Construct 2

Post » Mon Jan 07, 2013 9:14 am

Hi,

I want to know how can I do something like the Ghostreplay animations of Meatboy.

I want a replay ghost like I go from point A to B and press Space after that the Level reset and the ghostanimation started at the end of the animation the ghost will be stop. Is it possible? Because I want interact with the ghost later ingame.
B
4
S
1
Posts: 13
Reputation: 626

Post » Mon Jan 07, 2013 2:46 pm

The basics of it is that you save every x and y position incrementally in an array and plays it back when desired.

You might find tutorials around that demonstrate this, I remember there was a Braid example (time rewind) awhile ago. You might be able to use that to fit your needs: http://69.24.73.172/scirra/forum/viewtopic.php?t=9244&p=70772Julmust2013-01-07 14:47:18
B
17
S
6
G
6
Posts: 100
Reputation: 4,885

Post » Mon Jan 07, 2013 8:12 pm

Yes but that is only for one Player i want more Players on one screen....
B
4
S
1
Posts: 13
Reputation: 626

Post » Mon Jan 07, 2013 9:35 pm

Hmm, this would interest me too... let's have a think...
@bearboxmedia
www.bearboxmedia.com

Nintendo Wii U Developer using Construct 2
B
79
S
12
G
7
Posts: 961
Reputation: 10,717

Post » Tue Jan 08, 2013 12:04 am

More players ... More arrays ! Magic !
B
41
S
17
G
17
Posts: 2,247
Reputation: 17,436

Post » Tue Jan 08, 2013 12:26 am

A sprite and an array in a container works for this. Here's an example:
https://www.dropbox.com/s/lipjb22xahgej ... .capx?dl=0

Notice that only two events are used for the recording and playback. The rest are just standard game events.

This idea can be extended by adding some interpolation between recorded states to smooth out hiccups caused by garbage collecting or other programs running in the background.
Last edited by R0J0hound on Sat Mar 25, 2017 8:22 pm, edited 1 time in total.
B
89
S
30
G
95
Posts: 5,160
Reputation: 63,456

Post » Tue Jan 08, 2013 1:50 am

Aggh! The array instances! I can't handle the madness!

Solid job, yet again ;)
B
92
S
31
G
24
Posts: 3,191
Reputation: 32,669

Post » Tue Jan 08, 2013 1:59 am

[QUOTE=R0J0hound] A sprite and an array in a container works for this. Here's an example:
http://dl.dropbox.com/u/5426011/examples16/mario_record.capx

Notice that only two events are used for the recording and playback. The rest are just standard game events.

This idea can be extended by adding some interpolation between recorded states to smooth out hiccups caused by garbage collecting or other programs running in the background. [/QUOTE]

@R0J0hound your example made me wonder how is possible to port from CC to C2, i've ported some .cap to .capx but the results were not perfect.

The one what im trying to port was Braid's time rewind, isn't possible for HTML5?
B
96
S
34
G
29
Posts: 3,139
Reputation: 28,236

Post » Tue Jan 08, 2013 2:18 am

[QUOTE=Joannesalfa]
The one what im trying to port was Braid's time rewind, isn't possible for HTML5?[/QUOTE]

Of course it's possible ;) Instead of replaying the array forward, you step backwards, but it does come with complexity since you need to save time delays, animation frames etc.
B
15
S
5
G
7
Posts: 877
Reputation: 5,650

Post » Tue Jan 08, 2013 5:19 am

@R0J0hound Great example! Thanks!
B
42
S
10
G
7
Posts: 144
Reputation: 6,244

Next

Return to How do I....?

Who is online

Users browsing this forum: plinkie and 3 guests