Results 1 to 6 of 6

Thread: Need a very simple script that just clicks a link once an hour or so [n00b level] [another petsite]

  1. #1
    CaptainNight's Avatar
    Joined
    Jul 2014
    Posts
    306
    Userbars
    7
    Thanks
    81
    Thanked
    199/84
    DL/UL
    29/3
    Mentioned
    27 times
    Time Online
    12d 5h 51m
    Avg. Time Online
    4m

    Need a very simple script that just clicks a link once an hour or so [n00b level] [another petsite]

    Some time ago I asked for a script that would click a banner on (you need an account to see links) which is my 2nd favorite petsite. I am hopeless at scripts and code and whatnot so I guarentee this is easy for any of you..

    You guys saved my butt and I got sooo many items last year from the summer event. The same event is back this year with a new aspect

    Here was the older thread and what I need is very similar to this so you can probably reuse bit of this code:

    (you need an account to see links)

    This year I need to click a "get token" link on a static page. It only WORKS once an hour. Just refreshing does not work because each time you click it, a new "token" is generated that only works for that moment

    This is the page:

    (you need an account to see links)

    (you need an account to see links)

    and this is the "try again" token link format:
    Code:
    http://www.chickensmoothie.com/space/asteroids?token=f6e78303&time=1468809097
    Basically I need to click "try again" when the hour is up to get a new link (or like every 5-10 min it doesnt really matter, but id rather not be mad refreshing every 5 secs in case that sets something off) so it gives me a special item. Nothing needs to be clicked beyond that.

    I would be totally fine with a tampermonkey/Greasemonkey script. I don't need a full program or anything crazy. Just something to set up to get items while I sleep.

    If you need any more information, please let me know. The site does not really check for botting and abuse as far as I can tell so im not too worried about that.

    ABSOLUTELY WILL REP YALL
    Last edited by CaptainNight; 07-18-2016 at 08:08 PM.
    [CENTER]Lazy and Paranoid

  2. #2
    Zachafer's Avatar
    Joined
    Dec 2011
    Posts
    1,235
    Userbars
    11
    Thanks
    769
    Thanked
    1,466/678
    DL/UL
    98/0
    Mentioned
    512 times
    Time Online
    24d 13h 9m
    Avg. Time Online
    8m
    @(you need an account to see links) Can you post or PM me the source code of the page with the "Try again" link?

    Try this edited version of the previous script... Credit @(you need an account to see links)

  3. The Following User Says Thank You to Zachafer For This Useful Post:

    CaptainNight (07-19-2016)

  4. #3
    CaptainNight's Avatar
    Joined
    Jul 2014
    Posts
    306
    Userbars
    7
    Thanks
    81
    Thanked
    199/84
    DL/UL
    29/3
    Mentioned
    27 times
    Time Online
    12d 5h 51m
    Avg. Time Online
    4m
    @(you need an account to see links) thank you very much for helping me. Im on mobile right now, ill test it out as soon as im able. these silly chickensmoothie events will be the death of me, idk how anyone gets all the event stuff legitly.

    I can get the source code. Here:



    Its kind of long, hope this helps
    [CENTER]Lazy and Paranoid

  5. #4
    CaptainNight's Avatar
    Joined
    Jul 2014
    Posts
    306
    Userbars
    7
    Thanks
    81
    Thanked
    199/84
    DL/UL
    29/3
    Mentioned
    27 times
    Time Online
    12d 5h 51m
    Avg. Time Online
    4m
    So I tried the script you posted, the "try again" link is there all the time so it does not click it at an interval but like, mad refreshes it every single second or even less, as soon as my browser can load it because the script wants to click it as soon as it finds it (always). Its making my browser shit itself.

    The other banner event was not there all the time, so it would refresh every 5-10 seconds and not find the banner most of the time but then immediately click it upon finding it. For this event, Is there a way to make it wait before trying the link again? I dont want to be TOO suspicious in case they start logging clicks or something.
    Last edited by CaptainNight; 07-19-2016 at 09:30 AM.
    [CENTER]Lazy and Paranoid

  6. #5

    Joined
    Jul 2012
    Posts
    1,888
    Thanks
    1,619
    Thanked
    3,297/1,003
    DL/UL
    223/0
    Mentioned
    469 times
    Time Online
    132d 23h 52m
    Avg. Time Online
    45m
    Quote Originally Posted by flytenyte View Post
    So I tried the script you posted, the "try again" link is there all the time so it does not click it at an interval but like, mad refreshes it every single second or even less, as soon as my browser can load it because the script wants to click it as soon as it finds it (always). Its making my browser shit itself.

    The other banner event was not there all the time, so it would refresh every 5-10 seconds and not find the banner most of the time but then immediately click it upon finding it. For this event, Is there a way to make it wait before trying the link again? I dont want to be TOO suspicious in case they start logging clicks or something.

    Code:
    // ==UserScript==
    //  @(you need an account to see links) Giveaway Getter
    //  @(you need an account to see links)space Odd.ChickenSmoothieScripts (you need an account to see links)
    // @version 2.0
    //  @(you need an account to see links)cription Automatically refreshes the current Chicken Smoothie page and attempts to collect the giveaway prize when detected.
    //  @(you need an account to see links)ch (you need an account to see links)
    // ==/UserScript==
    
    (function() {
    
    var pageWaitMax = 10000;
    var pageWaitMin = 5000;
    
    var giveawayLink = null;
    var links = document.getElementsByTagName("a");
    
    for (var i = 0; (!giveawayLink && i < links.length); i++)
    if (links[i].href && links[i].href.match(/space\/asteroids\?token=[a-z0-9]+&time=[0-9]+/i)) giveawayLink = links[i];
    
    if (giveawayLink) {
    
    setTimeout
    (
    
    function() {
    
    location.href = location.href;
    },
    (Math.round(Math.random() * (pageWaitMax - pageWaitMin)) + pageWaitMin)
    );
    
    var iframe = document.createElement("iframe");
    
    iframe.onload = function() {
    
    location.href = location.href;
    };
    
    iframe.style.height =
    iframe.style.width = "0";
    iframe.style.visibility = "hidden";
    
    document.body.appendChild(iframe);
    
    iframe.src = giveawayLink.href;
    }
    
    })();
    @(you need an account to see links)

    I moved the wait to before clicking the link, let me know if it works.

    Last edited by Daviid; 07-19-2016 at 10:00 AM.

  7. #6
    CaptainNight's Avatar
    Joined
    Jul 2014
    Posts
    306
    Userbars
    7
    Thanks
    81
    Thanked
    199/84
    DL/UL
    29/3
    Mentioned
    27 times
    Time Online
    12d 5h 51m
    Avg. Time Online
    4m
    @(you need an account to see links) No it didnt work, its now just refreshing very very fast. Can the wait be in 2 locations? I dunno

    Sorry to make this difficult haha

    Thank you for your help, you know more than me
    [CENTER]Lazy and Paranoid

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •