diff --git a/cuevana3.json b/cuevana3.json new file mode 100644 index 00000000..97c0d751 --- /dev/null +++ b/cuevana3.json @@ -0,0 +1,69 @@ +{ + "id": "cuevana3", + "name": "Cuevana 3", + "active": true, + "adult": false, + "language": ["lat", "cast"], + "thumbnail": "https://www.cuevana3.co/wp-content/themes/cuevana3/public/img/cnt/cuevana3.png", + "banner": "", + "version": 1, + "categories": [ + "movie" + ], + "settings": [ + { + "id": "include_in_global_search", + "type": "bool", + "label": "Incluir en busqueda global", + "default": false, + "enabled": false, + "visible": false + }, + { + "id": "filter_languages", + "type": "list", + "label": "Mostrar enlaces en idioma...", + "default": 0, + "enabled": true, + "visible": true, + "lvalues": [ + "No filtrar", + "LAT", + "CAST", + "VOSE" + ] + }, + { + "id": "include_in_newest_peliculas", + "type": "bool", + "label": "Incluir en Novedades - Peliculas", + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "include_in_newest_infantiles", + "type": "bool", + "label": "Incluir en Novedades - Infantiles", + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "include_in_newest_terror", + "type": "bool", + "label": "Incluir en Novedades - Terror", + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "include_in_newest_documentales", + "type": "bool", + "label": "Incluir en Novedades - Documentales", + "default": true, + "enabled": true, + "visible": true + } + ] +} diff --git a/plugin.video.alfa/addon.xml b/plugin.video.alfa/addon.xml index 463a57d9..9f4ebb95 100755 --- a/plugin.video.alfa/addon.xml +++ b/plugin.video.alfa/addon.xml @@ -1,5 +1,5 @@ - + @@ -19,9 +19,14 @@ [B]Estos son los cambios para esta versión:[/B] [COLOR green][B]Arreglos[/B][/COLOR] - ¤ newpct1 ¤ inkapelis ¤ mp4upload + ¤ maxipelis24 ¤ cuevana3 ¤ pelisplusco + ¤ mejortorrent ¤ newpct1 + + [COLOR green][B]Novedades[/B][/COLOR] + ¤ Mundopelis ¤ thevideobee ¤ tusfiles + ¤ vup - ¤ Agradecimientos a @mac12m99 por colaborar con ésta versión + ¤ Agradecimientos a @mac12m99 y @chivmalev por colaborar con ésta versión Navega con Kodi por páginas web para ver sus videos de manera fácil. diff --git a/plugin.video.alfa/channels/autoplay.py b/plugin.video.alfa/channels/autoplay.py index 31f2275a..79c764b7 100644 --- a/plugin.video.alfa/channels/autoplay.py +++ b/plugin.video.alfa/channels/autoplay.py @@ -9,6 +9,7 @@ from platformcode import config, logger from platformcode import platformtools from platformcode import launcher from time import sleep +from platformcode.config import get_setting __channel__ = "autoplay" @@ -117,7 +118,7 @@ def start(itemlist, item): # Obtiene los ajustes des autoplay para este canal settings_node = channel_node.get('settings', {}) - if settings_node['active']: + if get_setting('autoplay') or settings_node['active']: url_list_valid = [] autoplay_list = [] autoplay_b = [] @@ -142,7 +143,7 @@ def start(itemlist, item): # 2: Solo servidores # 3: Solo calidades # 4: No ordenar - if settings_node['custom_servers'] and settings_node['custom_quality']: + if (settings_node['custom_servers'] and settings_node['custom_quality']) or get_setting('autoplay'): priority = settings_node['priority'] # 0: Servidores y calidades o 1: Calidades y servidores elif settings_node['custom_servers']: priority = 2 # Solo servidores @@ -391,14 +392,15 @@ def init(channel, list_servers, list_quality, reset=False): # Se comprueba que no haya calidades ni servidores duplicados if 'default' not in list_quality: list_quality.append('default') - list_servers = list(set(list_servers)) - list_quality = list(set(list_quality)) + # list_servers = list(set(list_servers)) + # list_quality = list(set(list_quality)) # Creamos el nodo del canal y lo añadimos channel_node = {"servers": list_servers, "quality": list_quality, "settings": { "active": False, + "plan_b": True, "custom_servers": False, "custom_quality": False, "priority": 0}} @@ -455,7 +457,7 @@ def check_value(channel, itemlist): for item in itemlist: if item.server.lower() not in server_list and item.server !='': - server_list.append(item.server) + server_list.append(item.server.lower()) change = True if item.quality not in quality_list and item.quality !='': quality_list.append(item.quality) @@ -672,7 +674,7 @@ def is_active(channel): # Obtiene los ajustes des autoplay para este canal settings_node = channel_node.get('settings', {}) - return settings_node.get('active', False) + return settings_node.get('active', False) or get_setting('autoplay') def reset(item, dict): diff --git a/plugin.video.alfa/channels/cuevana3.py b/plugin.video.alfa/channels/cuevana3.py index 9c4d64b3..4882c812 100644 --- a/plugin.video.alfa/channels/cuevana3.py +++ b/plugin.video.alfa/channels/cuevana3.py @@ -31,23 +31,29 @@ def mainlist(item): itemlist = list() - itemlist.append(Item(channel=item.channel, title="Ultimas", action="list_all", url=host, - thumbnail=get_thumb('last', auto=True))) + itemlist.append(Item(channel=item.channel, title="Todas", action="list_all", url=host+'peliculas', + thumbnail=get_thumb('all', auto=True))) + itemlist.append(Item(channel=item.channel, title="Estrenos", action="list_all", url=host+'estrenos', + thumbnail=get_thumb('premieres', auto=True))) + itemlist.append(Item(channel=item.channel, title="Mas vistas", action="list_all", url=host+'peliculas-mas-vistas', + thumbnail=get_thumb('more watched', auto=True))) + itemlist.append(Item(channel=item.channel, title="Mas votadas", action="list_all", url=host+'peliculas-mas-valoradas', + thumbnail=get_thumb('more voted', auto=True))) itemlist.append(Item(channel=item.channel, title="Generos", action="section", section='genre', thumbnail=get_thumb('genres', auto=True))) - itemlist.append(Item(channel=item.channel, title="Castellano", action="list_all", url= host+'espanol', - thumbnail=get_thumb('audio', auto=True))) - - itemlist.append(Item(channel=item.channel, title="Latino", action="list_all", url=host + 'latino', - thumbnail=get_thumb('audio', auto=True))) - - itemlist.append(Item(channel=item.channel, title="VOSE", action="list_all", url=host + 'subtitulado', - thumbnail=get_thumb('audio', auto=True))) - - itemlist.append(Item(channel=item.channel, title="Alfabetico", action="section", section='alpha', - thumbnail=get_thumb('alphabet', auto=True))) + # itemlist.append(Item(channel=item.channel, title="Castellano", action="list_all", url= host+'espanol', + # thumbnail=get_thumb('audio', auto=True))) + # + # itemlist.append(Item(channel=item.channel, title="Latino", action="list_all", url=host + 'latino', + # thumbnail=get_thumb('audio', auto=True))) + # + # itemlist.append(Item(channel=item.channel, title="VOSE", action="list_all", url=host + 'subtitulado', + # thumbnail=get_thumb('audio', auto=True))) + # + # itemlist.append(Item(channel=item.channel, title="Alfabetico", action="section", section='alpha', + # thumbnail=get_thumb('alphabet', auto=True))) itemlist.append(Item(channel=item.channel, title="Buscar", action="search", url=host+'?s=', thumbnail=get_thumb('search', auto=True))) @@ -69,17 +75,16 @@ def list_all(item): itemlist = [] try: - data = get_source(item.url) - if item.section == 'alpha': - patron = '\d+.*?
  • ') if next_page!="": next_page = urlparse.urljoin(item.url,next_page) @@ -80,11 +79,11 @@ def lista(item): def play(item): logger.info() itemlist = [] - data = scrapertools.cachePage(item.url) + data = httptools.downloadpage(item.url).data patron = 'video_url: \'([^\']+)\'' matches = scrapertools.find_multiple_matches(data, patron) for scrapedurl in matches: - itemlist.append(Item(channel=item.channel, action="play", title=item.title, fulltitle=item.fulltitle, url=scrapedurl, + itemlist.append(Item(channel=item.channel, action="play", title=item.title, url=scrapedurl, thumbnail=item.thumbnail, plot=item.plot, show=item.title, server="directo", folder=False)) return itemlist diff --git a/plugin.video.alfa/channels/filmoviXXX.py b/plugin.video.alfa/channels/filmoviXXX.py index 7308fb67..650f9335 100644 --- a/plugin.video.alfa/channels/filmoviXXX.py +++ b/plugin.video.alfa/channels/filmoviXXX.py @@ -26,7 +26,7 @@ def mainlist(item): thumbnail = scrapedthumbnail plot = "" itemlist.append( Item(channel=item.channel, action="play", title=title, url=scrapedurl, - thumbnail=thumbnail, plot=plot, contentTitle=contentTitle)) + thumbnail=thumbnail, fanart=thumbnail, plot=plot, contentTitle=contentTitle)) next_page_url = scrapertools.find_single_match(data,'

    len(matches): + last = len(matches) + next = True + scrapertools.printMatches(matches) + for scrapedthumbnail, scrapedurl, scrapedtitle in matches[first:last]: + scrapedyear = "-" + title = scrapedtitle.replace(" (2018)", "") + url = urlparse.urljoin(item.url,scrapedurl) + itemlist.append(item.clone(channel=item.channel, action = 'findvideos', title=title, contentTitle = scrapedtitle, + url=url, thumbnail=scrapedthumbnail, infoLabels={'year':scrapedyear} )) + tmdb.set_infoLabels(itemlist, True) + # Paginación + if not next: + url_next_page = item.url + first = last + else: + url_next_page = scrapertools.find_single_match(data, '", "", data) + patron = '<(?:iframe|IFRAME).*?(?:src|SRC)="([^"]+)"' + matches = scrapertools.find_multiple_matches(data, patron) + for url in matches: + lang = "VOSE" + if not config.get_setting('unify'): + title = ' (%s)' % (lang) + else: + title = '' + if url != '': + itemlist.append(item.clone(action="play", title='%s'+title, url=url, language=lang )) + itemlist = servertools.get_servers_itemlist(itemlist, lambda i: i.title % i.server.capitalize()) + + # Requerido para Filtrar enlaces + if __comprueba_enlaces__: + itemlist = servertools.check_list_links(itemlist, __comprueba_enlaces_num__) + # Requerido para FilterTools + itemlist = filtertools.get_links(itemlist, item, list_language) + # Requerido para AutoPlay + autoplay.start(itemlist, item) + + + if config.get_videolibrary_support() and len(itemlist) > 0 and item.extra !='findvideos' and not "/episodios/" in item.url : + itemlist.append(Item(channel=item.channel, action="add_pelicula_to_library", + title='[COLOR yellow]Añadir esta pelicula a la videoteca[/COLOR]', url=item.url, + extra="findvideos", contentTitle=item.contentTitle)) + return itemlist + + diff --git a/plugin.video.alfa/channels/newpct1.py b/plugin.video.alfa/channels/newpct1.py index a563068d..662351ba 100644 --- a/plugin.video.alfa/channels/newpct1.py +++ b/plugin.video.alfa/channels/newpct1.py @@ -7,6 +7,7 @@ import urlparse import datetime import ast import random +import traceback from channelselector import get_thumb from core import httptools @@ -700,8 +701,12 @@ def listado(item): #Guardamos el resto de variables del vídeo item_local.url = scrapedurl + if not item_local.url.startswith("http"): #Si le falta el http.: lo ponemos + item_local.url = scrapertools.find_single_match(item_local.channel_host, '(\w+:)//') + item_local.url item_local.thumbnail = scrapedthumbnail - item_local.contentThumbnail = scrapedthumbnail + if not item_local.thumbnail.startswith("http"): #Si le falta el http.: lo ponemos + item_local.thumbnail = scrapertools.find_single_match(item_local.channel_host, '(\w+:)//') + item_local.thumbnail + item_local.contentThumbnail = item_local.thumbnail #Guardamos el año que puede venir en la url, por si luego no hay resultados desde TMDB year = '' @@ -1008,7 +1013,7 @@ def listado_busqueda(item): if not data_serie: #Si no ha logrado encontrar nada, salimos title_subs += ["ERR"] - elif item_local.channel_alt: #Si ha habido fail-over, lo comento + elif item_local.channel_alt: #Si ha habido fail-over, lo comento url = url.replace(item_local.channel_alt, item_local.category.lower()) title_subs += ["ALT"] @@ -1029,8 +1034,10 @@ def listado_busqueda(item): title_subs += ["Episodio %sx%s" % (scrapertools.find_single_match(url, '\/temp.*?-(\d+)-?\/cap.*?-(\d+(?:-al-\d+)?)-?\/'))] url = item_local.url except: - pass + logger.error(traceback.format_exc()) + #logger.debug(item_local.url) + if item.extra == "novedades" and "/serie" in url: if not item_local.url or episodio_serie == 0: item_local.url = url @@ -1204,8 +1211,12 @@ def listado_busqueda(item): #Guardamos el resto de variables del vídeo item_local.url = url + if not item_local.url.startswith("http"): #Si le falta el http.: lo ponemos + item_local.url = scrapertools.find_single_match(item_local.channel_host, '(\w+:)//') + item_local.url item_local.thumbnail = scrapedthumbnail - item_local.contentThumbnail = scrapedthumbnail + if not item_local.thumbnail.startswith("http"): #Si le falta el http.: lo ponemos + item_local.thumbnail = scrapertools.find_single_match(item_local.channel_host, '(\w+:)//') + item_local.thumbnail + item_local.contentThumbnail = item_local.thumbnail #Guardamos el año que puede venir en la url, por si luego no hay resultados desde TMDB try: @@ -2019,7 +2030,12 @@ def episodios(item): item_local = item.clone() #Creamos copia local de Item por episodio item_local.url = url - item_local.contentThumbnail = thumb + if not item_local.url.startswith("http"): #Si le falta el http.: lo ponemos + item_local.url = scrapertools.find_single_match(item_local.channel_host, '(\w+:)//') + item_local.url + item_local.thumbnail = thumb + if not item_local.thumbnail.startswith("http"): #Si le falta el http.: lo ponemos + item_local.thumbnail = scrapertools.find_single_match(item_local.channel_host, '(\w+:)//') + item_local.thumbnail + item_local.contentThumbnail = item_local.thumbnail estado = True #Buena calidad de datos por defecto if "|\s{2,}', "", full_data) + season = str(item.infoLabels['season']) if int(season) <= 9: season = '0'+season data = scrapertools.find_single_match(full_data, 'Temporada %s
    (.*?)(?:down arrow|cuadre_comments)' % season) patron = '<\/i> (.*?)<\/a>' - matches = matches = re.compile(patron, re.DOTALL).findall(data) + matches = re.compile(patron, re.DOTALL).findall(data) infoLabels = item.infoLabels for url, episode in matches: episodenumber = re.sub('C.* ','',episode) @@ -354,7 +355,7 @@ def get_links_by_language(item, data): video_list = [] language = scrapertools.find_single_match(data, 'ul id="level\d_([^"]+)"\s*class=') - patron = 'data-source="([^"]+)"data-quality="([^"]+)"data-srt="([^"]+)"' + patron = 'data-source="([^"]+)"data-quality="([^"]+)"data-srt="([^"]+)?"' matches = re.compile(patron, re.DOTALL).findall(data) if language in IDIOMAS: language = IDIOMAS[language] @@ -399,7 +400,6 @@ def findvideos(item): new_url = base_url.replace('/serie/', '/player/serie/') new_url += '|%s|%s/' % (item.contentSeason, item.contentEpisodeNumber) data = get_source(new_url, referer=item.url) - patron_language ='(