Inventory requester

Inventory framework

Tính đến 21-10-2017. Xem phiên bản mới nhất.

Script này sẽ không được không được cài đặt trực tiếp. Nó là một thư viện cho các script khác để bao gồm các chỉ thị meta // @require https://update.greasyfork.org/scripts/34367/225309/Inventory%20requester.js

// ==UserScript==
// @name         Inventory requester
// @version      0.2
// @description  Inventory framework
// @author       A Meaty Alt
// @match        http://fairview.deadfrontier.com/onlinezombiemmo/index.php?page=35
// @grant        none
// ==/UserScript==

function getPlayerValues(params){
    return new Promise(function(resolve){
        var id = params.match(/userID=(.*?)&/)[1];
        var hashedPassword = params.match(/password=(.*?)&/)[1];
        $.post("https://fairview.deadfrontier.com/onlinezombiemmo/get_values.php",
               "userID="+id+"&password="+hashedPassword,
               function(response){
            resolve(response);
        });
    });
}