Discuss Scratch

pumpking02
Scratcher
15 posts

Pen trail fade away

I'm trying to make a Tron-esque game with light trails that fade away after a while. Is there a way to make a pen trail that fades off of screen after about 3 seconds?
jokebookservice1
Scratcher
1000+ posts

Pen trail fade away

If it is made with the pen blocks, you would need to clear, and redraw slightly lighter, until it disappears.
nickydroids
Scratcher
100+ posts

Pen trail fade away

have an object at X 0 Y 0 which has the same costume as the background. then give it this script
whenIreceiveFade startsetghosteffectto97foreverstamp
this should work
footsocktoe
Scratcher
1000+ posts

Pen trail fade away

pumpking02 wrote:

I'm trying to make a Tron-esque game with light trails that fade away after a while. Is there a way to make a pen trail that fades off of screen after about 3 seconds?

Yes. Make the sprite that contains the pen be the size of the pen and the color of the pen. When the pen draws, make the sprite clone itself after every move. You will have to draw in small moves, no big moves.

Under the “when I start as a clone hat block” put this…

whenIstartasaclonesetghosteffectto0repeat100changeghosteffectby1deletethisclone

Last edited by footsocktoe (May 12, 2016 02:30:03)

Studio42
Scratcher
500+ posts

Pen trail fade away

I made a game with a trail that fades away, it uses clones:
https://scratch.mit.edu/projects/105680204/
Basically the clones fade away after a certain time. Look inside to see the code I used.
drmcw
Scratcher
1000+ posts

Pen trail fade away

nickydroids answer is the only way to fade pen without having to do a complete redraw. You can see it working here https://scratch.mit.edu/projects/15033002/
pumpking02
Scratcher
15 posts

Pen trail fade away

Thanks so much for the feedback, I edited nickydroids' and footsocktoe's ideas to make a new block, but I am having trouble making the cycles explode when they touch the pen. I have tried the
whenclickedforeveriftouchingcolor?thennextcostumewait0.1secsnextcostumewait0.1secsswitchcostumeto costume_fine

The costumes being the explosions
UltrabyteDev
New Scratcher
1 post

Pen trail fade away

How do you put a fade trail on a “Clone” instead of the sprite itself, trying to figure this out right now.
i want to have a trail for a bullet and i want it to have a trail on each individual bullet, so i have the clone bullet create a clone of the trail, but when i do:
whenIstartasaclonegotoBullet
It goes to the MAIN bullet sprite and not the clone, how do I do this? I would like some help.
deck26
Scratcher
1000+ posts

Pen trail fade away

UltrabyteDev wrote:

How do you put a fade trail on a “Clone” instead of the sprite itself, trying to figure this out right now.
i want to have a trail for a bullet and i want it to have a trail on each individual bullet, so i have the clone bullet create a clone of the trail, but when i do:
whenIstartasaclonegotoBullet
It goes to the MAIN bullet sprite and not the clone, how do I do this? I would like some help.
Please create your own new topic rather than posting on an old one like this.

Your best bet might be to make trail a clone of the bullet as well so when you create a clone and give it the trail costume it is in the same place as the clone which created it.

https://scratch.mit.edu/projects/111228685/ may help.
kittycat123684
Scratcher
4 posts

Pen trail fade away

Ok guys thanks
whenclickedsayOkforTillIsayboomersecssayBoomer

Last edited by kittycat123684 (Feb. 22, 2020 05:10:37)

ghdavnfova
Scratcher
55 posts

Pen trail fade away

kittycat123684 wrote:

Ok guys thanks
whenclickedsayOkforTillIsayboomersecssayBoomer/quotePleasedon'tnecropost
cookiecat3210
Scratcher
2 posts

Pen trail fade away

My browser / operating system: MacOS Macintosh X 10.11.6, Chrome 101.0.4951.54, No Flash version detected
/quotedefine
cookiecat3210
Scratcher
2 posts

Pen trail fade away

HEY HOW DO YOU MAKE PART OF A PEN TRAIL GO AWAY BUT THE OTHER PARTS STAYS HEEEEEEELPPPPPPPPPP
Race__car__billy
Scratcher
2 posts

Pen trail fade away

do this
whenclickedforevercreatecloneofmyselfgotomouse pointerchangecoloreffectby10whenIstartasaclonegotomouse pointerrepeat7changeghosteffectby10wait1secsdeletethisclone

Last edited by Race__car__billy (Oct. 18, 2022 17:47:32)

sushi_slamer
Scratcher
100+ posts

Pen trail fade away

this post has been necroed so much what

Powered by DjangoBB