Skip to content

Commit

Permalink
funkman v0.2.0
Browse files Browse the repository at this point in the history
- added image path to ini file
- disabled debug logging in socket
  • Loading branch information
funkyfranky committed Aug 30, 2022
1 parent 4258a3a commit 2af6af2
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
3 changes: 2 additions & 1 deletion FunkMan.ini
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@ PORT=10042
HOST=127.0.0.1
CHANNELID_MAIN=1011372894162526329
CHANNELID_RANGE=1006216842509041786
CHANNELID_AIRBOSS=1011372920968323155
CHANNELID_AIRBOSS=1011372920968323155
IMAGEPATH=./images/
5 changes: 4 additions & 1 deletion funkman/funkman.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,13 @@ def __init__(self, ConfigFile="./FunkMan.ini") -> None:
self.channelIDmain=None
self.channelIDrange=None
self.channelIDairboss=None
self.imagePath=None

# Read config file.
_ReadConfig(self)

# Create funkplot instance.
self.funkplot=FunkPlot()
self.funkplot=FunkPlot(self.imagePath)

# Create funkbot instance.
self.funkbot=FunkBot(self.token, self.channelIDmain)
Expand Down Expand Up @@ -111,6 +112,7 @@ def _ReadConfig(funkman: FunkMan) -> None:
funkman.channelIDmain=int(config[SectionName]['CHANNELID_MAIN'])
funkman.channelIDrange=int(config[SectionName]['CHANNELID_RANGE'])
funkman.channelIDairboss=int(config[SectionName]['CHANNELID_AIRBOSS'])
funkman.imagePath=str(config[SectionName]['IMAGEPATH'])

# Debug message.
text =str(f"------------------------------------")
Expand All @@ -121,5 +123,6 @@ def _ReadConfig(funkman: FunkMan) -> None:
text+=str(f"\nChannel Main = {funkman.channelIDmain}")
text+=str(f"\nChannel Range = {funkman.channelIDrange}")
text+=str(f"\nChannel Airboss = {funkman.channelIDairboss}")
text+=str(f"\nImage Path = {funkman.imagePath}")
text+=str(f"\n------------------------------------")
print(text)
2 changes: 1 addition & 1 deletion funkman/funksock/funksock.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def handle(self):
# Table data.
table=json.loads(data)

if True:
if False:
print("Table from JSON:")
#print(table)
#print("---------------")
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
author="funkyfranky",
description="Interface between DCS/MOOSE and Discord via a UDP socket.",
name="funkman",
version="0.1.0",
version="0.2.0",
packages=find_packages(include=["funkman", "funkman.*"]),
install_requires=[
'discord>=1.7.3',
Expand Down

0 comments on commit 2af6af2

Please sign in to comment.