Last active
July 6, 2022 08:41
-
-
Save tompng/17c567b2eeef43f43fc89392f705702c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
code=%(h=60;w=140;s | |
=32.chr;q=s+'rq_xkyzsugt[w | |
vc'.bytes.map{(_1+9509).chr'u | |
tf-8'}*'';l=(s*22+'code=%('+code | |
+");eval(code.scan(/[!-~]/)*'');") ▄▄ | |
.tr(q,s).split($/);v=40.times.map{[ ▟███▄ | |
2*rand-1,rand,0.2+rand,1+_1*0.05]};(0 ▐██████▄ | |
..).each{|t|cv=(1..h).map{[0]*w};v.eac ▐████████▖ | |
h{->cx,cy,r{((2*cx-2*r).ceil..2*cx+2*r ▝█████████▖ | |
).map{|x|((cy-r).ceil..cy+r).map{|y|(2* ▝█████████▖ | |
cx-x)**2/4.0+(cy-y)**2<r*r&&(x-w/2)**2/4 ▝▀▜███▛▀▀ | |
.0+(y-h/2)**2<h**2/5&&cv[y][x]=1}}}[w/2* | |
(0.5+_1+Math.sin(_2*t/4+_3)/8),h/2*(2.5-( ▄▄▟███▄▄▖ | |
_2+_3*t/40)%1*3),_4*h/16]};e=27.chr;$><<e ▗▟███████████▄ | |
+"[H"+e+"[J"+(0...h/2).map{|y|(0...w/2). ▗███████████████▖ | |
map{|x|a,b=cv[2*y,2];s==(d=l[y]&.[](x)|| ▗████████████████▙ | |
s)?q[a[2*x]*8+a[2*x+1]*4+b[2*x]*2+b[2*x+ ▐█████████████████ | |
1]]:d}*''+$/}*'';sleep(0.05)};okinawa.rb ▝█████████████████ | |
);eval(code.scan(/[!-~]/)*''); ▜███████████████▘ | |
▝██████████▛ ▝████████████▛▘ | |
▝█████████▘ ▗▄▄▄▄▐███████▀▀ ▗▖ | |
▝▜██████▟███▙▄▄▖ ▗▟███████████████▙▖▄▛ | |
▗▄█████████████▄ ▗███████████████████▛ | |
▝▜███████████████▖ ███████████████████▀ | |
▝▜██████████████▖ ▐████████████████▀ | |
▝▜█████████████ ▜█████████████▀ | |
▀▜██████████ ▝▀▜███████▀▘ | |
▝▀▜██████ ▝▜▀▀ | |
▝▀▀▘ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# code=%( | |
# );eval(code.scan(/[!-~]/)*'') | |
template=<<EOS | |
################### | |
########################## | |
############################# | |
################################ | |
################################## | |
################################### | |
##################################### | |
###################################### | |
###################################### | |
####################################### | |
######################################## | |
######################################## | |
######################################### | |
######################################### | |
######################################## | |
######################################## | |
######################################## | |
######################################## | |
######################################## | |
EOS | |
evalcode=File.read(__FILE__).split(/_+END__/)[1].scan(/[!-~]/)*'' | |
chars = ('code=%('.gsub(/./,' ')+evalcode+");eval(code.scan(/[!-~]/)*'');".gsub(/./,' ')).chars | |
code = template.gsub('#'){chars.shift||''}.gsub(/\A +/, '').gsub(/ *\n?\z/, '') | |
eval evalcode; | |
binding.irb | |
__END__ | |
h=60; | |
w=140; | |
s=32.chr; | |
q=s+'rq_xkyzsugt[wvc'.bytes.map{(_1+9509).chr'utf-8'}*''; | |
l=(s*22+'code=%('+code+");eval(code.scan(/[!-~]/)*'');").tr(q,s).split($/); | |
v=40.times.map{[2*rand-1,rand,0.2+rand,1+_1*0.05]}; | |
(0..).each{|t| | |
cv=(1..h).map{[0]*w}; | |
v.each{ | |
->cx,cy,r{ | |
((2*cx-2*r).ceil..2*cx+2*r).map{|x|((cy-r).ceil..cy+r).map{|y| | |
(2*cx-x)**2/4.0+(cy-y)**2<r*r&&(x-w/2)**2/4.0+(y-h/2)**2<h**2/5&&cv[y][x]=1 | |
}} | |
}[w/2*(0.5+_1+Math.sin(_2*t/4+_3)/8),h/2*(2.5-(_2+_3*t/40)%1*3),_4*h/16] | |
}; | |
e=27.chr; | |
$><<e+"[H"+e+"[J"+(0...h/2).map{|y| | |
(0...w/2).map{|x| | |
a,b=cv[2*y,2]; | |
s==(d=l[y]&.[](x)||s)?q[a[2*x]*8+a[2*x+1]*4+b[2*x]*2+b[2*x+1]]:d | |
}*''+$/ | |
}*''; | |
sleep(0.05) | |
};okinawa.rb |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment