Skip to content

Instantly share code, notes, and snippets.

@hidex7777
Created February 3, 2024 09:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hidex7777/75580fcd565fbf44899d5ef074fb65c0 to your computer and use it in GitHub Desktop.
Save hidex7777/75580fcd565fbf44899d5ef074fb65c0 to your computer and use it in GitHub Desktop.
返り血健康法
//title: 返り血健康法(Blood Splash Health Method)
PFont ecriture;
String castor, pollux, stone;
int earth, wind;
BLEED[] blood;
void setup(){
fullScreen(P3D);
smooth();
frameRate(60);
wind = 4;
earth = (int)(height * 0.067);
ecriture = createFont("serif", earth, true);
textFont(ecriture);
fill(0);
genesis();
blood = new BLEED[pollux.length()];
for(int core = 0; core < pollux.length(); core++){
blood[core] = new BLEED(core);
}
}
void draw(){
background(255);
for(BLEED gore : blood){
gore.rebirth();
gore.presentation();
}
}
void keyPressed(){
exit();
}
void mousePressed(){
setup();
}
class BLEED{
char spirit, soul, mind;
float current, field, thrust;
BLEED(int core){
spirit = pollux.charAt(core);
soul = castor.charAt(core);
mind = spirit;
current = width - earth;
field = height + (core * earth * 1.2);
thrust = 0;
}
void rebirth(){
field = field - wind;
if(field < 0){
field = height + earth;
current = current - (earth * 1.7);
if(current < 0){
current = width - earth;
}
}
thrust = 50 * sin((field + current) * 0.003);
if(random(3000) < 1){
mind = spirit;
spirit = soul;
soul = mind;
}
}
void presentation(){
textAlign(CENTER);
text(spirit, current, field, thrust);
}
}
void genesis(){
String cain, abel;
cain =
"弾丸が緑色の悲鳴を響かせ僕の血管を駈けのぼってくるとき結" +
"び目をたくさんつけた紐に巻きつかれた聖母像は海に空いた細" +
"い穴へと滑りおちようとするものの顔が磁石で肉が電流ででき" +
"ている馬がふしだらにも雪の山頂へと曳こうと乱れるから聴診" +
"器の卵を肩甲骨に産みつけられた僕の最期の視界は緑色だった";
abel =
"軍帽が菫色の吐息を震わせ姉の産道を垂れさがってくるとき返" +
"り血をみにくくおびた鳥に棲みつかれた幼稚園は夜に浮いた薄" +
"い陸へと登りつめようとするものの骨が時計で軸が灯台ででき" +
"ている傘がいやらしくも夢の海底へと吹こうと広がるから蓄音" +
"機の扉を横隔膜に据えつけられた姉の最初の苦痛は菫色だろう";
if(random(1000) < 500){
castor = cain;
pollux = abel;
}else{
castor = abel;
pollux = cain;
}
}
//This poem is a script code for Processing.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment