One option is to download the repository from https://github.com/screeps/docs and host your own web server to browse. Another option is to install a web page archive plugin to your browser and download website.
Posts made by stybbe
-
RE: Can I download the documentation?
-
RE: New improved WebGL renderer
This room state hang the tab for me when using webgl renderer. Work just fine with the old one. It was the same issue when it was live and not only in the replay view. https://screeps.com/a/#!/history/shard0/W22S18?t=22318600.
-
RE: Changelog 2017-09-28
@hyramgraff said in Changelog 2017-09-28:
I must admit that I'm a bit nostalgic about the default names that were generated by
createCreep
. Is there a way to expose the function that it was using to generate creep names?The function is posted in this thread https://screeps.com/forum/topic/626/please-give-us-access-to-random-name-generator-for-creeps/5
-
RE: Unable to play for 19 hours. No response from support.
Have you tried creating a new branch? Or clearing your memory? The patch introduces a lot of bugs so I guess the Artem is quite busy right now.
-
RE: Objects initialized outside of loop get constantly reset
Ye it's all normal, everyone has it.
-
RE: Request: Ranking by GCL
If you need any help calculating the GLC from stats.energyControl you can check this code.
-
RE: Url to show room with selected object by it's id
If you're using Chrome and the Screeps SC extension you can add your own little module to have this feature.
Example:
In settings.json
{
"path": "modules/room.select.objectid.js",
"runAt":{
"onUpdate": "https://screeps.com/a/#!/room/"
}
}Create a new file modules/room.select.objectid.js
/**
* @summary Select object by id on room access.
*
* Example: https://screeps.com/a/#!/room/W10S10?objectid=57cd3a30c0551957424a1f47
*
*/
module.exports.init = function () {
module.getScopeData("room", "Room", ['Room.objects'], function (Room) {
var id = module.exports.getParameterByName("objectid");
var objects = _.filter(Room.objects, { _id: id });
if (objects.length) {
Room.selectedObject = objects[0];
} else {
console.warn("Could not select object by id: " + id)
}
});
}
module.exports.update = function () {
// not used.
}
// http://stackoverflow.com/questions/901115/how-can-i-get-query-string-values-in-javascript/901144#901144
module.exports.getParameterByName = function (name, url) {
if (!url) {
url = window.location.href;
}
name = name.replace(/[[\]]/g, "\\$&");
var regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"),
results = regex.exec(url);
if (!results) return null;
if (!results[2]) return '';
return decodeURIComponent(results[2].replace(/\+/g, " "));
} -
RE: Useful utilities
I've made a chrome extension for screeps. The extension is built so it's very easy to write and add your own modules. The project includes modules I've made so if you just want some nice extra client features you can install and use it in its current form.
See the repository at: https://github.com/stybbe/Screeps-SC
-
RE: Increase max simulation speed
You could try changing the limit to see if your code run faster, but there is a limit on how fast your browser can process each tick. You could probably run it a lot faster if you host a local server to test your code.
Type the following in the console to change the limit
angular.element(document.getElementsByClassName('game ng-scope')).scope().Game.maxSpeed = 1000