Events and timers? - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32) +--- Forum: Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=26) +--- Thread: Events and timers? (/showthread.php?tid=24538) |
Events and timers? - art0rz - 2007-01-29 Hi, First of all, I would like to thank the developers for making such an awesome XBox dashboard, I've had lots of fun with it and have stopped using my pc as a media center. I'm making a 'now playing' script for XBMC and mIRC, and need some advice. Right now, the script runs in an aweful while loop that gets the song info every 20 seconds and I would like it to use an event for when XBMC changes the current song. I've not dug very deep into the documentation -mainly because it's not very well documented afaik - and my python skills have known better times. If this is not possible, I would like to know how to get rid of the aweful loop, and switch to a more .. proper way of having a timer. And one more question, could you list the getMusicInfoTag functions? Cheers, art0rz - art0rz - 2007-01-29 My apologies for the double post, I couldnt find the edit button. It seems I overlooked the HttpApi page. No need for a python script now. - Nuka1195 - 2007-01-29 http://home.no.net/thor918/xbmc/xbmc.html http://home.no.net/thor918/xbmc/xbmcgui.html The following is what I use, thanks to Thor918. I call it with the following: self.MyPlayer = MyPlayer( xbmc.PLAYER_CORE_MPLAYER, function = self.myPlayerChanged ) Code: ## Thanks Thor918 for this class ## |