Difference between revisions of "User:Troylaurin"
Jump to navigation
Jump to search
Troylaurin (talk | contribs) |
Troylaurin (talk | contribs) m |
||
Line 84: | Line 84: | ||
|craft init | |craft init | ||
| | | | ||
− | * On wake | + | *On wake |
− | | | + | | |
|9 | |9 | ||
| | | | ||
Line 189: | Line 189: | ||
<br /> | <br /> | ||
| | | | ||
− | * not busy crafting | + | *not busy crafting |
|1 | |1 | ||
| | | | ||
Line 219: | Line 219: | ||
<br /> | <br /> | ||
| | | | ||
− | * not busy crafting | + | *not busy crafting |
|2 | |2 | ||
| | | | ||
Line 257: | Line 257: | ||
2 actions | 2 actions | ||
| | | | ||
− | * not busy crafting | + | *not busy crafting |
|2 | |2 | ||
| | | | ||
Line 298: | Line 298: | ||
5 actions | 5 actions | ||
| | | | ||
− | * not busy crafting | + | *not busy crafting |
|5 | |5 | ||
| | | | ||
Line 347: | Line 347: | ||
5 actions | 5 actions | ||
| | | | ||
− | * not busy crafting | + | *not busy crafting |
|5 | |5 | ||
| | | | ||
Line 393: | Line 393: | ||
<br /> | <br /> | ||
| | | | ||
− | * not busy crafting | + | *not busy crafting |
|1 | |1 | ||
| | | |
Revision as of 01:36, 19 January 2021
A bunch of scripts to craft stuff.
Click to copy (tamperscript) |
---|
// ==UserScript==
// @name Click to copy on <pre> tags
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Add click to copy buttons to <pre> tags
// @author Troy.Laurin@gmail.com
// @match https://www.perfecttower2.com/wiki/*
// @grant GM_addStyle
// @require https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/2.0.6/clipboard.min.js
// @require http://code.jquery.com/jquery-3.5.1.slim.min.js
// ==/UserScript==
(function() {
'use strict';
// ------------------------------------------
// CSS part injected in the page
GM_addStyle(" \
.precontainer { \
position: relative; \
} \
.copy-btn { \
background: #DDD; \
font-family: monospace; \
font-weight: bolder; \
margin: 0; \
opacity: 0; \
padding: 4px; \
position: absolute; \
right: 1px; \
top: 1px; \
cursor: pointer; \
-webkit-transition: opacity 0.3s ease-in-out; \
-o-transition: opacity 0.3s ease-in-out; \
transition: opacity 0.3s ease-in-out; \
} \
.precontainer:hover >.copy-btn { \
opacity: 1; \
} \
table { width: 100% } \
");
$('pre').wrap('<div class="precontainer"></div>');
$('pre').before($('<span class="copy-btn"></></span>'));
new ClipboardJS('.copy-btn', {
text: function(trigger) {
return $(trigger.nextElementSibling).text();
}
})
.on('success',function (e) {
$(e.trigger).html("<copied/>")
setTimeout(function() {
$(e.trigger).html("</>");
}, 3000);
})
.on('error',function (e) {
$(e.trigger).html("Error!")
setTimeout(function() {
$(e.trigger).html("</>");
}, 3000);
});
})();
|
IN DEVELOPMENT. USE AT YOUR OWN RISK.
General scripts
Script | Impulses | Conditions | Lines | Source | |||
---|---|---|---|---|---|---|---|
craft init |
|
9 |
| ||||
craft GO |
|
|
12 |
| |||
craft tier up |
|
|
1 |
| |||
craft mode up |
|
|
2 |
| |||
craft output up | 1 impulse
1 condition
2 actions |
|
2 |
| |||
craft count up | 1 impulse
1 condition
5 actions |
|
5 |
| |||
craft count down | 1 impulse
1 condition
5 actions |
|
5 |
| |||
craft inventory use |
|
|
1 |
| |||
craft script check | 3 |
| |||||
craft producer set (pg1) |
|
|
14 |
| |||
craft producer set (pg2) |
|
|
13 |
| |||
craft machine set |
|
|
4 |
| |||
craft ingot | 15 |
|
Parts scripts
Output | Part | Scripts | |||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | chips |
| |||||||||||||||||||||||||||
2 | plates |
| |||||||||||||||||||||||||||
3 | dense plates |
| |||||||||||||||||||||||||||
4 | blocks |
| |||||||||||||||||||||||||||
5 | cables |
| |||||||||||||||||||||||||||
6 | insulated cables |
| |||||||||||||||||||||||||||
7 | rods |
| |||||||||||||||||||||||||||
8 | motors |
| |||||||||||||||||||||||||||
9 | pumps |
|
Producer scripts
Machine scripts
Name | Lines | Code | |||
---|---|---|---|---|---|
x | x |
|