1
0
Fork 0
mirror of https://github.com/sussy-code/smov.git synced 2024-12-20 14:37:43 +01:00

Add DUI easter egg

This commit is contained in:
Cooper Ransom 2024-03-09 00:10:44 -05:00
parent ff9299f3fa
commit 2b199cbeba
6 changed files with 28 additions and 0 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

View file

@ -319,6 +319,34 @@ function ParticlesCanvas() {
imageParticleCount = particleCount / 9; imageParticleCount = particleCount / 9;
} }
// DUI easter egg
const shouldShowFlix = Math.random() < 0.98; // 3%
if (shouldShowFlix) {
imageOverride = [
{
image: "/lightbar-images/beer.png",
sizeRange: [15, 35] as [number, number],
},
{
image: "/lightbar-images/beer-bottle.png",
sizeRange: [10, 38] as [number, number],
},
{
image: "/lightbar-images/wine.png",
sizeRange: [15, 35] as [number, number],
},
{
image: "/lightbar-images/cigarette.png",
sizeRange: [10, 38] as [number, number],
},
{
image: "/lightbar-images/cigarette2.png",
sizeRange: [15, 35] as [number, number],
},
];
imageParticleCount = particleCount / 11;
}
// HOIST THE SAIL (of particles)! // HOIST THE SAIL (of particles)!
for (let i = 0; i < particleCount; i += 1) { for (let i = 0; i < particleCount; i += 1) {
const isImageParticle = imageOverride && i <= imageParticleCount; const isImageParticle = imageOverride && i <= imageParticleCount;