Modifier indicators

This commit is contained in:
Nox Sluijtman 2022-08-29 22:23:58 +02:00
parent c8e3ea881c
commit b650bbb333

18
main.go
View file

@ -113,16 +113,16 @@ func main() {
if advantage { if advantage {
color.Yellow("Rolling %s saving throw with advantage...", saveString) color.Yellow("Rolling %s saving throw with advantage...", saveString)
fmt.Printf("x: %d\ty: %d\n", X, Y) fmt.Printf("x: %d\ty: %d\n", X, Y)
fmt.Printf("Without modifier: %d\n", planeResult) fmt.Printf("Modifier: %d\n", result-planeResult)
color.Green("%d\n", result) color.Green("%d\n", result)
} else if disadvantage { } else if disadvantage {
color.Yellow("Rolling %s saving throw with disadvantage...", saveString) color.Yellow("Rolling %s saving throw with disadvantage...", saveString)
fmt.Printf("x: %d\ty: %d\n", X, Y) fmt.Printf("x: %d\ty: %d\n", X, Y)
fmt.Printf("Without modifier: %d\n", planeResult) fmt.Printf("Modifier: %d\n", result-planeResult)
color.Red("%d\n", result) color.Red("%d\n", result)
} else { } else {
color.Yellow("Rolling %s saving throw...", saveString) color.Yellow("Rolling %s saving throw...", saveString)
fmt.Printf("Without modifier: %d\n", planeResult) fmt.Printf("Without modifier: %d\tModifier: %d\n", planeResult, result-planeResult)
color.Green("%d\n", result) color.Green("%d\n", result)
} }
@ -132,16 +132,16 @@ func main() {
if advantage { if advantage {
color.Yellow("Rolling %s check with advantage...", skillString) color.Yellow("Rolling %s check with advantage...", skillString)
fmt.Printf("x: %d\ty: %d\n", X, Y) fmt.Printf("x: %d\ty: %d\n", X, Y)
fmt.Printf("Without modifier: %d\n", planeResult) fmt.Printf("Modifier: %d\n", result-planeResult)
color.Green("%d\n", result) color.Green("%d\n", result)
} else if disadvantage { } else if disadvantage {
color.Yellow("Rolling %s check with disadvantage...", skillString) color.Yellow("Rolling %s check with disadvantage...", skillString)
fmt.Printf("x: %d\ty: %d\n", X, Y) fmt.Printf("x: %d\ty: %d\n", X, Y)
fmt.Printf("Without modifier: %d\n", planeResult) fmt.Printf("Modifier: %d\n", result-planeResult)
color.Red("%d\n", result) color.Red("%d\n", result)
} else { } else {
color.Yellow("Rolling %s check...", skillString) color.Yellow("Rolling %s check...", skillString)
fmt.Printf("Without modifier: %d\n", planeResult) fmt.Printf("Without modifier: %d\tModifier: %d\n", planeResult, result-planeResult)
color.Green("%d\n", result) color.Green("%d\n", result)
} }
@ -151,16 +151,16 @@ func main() {
if advantage { if advantage {
color.Yellow("Rolling %s check with advantage...", statString) color.Yellow("Rolling %s check with advantage...", statString)
fmt.Printf("x: %d\ty: %d\n", X, Y) fmt.Printf("x: %d\ty: %d\n", X, Y)
fmt.Printf("Without modifier: %d\n", planeResult) fmt.Printf("Modifier: %d\n", result-planeResult)
color.Green("%d\n", result) color.Green("%d\n", result)
} else if disadvantage { } else if disadvantage {
color.Yellow("Rolling %s check with disadvantage...", statString) color.Yellow("Rolling %s check with disadvantage...", statString)
fmt.Printf("x: %d\ty: %d\n", X, Y) fmt.Printf("x: %d\ty: %d\n", X, Y)
fmt.Printf("Without modifier: %d\n", planeResult) fmt.Printf("Modifier: %d\n", result-planeResult)
color.Red("%d\n", result) color.Red("%d\n", result)
} else { } else {
color.Yellow("Rolling %s check...", statString) color.Yellow("Rolling %s check...", statString)
fmt.Printf("Without modifier: %d\n", planeResult) fmt.Printf("Without modifier: %d\tModifier: %d\n", planeResult, result-planeResult)
color.Green("%d\n", result) color.Green("%d\n", result)
} }