Now I'll show you how to make a GG and a map together!
- Open the browser Opera.
- Go to the map
- We get down in a flush-free region
- Click RMB select the source code
- Copy the script (see script below), paste it to the end but until:
Code:
</body> </html>
------------------------------- 1st Script----------------------------------
Here's a variation with one button but without log and inappropriately insert SID & ID + GG Warning clicked yourself until you again click on the button!
Code:
<script>
var req;
var started = false;
var url = '/flashinput/galaxyGates.php?userID=' + BpTrack['uid'] + '&action=energy&sid=' + BpTrack['sid'] + '&sample=1';
var samples = '';
function loadXMLDoc(url) {
if (started == false)
return;
if (window.XMLHttpRequest) {
req = new XMLHttpRequest();
req.onreadystatechange = processReqChange;
req.open("GET", url, true);
req.send(null);
} else if (window.ActiveXObject) {
req = new ActiveXObject("Microsoft.XMLHTTP");
if (req) {
req.onreadystatechange = processReqChange;
req.open("GET", url, true);
req.send();
}
}
}
function processReqChange() {
if (req.readyState == 4) {
// для статуса "OK"
if (req.status == 200) {
// здесь идут всякие штуки с полученным ответом
var start = req.responseText.indexOf('<samples>');
var end = req.responseText.indexOf('</samples>');
samples = req.responseText.substring(start + 9, end);
if (started == true)
document.getElementById('sample').innerHTML = "Energy stop " + samples;
else
document.getElementById('sample').innerHTML = "Energy start " + samples;
}
}
}
function start() {
if (started == true) {
started = false;
document.getElementById('sample').innerHTML = "Energy start " + samples;
} else {
started = true;
document.getElementById('sample').innerHTML = "Energy stop " + samples;
}
}
window.setInterval("loadXMLDoc(url)", 200);
</script>
<button id="sample" onclick="start(); return;">Energy start</button>
The script itself takes SID & ID + a log, but no switch (that is, the button must be pressed himself).
Code:
<script>
var req;
var url = '/flashinput/galaxyGates.php?userID=' + BpTrack['uid'] + '&action=energy&sid=' + BpTrack['sid'] + '&sample=1';
var money = '';
var samples = '';
var battery = ['', '', 'MCB-25', 'MCB-50', 'UCB-50', 'SAB'];
var gate = ['', 'α', 'β', 'γ', 'δ'];
function loadXMLDoc(url) {
if (window.XMLHttpRequest) {
req = new XMLHttpRequest();
req.onreadystatechange = processReqChange;
req.open("GET", url, true);
req.send(null);
} else if (window.ActiveXObject) {
req = new ActiveXObject("Microsoft.XMLHTTP");
if (req) {
req.onreadystatechange = processReqChange;
req.open("GET", url, true);
req.send();
}
}
}
function processReqChange() {
if (req.readyState == 4) {
// для статуса "OK"
if (req.status == 200) {
// здесь идут всякие штуки с полученным ответом
xml = req.responseXML;
if (xml.getElementsByTagName('error')[0] !== undefined) {
return;
}
samples = xml.getElementsByTagName('samples')[0].firstChild.nodeValue;
money = xml.getElementsByTagName('money')[0].firstChild.nodeValue;
update();
var items = xml.getElementsByTagName('item');
for (var i = 0; i < items.length; i++) {
var item = items[i];
var type = item.getAttribute('type');
if (type == 'hitpoints') {
log(item.getAttribute('amount') + ' Extra Strength');
} else if (type == 'rocket') {
var item_id = item.getAttribute('item_id');
var amount = item.getAttribute('amount');
if (item_id == '11') {
if (amount == '1')
log('1 Bomb ACM-1');
else
log('Bomb ACM-1 (' + amount + ' шт.)');
} else
log('Rockets PLT-2021 (' + amount + ' шт.)');
} else if (type == 'battery') {
log('Type: ' + battery[item.getAttribute('item_id')] + ' (' + item.getAttribute('amount') + ' шт.)');
} else if (type == 'ore') {
log('Type: Xenomit (' + item.getAttribute('amount') + ' шт.)');
} else if (type == 'logfile') {
var amount = item.getAttribute('amount');
if (amount == '1')
log('1 log-disk');
else
log('Log-disks: ' + amount);
} else if (type == 'voucher') {
var amount = item.getAttribute('amount');
if (amount == '1')
log('1 Coupon repair');
else
log(amount + 'Coupon repair');
} else if (type == 'part') {
var duplicate = item.getAttribute('duplicate');
if (duplicate != undefined)
log('Multiplier x' + xml.getElementsByTagName('multiplier')[0].getAttribute('value'));
else
log('Part ' + item.getAttribute('part_id') + '/teleport ' + gate[item.getAttribute('gate_id')]);
}
}
}
}
}
function update() {
document.getElementById('sample').innerHTML = "Energy | URI: " + money + " | Energy: " + samples;
}
function log(message) {
document.getElementById('log').innerHTML = message + '\n' + document.getElementById('log').innerHTML;
}
</script>
<button id="sample" onclick="loadXMLDoc(url);">Energy</button><br />
<textarea id="log" cols="50" rows="3">Galaxy Gates log...</textarea>






