Log In  


Cart #drakeblue_fireworks-2 | 2021-04-28 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Some fairly simple particle fireworks just for fun.
Press X to switch the screen effect on/off. For more about that see here: https://www.lexaloffle.com/bbs/?tid=41149

Every sixth of a second, 50-100 Particles are emitted at a random point on the screen with random angle/velocity determined by a tiny bit of trig. They're given colours in the top half of the PICO-8 palette (7+) and as the particles get old the colour changes according to the same mapping that the screen fade effect uses to a darker colour.
If they run out of life or become black then the particles are deleted.
There are two possible update functions for each particle - one with a wiggle :)

-- update: tidied code a bit, updated fade effect.

P#90763 2021-04-18 14:02 ( Edited 2021-04-28 11:20)

:: flavio

Nice work! :)

P#90779 2021-04-18 17:50
:: wez


P#93238 2021-06-09 10:32

[Please log in to post a comment]

Follow Lexaloffle:        
Generated 2021-10-25 06:49:46 | 0.011s | Q:17