Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
lemmings script / pyxmms returns strange result
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
fuzzythebear
Guru
Guru


Joined: 28 Nov 2004
Posts: 317

PostPosted: Fri Sep 01, 2006 11:06 pm    Post subject: lemmings script / pyxmms returns strange result Reply with quote

Hi's

I got an issue with xmms / pyxmms and the lemmings script for XChat
When you play an ogg and do a /xmms playing ( code to follow )
it returns something like this :
xyz is currently listening to Dream Theater - This Dying Soul (01:02 / Live stream)

It aint a live stream .. it's a ogg file ..
I checked the code portion relevant to this :

#XMMS section . ProGuy did it under duress.Strong arm tactics have
#been used to get this work done.No animals were harmed during this phase.

if xmms_installed:
class FuzzyXMMS:
def __init__(self):
self.currentlyPlaying = -1
self.announceChannels = []

def constructPlayingString(self):
if xmms.is_playing():
self.currentlyPlaying = xmms.get_playlist_pos()
totalTime = xmms.get_playlist_time(self.currentlyPlaying)
playedTime = xmms.get_output_time()
return xmms.get_playlist_title(self.currentlyPlaying) +\
" (" + self.formatTime(playedTime) + " / " +\
self.formatTime(totalTime) + ")"

def showPlaying(self):
xchat.command("me is currently listening to " +
self.constructPlayingString())

def announceToChannel(self, channel):
xchat.command("msg " + channel + " I'm listening to " +
self.constructPlayingString())

# Time is given in ms to formatTime, it will output a nice string
def formatTime(self, time):
mins = time / 60000
rem = time % 60000
secs = rem / 1000
if mins < 10:
shMins = "0"+str(mins)
else:
shMins = str(mins)

if secs < 10:
shSecs = "0"+str(secs)
else:
shSecs = str(secs)

return shMins + ":" + shSecs

Nowhere is there a mention of Live stream..
would this be a xmms bug ?
did anyone ran in this oddity with other scripts ?
anyone got a workaround ?
anyone know anything that can help us fix this ?

Thanks :)

FTB
_________________
There's this once i thought i had made a mistake .. but i was wrong :|
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum