This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2010-11-23 16:00:17

Brojangles
New Scratcher
Registered: 2010-11-23
Posts: 4

'Destroyed' effect without costume change?

Hi, I've been trying to make sprites which move around the game have an effect of an explosion come up when the player clicks them and they respawn, but I can't do this with a costume change on the clicked sprite because backgrounds pre define the costume of the clicked sprite. I tried using a sprite just for the effect, but I can't figure out how to get it to appear as I want it.

Offline

 

#2 2010-11-23 16:25:52

TheSaint
Scratcher
Registered: 2008-11-04
Posts: 1000+

Re: 'Destroyed' effect without costume change?

Using a sprite for effect will work. Label a new sprite with "Explosion" or whatever, and put you effect in there.

Now then, when the moving sprite ("Sprite 1") is clicked, put this script:

<when[  Sprite 1  ]clicked> 

<hide>

<broadcast[   Explosion   ]and wait c>

<end>

Then, on the "Explosion" sprite use the    <when I receive[Explosion]  block to add your explsion. Be sure to make it go to "Sprite1"!

Once the explosion is over, simply use the show block when it is back at the respawn point, and that should work.
I hope this helps.  big_smile

Last edited by TheSaint (2010-11-23 16:26:58)

Offline

 

#3 2010-11-23 16:39:01

Brojangles
New Scratcher
Registered: 2010-11-23
Posts: 4

Re: 'Destroyed' effect without costume change?

Worked, thanks

Offline

 

#4 2010-11-23 17:37:44

TheSaint
Scratcher
Registered: 2008-11-04
Posts: 1000+

Re: 'Destroyed' effect without costume change?

Your Welcome!  big_smile

Offline

 

Board footer