Multiplayer Spades: Include Function

Name: include [client/server]

Description: Include another *.js file to the game.

Support versions: 0.9 beta test 1 – …

Usage:

include(string file, function callback);
  1. string file
    The URL address. Example: http://sample.com/folder/script.js
  2. function callback
    Callback when script is loaded.

Examples:

include("//gameclient.ml/uploads/sampleuser/script.js", function() {
     alert("Successfully included!");
});
var fn = function() {
     alert("Successfully included!");
};
var url = "//gameclient.ml/uploads/sampleuser/script.js";
include(url, fn);

Leave a Reply

Your email address will not be published. Required fields are marked *