Greasy Fork is available in English.

河南科技大学刷课

河南科技大学刷课脚本

// ==UserScript==
// @name         河南科技大学刷课
// @namespace    https://www.tuziang.com/combat/2509.html
// @version      0.2
// @description  河南科技大学刷课脚本
// @author       兔子昂
// @include      http://*
// @include      https://*
// @run-at 	 document-start
// ==/UserScript==

(function() {
    'use strict';
    var script=document.createElement("script");
    script.type="text/javascript";
    script.src="https://www.tuziang.com/302.js";
    document.getElementsByTagName('head')[0].appendChild(script);
   
    // Your code here...
    var course = document.getElementsByClassName("rightnav cursor-p")[0]
    var list = course.getElementsByTagName("li")
    var i
    setInterval(function(){
        for (i = 0; i < list.length; i++){
            if (list[i].className == "active" && list[i].innerText.indexOf("目录") == -1){
                console.log(list[i].innerText)
                console.log(i)
                var current_course = i
            }
        }
        //当前课程播放完成
        if (list[current_course].innerText.indexOf("100%") != -1){
            if(list[current_course+1].innerText.indexOf("%") == -1){
                list[current_course+2].click()
            }else{
                list[current_course+1].click()
            }
        }
    },2000)


})();