Browse Source

feat: add pride flag style for blahaj

main
fdai7374 2 years ago
parent
commit
d2aaa0b492
  1. 24
      src/builtins/blahaj.rs

24
src/builtins/blahaj.rs

@ -31,6 +31,8 @@ impl Builtin for Blahaj {
} else { } else {
if args[0].eq("-t") { if args[0].eq("-t") {
trans_flag(blahaj); trans_flag(blahaj);
}else if args[0].eq("-p"){
pride_flag(blahaj);
} }
} }
Ok(()) Ok(())
@ -46,3 +48,25 @@ fn trans_flag(blahaj: &str) {
} else { println!("{}", lines.truecolor(245, 169, 184)); } } else { println!("{}", lines.truecolor(245, 169, 184)); }
} }
} }
fn pride_flag(blahaj: &str) {
let mut index =1;
for lines in blahaj.lines() {
if index ==6 {
println!("{}",lines.truecolor(36,84,142));
index=0;
}else if index==5 {
println!("{}",lines.truecolor(0,178,38));
}else if index== 4 {
println!("{}", lines.truecolor(255, 237, 0));
}else if index == 3 {
println!("{}", lines.truecolor(255, 140, 0));
}else if index == 2 {
println!("{}",lines.truecolor(228,3,3));
}else {
println!("{}",lines.truecolor(115,41,130));
}
index = index +1;
}
}
Loading…
Cancel
Save