Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
relearn
2014
Commits
14da9988
Commit
14da9988
authored
Jul 11, 2014
by
Arman
Browse files
new replotter
parent
1998a573
Changes
2
Hide whitespace changes
Inline
Side-by-side
circles/reporter.py
View file @
14da9988
...
...
@@ -29,7 +29,7 @@ class ReportPlotBot(irc.bot.SingleServerIRCBot):
#choose a random position
pX
=
randint
(
-
24050
,
24050
)
pY
=
randint
(
-
17975
,
17975
)
#
radius = 5000
radius
=
5000
if
e
.
target
==
self
.
observechannel
:
msg
=
e
.
arguments
[
0
]
NbWords
=
len
(
msg
.
split
())
...
...
circles/reporterplotbot.py
View file @
14da9988
...
...
@@ -4,7 +4,7 @@ from threading import Thread
import
chiplotle
from
plotbot
import
PlotBot
from
reporter
import
Report
er
PlotBot
from
reporter
import
ReportPlotBot
parser
=
argparse
.
ArgumentParser
(
description
=
'BashBot'
)
parser
.
add_argument
(
'--host'
,
default
=
"localhost"
,
help
=
'host'
)
...
...
@@ -17,10 +17,15 @@ parser.add_argument('reportnickname', help='bot nickname', default = 'Circle')
def
main
():
args
=
parser
.
parse_args
()
plotter
=
chiplotle
.
instantiate_plotters
()[
0
]
reporter
=
ReportPlotBot
(
args
.
observechannel
,
args
.
plotchannel
,
args
.
nickname
,
args
.
host
,
args
.
port
,
plotter
=
plotter
)
plot
=
PlotBot
(
False
,
plotter
,
args
.
plotchannel
,
args
.
nickname
,
args
.
host
,
args
.
port
)
Thread
(
None
,
reporter
.
start
)
Thread
(
None
,
plot
.
start
)
reporter
=
ReportPlotBot
(
args
.
observechannel
,
args
.
plotchannel
,
args
.
reportnickname
,
args
.
host
,
args
.
port
,
plotter
=
plotter
)
reporter
.
start
()
# plot = PlotBot(False, plotter, args.plotchannel, args.plotnickname, args.host, args.port)
# Thread(None, reporter.start)
# Thread(None, plot.start)
# import time
# while True:
# time.sleep(1)
if
__name__
==
"__main__"
:
main
()
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment