Add ISC license and code cleanup
parent
3b4f2ddd1a
commit
471720b56e
|
@ -0,0 +1,15 @@
|
|||
ISC License
|
||||
|
||||
Copyright (c) 2017, Jacob Funke
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|
@ -189,7 +189,7 @@ class CursedMenu(object):
|
|||
# don't allow negative value
|
||||
water_left_pct = max(0, water_left_pct)
|
||||
water_left = int(math.ceil(water_left_pct * 10))
|
||||
water_string = "(" + (")" * water_left) + ("." * (10 - water_left)) + ") " + str(int(water_left_pct * 100)) + "%"
|
||||
water_string = "(" + (")" * water_left) + ("." * (10 - water_left)) + ") " + str(int(water_left_pct * 100)) + "% "
|
||||
return water_string
|
||||
|
||||
|
||||
|
@ -441,14 +441,15 @@ class CursedMenu(object):
|
|||
# Draw instructions on screen
|
||||
self.clear_info_pane()
|
||||
if self.infotoggle != 4:
|
||||
instructions_txt = """welcome to botany. you've been given a seed
|
||||
that will grow into a beautiful plant. check
|
||||
in and water your plant every 24h to keep it
|
||||
growing. 5 days without water = death. your
|
||||
plant depends on you to live! more info is
|
||||
available in the readme :)
|
||||
cheers,
|
||||
curio"""
|
||||
instructions_txt = ("welcome to botany. you've been given a seed\n"
|
||||
"that will grow into a beautiful plant. check\n"
|
||||
"in and water your plant every 24h to keep it\n"
|
||||
"growing. 5 days without water = death. your\n"
|
||||
"plant depends on you to live! more info is\n"
|
||||
"available in the readme :)\n"
|
||||
" cheers,\n"
|
||||
" curio\n"
|
||||
)
|
||||
self.draw_info_text(instructions_txt)
|
||||
self.infotoggle = 4
|
||||
else:
|
||||
|
|
Loading…
Reference in New Issue