// ==UserScript== // @name Neopets Random Lottery Links // @namespace shiftasterisk // @version 0.1 // @description Button to generate 20 random lottery ticket links on neopets // @author shiftasterisk // @match http://www.neopets.com/games/lottery.phtml // @include https://code.jquery.com/jquery-3.1.1.min.js // @grant none // @downloadURL https://update.greasyfork.icu/scripts/26139/Neopets%20Random%20Lottery%20Links.user.js // @updateURL https://update.greasyfork.icu/scripts/26139/Neopets%20Random%20Lottery%20Links.meta.js // ==/UserScript== $('input[type="submit"][value="Buy a Lottery Ticket!"]').parent().append(""); $('input[type="submit"][value="Buy a Lottery Ticket!"]').parent().parent().parent().append("
"); var numberOfTickets = 20; var tickets = []; $('#buyTwenty').click(function() { tickets = []; $("#linkContainer").empty(); selectTickets(); displayTicketLinks(); }); function displayTicketLinks() { for(x = 0; x < tickets.length; x++) { $("#linkContainer").append('Ticket ' + (x+1) + '