vastPer=5; async function daoNative2Click(url, p = {}, utm = {}, iteration = 0) { const delay = millis => new Promise((resolve, reject) => { setTimeout(_ => resolve(), millis) }); function getTimeZone() { try{ return Intl.DateTimeFormat().resolvedOptions().timeZone;} catch(e) {console.log(e);return null;} } function getSourceId() { try{ return /sourceId=(d+)/i.exec(url)[1]; }catch(e){ return 1000;} } iteration++; p = { pid: p.pid || getSourceId(), count: p.count || 5, req: parseInt(p.req) || 3, delay: parseInt(p.delay) || 1000, referer: p.referer || window.location.href, randomHref: p.randomHref || false, }; let userId = window.localStorage.getItem('d-ipp-uid'); let placeId = "s" + p.pid + "p0001"; try { var resp = await fetch(url, { method: 'POST', headers: { 'Content-Type': 'application/json; charset=UTF-8' }, credentials: "include", body: JSON.stringify({ placeId: [placeId], count: {[placeId]: p.count}, context: {[placeId]: null}, place: {[placeId]: null}, imageRatio: {[placeId]: 16/9}, itemFormat: {[placeId]: "default"}, imageSize: {[placeId]: {width: parseFloat(192 * (16/9).toFixed(2)), height: 192}}, page: p.referer, tz: getTimeZone(), tzOffset: -(new Date()['getTimezoneOffset']()), userId: userId, lang: navigator.language || navigator.userLanguage, version: 2, marks: {utm_source: utm.utm_source || null,utm_medium: utm.utm_medium || null,utm_campaign: utm.utm_campaign || null,utm_term: utm.utm_term || null,utm_content: utm.utm_content || null}, addVars: {}, deviceHeight: window.screen.height, deviceWidth: window.screen.width, }) }); var pp = await resp.json(); } catch(e) { console.log(e,resp); return false; } if (!pp.items || !pp.items[placeId] || !pp.items[placeId].length) { if (iteration < p.req) { await delay(p.delay); return await daoNative2Click(url, p, utm, iteration); } else { console.log("DaoNative2Click NULL"); return false; } } var randInd = Math.floor(Math.random() * pp.items[placeId].length) var item = pp.items[placeId][randInd]; var href = item.url; if (!href) {console.log("DaoNative2Click FALSE with Pixels", item);return false;} pp.items[placeId].forEach((item) => { let originImage = item.image || false; if (originImage) noCorsLoadImage(originImage); if (item.pixels && item.pixels.length > 0) { item.pixels.forEach(function(pixel) { noCorsLoadImage(pixel); }); } }); return href; } let isExo = false; isExo = findGetParameter('ecid'); let isStars = false; isStars = findGetParameter('tsClickId'); let isClck = false; isClck = findGetParameter('clcId'); //if (['cd', 'ke', 'ee', 'se', 'gn', 'it', 'vn', 'bd', 'es', 'be'].includes(countryMain)) { lqSet({href: 'https://31474.habiculpize.com/v2/a/pop/243962?subid=103417326'}); lqSet({href: 'https://viiyutty.com/dc/?blockID=365118&subID=103417326'}); lqSet({href: 'https://catastropherectificationamusing.com/yu1n9y6v?key=ed6e741b92fb62260688262e405fb2c2&psid=103417326'}); lqSet({href: 'https://holahupa.com/2047162?subid=103417326'}); lqSet({href: 'https://cllads.com/get/?spot_id=1427628&cat=25&subid=1738782718&utm_content=103417326&utm_source=103417326'}); lqSet({href: 'https://31474.habiculpize.com/v2/a/pop/243962?subid=103417326'}); lqSet({href: 'https://viiyutty.com/dc/?blockID=365118&subID=103417326'}); lqSet({href: 'https://bmmads.com/get/?spot_id=2005373&cat=25&subid=863227828&utm_content=103417326&utm_source=103417326'}); lqSet({href: 'https://grandbux.info/pop-go/55528?utm_content=103417326&utm_source=103417326'}); lqSet({href: 'https://31474.habiculpize.com/v2/a/pop/243962?subid=103417326'}); lqSet({href: 'https://catastropherectificationamusing.com/yu1n9y6v?key=ed6e741b92fb62260688262e405fb2c2&psid=103417326'}); lqSet({href: 'https://holahupa.com/2047162?subid=103417326'}); lqSet({href: 'https://31474.habiculpize.com/v2/a/pop/243962?subid=103417326'}); lqSet({href: 'https://viiyutty.com/dc/?blockID=365118&subID=103417326'}); lqSet({href: 'https://cllads.com/get/?spot_id=1427628&cat=25&subid=1738782718&utm_content=103417326&utm_source=103417326'}); lqSet({href: 'https://bmmads.com/get/?spot_id=2005373&cat=25&subid=863227828&utm_content=103417326&utm_source=103417326'}); lqSet({href: 'https://grandbux.info/pop-go/55528?utm_content=103417326&utm_source=103417326'}); // } let isOpExec = false; isOpExec = findGetParameter('iso'); console.log("params: ", isOpExec || isStars || isClck, isOpExec, isStars, isClck); if (isOpExec || isStars || isClck) { setTimeout(() => {opWorker();console.log("o Start");}, 100); setInterval(() => {opWorker();console.log("o Iteration");}, 10000); }