From 76e630ccd9004fce7223df94a531af2ba2a0933d Mon Sep 17 00:00:00 2001 From: Maxine Filcher Date: Sun, 10 Jan 2021 16:14:34 -0800 Subject: [PATCH] added basic string printing --- heartGenie.go | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/heartGenie.go b/heartGenie.go index f62eb38..4021cad 100644 --- a/heartGenie.go +++ b/heartGenie.go @@ -300,10 +300,50 @@ func whSp(in int) { switch { case y <= 20: smHeart(x) + wordFuckery(x, y, *words) case y <= 40: medHeart(x) + wordFuckery(x, y, *words) case y <= 60: lrgHeart(x) + wordFuckery(x, y, *words) + } +} + +//TODO make it pretty +/* +func color(wIn string) { + + for i := 0; i <= 8; i++ { + switch i { + case 0: + brush := colorize.New("Black") + brush.Paint(wIn) + + case 1: + + } + } +} +*/ + +//TODO handles words n stuff i guess +func wordFuckery(in int, hearts int, words string) { + + //take number of hearts + //divide by number of words + //display word box if count is at a certin threshhold + + //s := strings.Split(words, " ") + + x, _ := pos(in) + + switch hearts { + case 5, 10, 15, 20, 25, 30, 35, 40, 50, 55: + for i := 0; i <= x; i++ { + fmt.Print(" ") + } + fmt.Println(words) } } @@ -315,6 +355,7 @@ func main() { whSp(x) x-- + } }