PK VJ+I I plugin.video.bigkids/addon.xml
video
Big Kids
Support is now dropped for this addon. Visit kodification.co.uk for any issues
The author neither hosts or stores any content, the author has no affiliation with content hosts
all
PK kUJ*Q Q plugin.video.bigkids/default.py'''
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see .
'''
import sys,os
import urllib,urllib2,re,base64,xbmc,xbmcplugin,xbmcgui,xbmcaddon,urlparse
import urlresolver
import random
Dialog = xbmcgui.Dialog()
Decode = base64.decodestring
base_url = sys.argv[0]
addon_handle = int(sys.argv[1])
args = urlparse.parse_qs(sys.argv[2][1:])
PATH = "Big Kids"
VERSION = "1.0.1"
IE_USER_AGENT = 'Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; AS; rv:11.0) like Gecko'
FF_USER_AGENT = 'Mozilla/5.0 (Windows NT 6.3; rv:36.0) Gecko/20100101 Firefox/36.0'
IOS_USER_AGENT = 'Mozilla/5.0 (iPhone; CPU iPhone OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A5376e Safari/8536.25'
ANDROID_USER_AGENT = 'Mozilla/5.0 (Linux; Android 4.4.2; Nexus 4 Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/34.0.1847.114 Mobile Safari/537.36'
parental = 'true'
ADDONS = xbmc.translatePath(os.path.join('special://home','addons',''))
addon_id='plugin.video.bigkids'
ART = os.path.join(ADDONS,addon_id,'resources','art')+os.sep
FANART = xbmc.translatePath(os.path.join(ADDONS,addon_id,'fanart.jpg'))
IMAGES = ART + 'icon.png'
BASE = Decode('aHR0cDovL3d3dy5hbmltZXRvb24ub3JnL2NhcnRvb24=')
ADDONS = xbmc.translatePath(os.path.join('special://home','addons',''))
addon_id='plugin.video.bigkids'
current_folder = ADDONS+'/'+addon_id+'/'
full_file = current_folder.replace('\\','/') + '/final.txt'
def TextBoxes(heading,announce):
class TextBox():
WINDOW=10147
CONTROL_LABEL=1
CONTROL_TEXTBOX=5
def __init__(self,*args,**kwargs):
xbmc.executebuiltin("ActivateWindow(%d)" % (self.WINDOW, )) # activate the text viewer window
self.win=xbmcgui.Window(self.WINDOW) # get window
xbmc.sleep(500) # give window time to initialize
self.setControls()
def setControls(self):
self.win.getControl(self.CONTROL_LABEL).setLabel(heading) # set heading
try: f=open(announce); text=f.read()
except: text=announce
self.win.getControl(self.CONTROL_TEXTBOX).setText(str(text))
return
TextBox()
TextBox()
if not os.path.exists(full_file):
Open = open(full_file,'w+')
TextBoxes('Final Version','The time has come to call it a day. I\'ve been studying lots of other stuff outside of Kodi and unfortunately am at a point where i feel i have too many commitments so Kodi stuff being a hobby will have to be the one getting the chop. I\'ll not delete any addons as if they still work you may aswell enjoy them. All the code is open for anyone to use or addons to fork just do them justice and a little credit is never a bad thing. Don\'t forget to visit kodification.co.uk as the site will hopefully be getting a nice new look in the coming weeks. \n\nThe addon\'s will work as long as they work i cannot promise any time scale just enjoy them while they are there, but there will be no future updates to any addons. Its been a long and enjoyable learning curve and hope some have enjoyed my addons. All the best to everyone thats helped me along the way.\n\nOrigin')
def Home_Menu():
addDirFolder('Cartoons','',1,IMAGES,FANART,'')
addDirFolder('Cartoons and Movies','',6,IMAGES,FANART,'')
addDirFolder('Search Cartoons','',2,IMAGES,FANART,'')
addDirFolder('Search Movies','',11,IMAGES,FANART,'')
addDirFolder('24/7','',12,IMAGES,FANART,'')
def Random_Lists():
Random_play('24/7 Random Cartoon',13,url=BASE,image=IMAGES,isFolder=False)
addDirFolder('24/7 Select Cartoon','',17,IMAGES,FANART,'')
Random_play('20 Random Movies',14,url='http://www.animetoon.org/movies',image=IMAGES,isFolder=False)
def Random_Cartoon(url):
Playlist = xbmc.PlayList(xbmc.PLAYLIST_VIDEO)
Playlist.clear()
Counter = []
full_count = []
Prog_Name = []
html=OPEN_URL(url)
match = re.compile('
(.+?) | ').findall(html)
for url,name in match:
full_count.append([url,name])
if len(full_count) == len(match):
for item in full_count:
get_random=random.randint(1,len(full_count))
try:
url_to_add = full_count[int(get_random)]
except:
pass
if url_to_add[1] not in Prog_Name:
Prog_Name.append(url_to_add[1])
if int(len(Counter)) < 1:
Counter.append(url_to_add[1][0])
Random_Play_Cartoon(url_to_add[0],url_to_add[1])
else:
pass
else:
pass
else:
pass
def twenty47_select():
html=OPEN_URL(BASE)
match = re.compile('(.+?) | ').findall(html)
for url,name in match:
Random_play(name,16,url=url,image=IMAGES,isFolder=False)
xbmcplugin.addSortMethod(addon_handle, xbmcplugin.SORT_METHOD_TITLE);
def Random_Movie(url):
Playlist = xbmc.PlayList(xbmc.PLAYLIST_VIDEO)
Playlist.clear()
Full_List = []
Count = []
Name = []
HTML = OPEN_URL(url)
match = re.compile('(.+?) | ').findall(HTML)
for url2,name in match:
Full_List.append([url2,name])
if len(Full_List)==len(match):
for item in Full_List:
random_movie=random.randint(1,len(Full_List))
try:
next_url = Full_List[int(random_movie)]
except:
pass
if len(Count)<=20:
if next_url[1] not in Name:
HTML2 = OPEN_URL(next_url[0])
match3 = re.compile(' (.+?)').findall(HTML2)
for Playlink_url,Ep_name in match3:
HTML4 = OPEN_URL(Playlink_url)
match4 = re.compile('"playlist">(.+?)').findall(html2)
for img in match2:
IMAGE = img
match3 = re.compile('
(.+?)').findall(html2)
for Playlink_url,Ep_name in match3:
episode_full_count.append([Playlink_url,Ep_name])
if len(episode_full_count)==len(match3):
for item in episode_full_count:
get_random_ep=random.randint(1,len(episode_full_count))
try:
next_url_to_use=episode_full_count[int(get_random_ep)]
if next_url_to_use[1] not in Ep_Name_List:
Ep_Name_List.append(next_url_to_use[1])
html3 = OPEN_URL(next_url_to_use[0])
match4 = re.compile('"playlist">(.+?)