Log In  

Cart #pixular_effect-0 | 2022-09-30 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
8
(v00 09-30-22)
TO LOAD THIS PICO-8 CART, in immediate mode, type: load #pixular_effect

Hello.

Another interesting effect I have seen in some games is what I call The Pixular Effect.

It appears like this:

https://youtu.be/s_EDnDJvlw8?t=1049

In the code above Use the LEFT and RIGHT arrow keys to animate from no Pixular at zero to full Pixular at 15 and at a reasonable rate.

Use the 🅾️ and ❎ to see it running maximum speed.

I thought it was a perfect effect to show someone losing consciousness though I have seen it in other places as a kind of screen-fade and warping from one place to another.

Well I sat down with the code this morning and started to experiment, trying to recreate it. And I think I have.

Examine the code carefully and you will see how it is done, and yes, this works without requiring you to redraw the screen and uses the standard _init() and _update() functions.

It does require use of memory 0xE000-0xFFFF so as not to interfere with your current display should you turn it off.

Enjoy !

P#118231 2022-09-30 20:05 ( Edited 2022-10-01 20:57)

Cool stuff.

P#118238 2022-09-30 20:41

Thanks, @Kowalik_13 !

I hope I wrote it easy enough others can make use of it in their own code. There are a few other effects I had in my earlier S2 I need to put out here, but I'm done coding for today.

And yes, for those wondering about that biggo print statement up there, that is just the sample picture to work with. Go HERE:

https://www.lexaloffle.com/bbs/?tid=49536

To see how it's done and use the tool there to make your own pictures.

Thanks for your interest !

P#118240 2022-09-30 20:53

Cool bro. That can be used very easily to do deaths. I think mabe I'll use something like that in my game if you don't care... One example of that being used is the Vampire Survivors if I remember well.

P#118313 2022-10-01 20:23

Actually, @biteco8. I do care.

I would LOVE to know my code is helpful and in use by a fellow programmer, and with my thanks !

Please keep me posted about your game ! :D

P#118315 2022-10-01 20:34

I posted it in a thread called "Procedural World Generation", but nobody saw it, so I just use a id to called "killedim" to show it to my friends. Anyways, get your gold star ;).

P#118316 2022-10-01 20:37

Nice! I've seen this sort of thing referred to as "mosaic effect" as well.

P#118317 2022-10-01 20:40

Thanks, @biteco8 and @Logarhythm.

I did not know the proper name of it ! "Mosaic" is a much better name than "Pixular." I will change the message title and keywords that it can be easier found in the future.

P#118320 2022-10-01 20:56 ( Edited 2022-10-01 20:58)

[Please log in to post a comment]

Follow Lexaloffle:          
Generated 2022-12-04 05:50:48 | 0.071s | Q:28