Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kenorb/a58df5fc6bda24840f163146ac894860 to your computer and use it in GitHub Desktop.
Save kenorb/a58df5fc6bda24840f163146ac894860 to your computer and use it in GitHub Desktop.
Downloads all the free Mixamo Animations

Step 1

Go to https://www.mixamo.com/store/#/search?page=1, make sure you're logged in.

Step 2

open up chrome console by pressing F12 on your keyboard on the Mixamo webpage. Click on the "Console" tab in the new window (developer console).

Step 3

Paste in "DownloadMixamoByJakeCattrall.js" into the console input and return. It'll starting downloading from that page and until the last page.

function trigger(el, eventType) {
if (typeof eventType === 'string' && typeof el[eventType] === 'function') {
el[eventType]();
} else {
const event =
eventType === 'string'
? new Event(eventType, {bubbles: true})
: eventType;
el.dispatchEvent(event);
}
}
function fetchList() {
return document.querySelectorAll(".product-results-holder .product-animation")
}
const wait = (ms) => new Promise(resolve => setTimeout(resolve, ms));
const nextPage = async () => {
var lastButton = document.querySelectorAll(".pagination.pagination-sm li:last-child a")
trigger(lastButton[0], "click")
await wait(5000)
}
const start = async () => {
list = fetchList()
for (var i = 0; i <= list.length; i++) {
if (i >= list.length) {
await nextPage()
list = fetchList()
if (list.length == 0) {
return alert("Done!")
}
i = 0
window.scrollTo(0, document.body.scrollHeight);
}
trigger(list[i], "click")
await wait(5000)
var download = document.querySelectorAll(".product-preview-holder .editor.row.row-no-gutter > div.editor-sidebar.col-xs-4 button")[0]
trigger(download, "click")
await wait(800)
var select = document.querySelectorAll("select.input-sm.form-control")[4]; select.value = 2; select.dispatchEvent(new Event('change', {bubbles: true}));
await wait(500)
var select = document.querySelectorAll("select.input-sm.form-control")[3]; select.value = 24; select.dispatchEvent(new Event('change', {bubbles: true}));
await wait(500)
var download2 = document.querySelectorAll(".modal-footer .btn-primary")[0]
trigger(download2, "click")
await wait(8000)
console.log(`Completed item ${i} of ${list.length - 1}`)
}
}
start()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment