Add cowthink
function
This commit is contained in:
parent
09882d4768
commit
c33bda7e36
1 changed files with 6 additions and 0 deletions
|
@ -1,6 +1,7 @@
|
|||
module Cowsay
|
||||
|
||||
export cowsay
|
||||
export cowthink
|
||||
|
||||
include("cows/blowfish.cow.jl")
|
||||
include("cows/bunny.cow.jl")
|
||||
|
@ -96,6 +97,11 @@ function cowsay(message::AbstractString; cow=default, eyes="oo", tongue=" ")
|
|||
println(string(balloon, cow(eyes=eyes, tongue=tongue)))
|
||||
end
|
||||
|
||||
function cowthink(message::AbstractString; cow=default, eyes="oo", tongue=" ")
|
||||
balloon = thinkballoon(message)
|
||||
println(string(balloon, cow(eyes=eyes, tongue=tongue, thoughts="o")))
|
||||
end
|
||||
|
||||
function sayballoon(message::AbstractString)
|
||||
messagelines = split(message, "\n")
|
||||
nlines = length(messagelines)
|
||||
|
|
Loading…
Reference in a new issue