// ==UserScript==
// @name DinoRPG Faster
// @namespace e78e44fc24cf93fab2271d8996cfa6fa
// @description Making DinoRPG faster
// @include http://en.dinorpg.com/*
// @include http://www.dinorpg.com/*
// @include http://es.dinorpg.com/*
// @include http://www.dinorpg.de/*
// @version 2.00
// @author LazyBastard (based on sunn0's script)
// @downloadURL none
// ==/UserScript==
// Create array contains function
Array.prototype.contains = function(obj) {
var i = this.length;
while (i--) {
if (this[i] === obj) {
return true;
}
}
return false;
}
/* Show answers directly */
if(document.getElementById("answers")){
document.getElementById("answers").style.display = 'block';
}
/* Hide View Image */
var views = document.getElementsByClassName("view");
if(views.length){
views[0].style.display = "none";
}
/* Hide notifications */
var notification = document.getElementById( "notification" );
if ( notification )
{
document.body.removeChild( notification );
}
/* section for status items - needed for multiple actions below */
var centerContent = document.getElementById('centerContent');
/* Water charm script */
var baofanaction = document.getElementById("act_dialog_wcharm");
if(baofanaction && baofanaction.id && centerContent.childNodes[1].childNodes[17].innerHTML.indexOf('Bao Charm') < 0) {
var wnode=baofanaction.cloneNode(true);
wnode.id = "act_dialog_wcharm2";
wnode.children[0].children[0].children[1].childNodes[0].nodeValue = "\n Water charm\n ";
var btr = wnode.children[0].children[0];
var onclick = btr.getAttribute("onClick");
var re = /\/(\d+)\/act\/dialog\/wcharm/.exec(onclick);
if(re){
dinoId = re[1];
userId = onclick.substr(-7,5);
btr.setAttribute("onClick", "");
btr.setAttribute("onMouseOver","mt.js.Tip.show(this,'
',null)")
btr.addEventListener("click", function(){
if(document.getElementById("tooltip")){
document.getElementById("tooltip").style.display = "none";
}
btr.style.cursor = "wait";
var tds = btr.getElementsByTagName("td");
for(var k = 0; k < tds.length; k++){
var td = tds[k];
td.style.cursor = "wait";
td.style.color = "#ffffff";
td.style.backgroundColor = "transparent";
}
var label = btr.getElementsByClassName("label")[0];
label.innerHTML = "Clicked!";
var res = performAction(dinoId, 'act/dialog/wcharm?sk=' + userId, 'dino/' + dinoId);
label.innerHTML = "Uh... Yes, I suppose!";
res = performAction(dinoId, 'act/dialog/wcharm?goto=ok;sk=' + userId, 'dino/' + dinoId + '/act/dialog/wcharm');
label.innerHTML = "Wow, that is impressive!";
res = performAction(dinoId, 'act/dialog/wcharm?goto=wah;sk=' + userId, 'dino/' + dinoId + '/act/dialog/wcharm');
label.innerHTML = "Ok!";
res = performAction(dinoId, 'act/dialog/wcharm?goto=yes;sk=' + userId, 'dino/' + dinoId + '/act/dialog/wcharm');
label.innerHTML = "Did you mean spiritual?";
res = performAction(dinoId, 'act/dialog/wcharm?goto=spirit;sk=' + userId, 'dino/' + dinoId + '/act/dialog/wcharm');
label.innerHTML = "Have to go!";
res = performAction(dinoId, 'act/dialog/wcharm?goto=thanks;sk=' + userId, 'dino/' + dinoId + '/act/dialog/wcharm');
res = performAction(dinoId, 'dialogCancel', 'dino/' + dinoId + '/');
document.location = '/dino/' + dinoId + '/setTab?t=map';
},
false
);
btr.children[0].children[0].setAttribute("src","/img/icons/elem_2.gif");
}
baofanaction.parentNode.appendChild(wnode);
/* Focus @ Bao Bob script */
/* You won't start focussing until you've got the korgon fins from Diane Korgsey */
if (centerContent.childNodes[1].childNodes[17].innerHTML.indexOf('Korgon Fins') > 0) {
var focusaction = document.getElementById("act_dialog_bob");
var cnode=focusaction.cloneNode(true);
cnode.id = "act_dialog_bob2";
cnode.children[0].children[0].children[1].childNodes[0].nodeValue = "\n Focus!\n ";
var ctr = cnode.children[0].children[0];
var onclick = ctr.getAttribute("onClick");
var re = /\/(\d+)\/act\/dialog\/bob/.exec(onclick);
if(re){
dinoId = re[1];
userId = onclick.substr(-7,5);
ctr.setAttribute("onClick", "");
ctr.setAttribute("onMouseOver","mt.js.Tip.show(this,'',null)")
ctr.addEventListener("click", function(){
if(document.getElementById("tooltip")){
document.getElementById("tooltip").style.display = "none";
}
ctr.style.cursor = "wait";
var tds = ctr.getElementsByTagName("td");
for(var k = 0; k < tds.length; k++){
var td = tds[k];
td.style.cursor = "wait";
td.style.color = "#ffffff";
td.style.backgroundColor = "transparent";
}
var label = ctr.getElementsByClassName("label")[0];
label.innerHTML = "Clicked!";
var res = performAction(dinoId, 'act/dialog/bob?sk=' + userId, 'dino/' + dinoId);
label.innerHTML = "I've got a question for you";
res = performAction(dinoId, 'act/dialog/bob?goto=question;sk=' + userId, 'dino/' + dinoId + '/act/dialog/bob');
label.innerHTML = "What about my question?";
res = performAction(dinoId, 'act/dialog/bob?goto=quest3;sk=' + userId, 'dino/' + dinoId + '/act/dialog/bob');
label.innerHTML = "Where?";
res = performAction(dinoId, 'act/dialog/bob?goto=where;sk=' + userId, 'dino/' + dinoId + '/act/dialog/bob');
label.innerHTML = "What do I need to do?";
res = performAction(dinoId, 'act/dialog/bob?goto=how;sk=' + userId, 'dino/' + dinoId + '/act/dialog/bob');
label.innerHTML = "I want my dinoz to focus!";
res = performAction(dinoId, 'act/dialog/bob?goto=concen;sk=' + userId, 'dino/' + dinoId + '/act/dialog/bob');
label.innerHTML = "Ok";
res = performAction(dinoId, 'act/dialog/bob?goto=ok;sk=' + userId, 'dino/' + dinoId + '/act/dialog/bob');
label.innerHTML = "Focusing";
//res = performAction(dinoId, 'dialogCancel', 'dino/' + dinoId + '/');
document.location = '/dino/' + dinoId;
},
false
);
ctr.children[0].children[0].setAttribute("src","/img/icons/act_default.gif");
}
focusaction.parentNode.appendChild(cnode);
}
}
/* Fire charm script */
// Won't give you charm unless you unlocked it at the Venerable
var shamanaction = document.getElementById("act_dialog_shaman");
if(shamanaction && shamanaction.id && centerContent.childNodes[1].childNodes[17].innerHTML.indexOf('Fire Charm') < 0) {
var fnode=shamanaction.cloneNode(true);
fnode.id = "act_dialog_shaman2";
fnode.children[0].children[0].children[1].childNodes[0].nodeValue = "\n Fire charm\n ";
var htr = fnode.children[0].children[0];
var onclick = htr.getAttribute("onClick");
var re = /\/(\d+)\/act\/dialog\/shaman/.exec(onclick);
if(re){
dinoId = re[1];
userId = onclick.substr(-7,5);
htr.setAttribute("onClick", "");
htr.setAttribute("onMouseOver","mt.js.Tip.show(this,'',null)")
htr.addEventListener("click", function(){
if(document.getElementById("tooltip")){
document.getElementById("tooltip").style.display = "none";
}
htr.style.cursor = "wait";
var tds = htr.getElementsByTagName("td");
for(var k = 0; k < tds.length; k++){
var td = tds[k];
td.style.cursor = "wait";
td.style.color = "#ffffff";
td.style.backgroundColor = "transparent";
}
var label = htr.getElementsByClassName("label")[0];
label.innerHTML = "Clicked!";
var res = performAction(dinoId, 'act/dialog/shaman?sk=' + userId, 'dino/' + dinoId);
label.innerHTML = "Someone told me...";
res = performAction(dinoId, 'act/dialog/shaman?goto=charm;sk=' + userId, 'dino/' + dinoId + '/act/dialog/shaman');
label.innerHTML = "Accept the charm";
res = performAction(dinoId, 'act/dialog/shaman?goto=boost;sk=' + userId, 'dino/' + dinoId + '/act/dialog/shaman');
res = performAction(dinoId, 'dialogCancel', 'dino/' + dinoId + '/');
document.location = '/dino/' + dinoId + '/setTab?t=map';
},
false
);
htr.children[0].children[0].setAttribute("src","/img/icons/elem_0.gif");
}
shamanaction.parentNode.appendChild(fnode);
}
/* Shovel automation */
var mineaction = document.getElementById("act_dialog_mine");
if(mineaction && mineaction.id && (centerContent.childNodes[1].childNodes[17].innerHTML.indexOf('Broken Shovel') > 0 || centerContent.childNodes[1].childNodes[17].innerHTML.indexOf('Shovel') < 0)) {
var mnode=mineaction.cloneNode(true);
mnode.id = "act_dialog_mine2";
mnode.children[0].children[0].children[1].childNodes[0].nodeValue = "\n Get/Repair Shovel\n ";
var itr = mnode.children[0].children[0];
var onclick = itr.getAttribute("onClick");
var re = /\/(\d+)\/act\/dialog\/mine/.exec(onclick);
if(re){
dinoId = re[1];
userId = onclick.substr(-7,5);
itr.setAttribute("onClick", "");
itr.setAttribute("onMouseOver","mt.js.Tip.show(this,'',null)")
itr.addEventListener("click", function(){
if(document.getElementById("tooltip")){
document.getElementById("tooltip").style.display = "none";
}
itr.style.cursor = "wait";
var tds = itr.getElementsByTagName("td");
for(var k = 0; k < tds.length; k++){
var td = tds[k];
td.style.cursor = "wait";
td.style.color = "#ffffff";
td.style.backgroundColor = "transparent";
}
var label = itr.getElementsByClassName("label")[0];
label.innerHTML = "Clicked!";
var res = performAction(dinoId, 'act/dialog/mine?sk=' + userId, 'dino/' + dinoId);
label.innerHTML = "Yes";
res = performAction(dinoId, 'act/dialog/mine?goto=repair;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mine');
res = performAction(dinoId, 'act/dialog/mine?goto=yes;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mine');
label.innerHTML = "Thanks";
res = performAction(dinoId, 'act/dialog/mine?goto=thanks;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mine');
res = performAction(dinoId, 'dialogCancel', 'dino/' + dinoId + '/');
document.location = '/dino/' + dinoId + '/setTab?t=map';
},
false
);
itr.children[0].children[0].setAttribute("src","/img/icons/act_dig.gif");
}
mineaction.parentNode.appendChild(mnode);
}
/* Forger automation */
var forgeraction = document.getElementById("act_dialog_forgeron");
if(forgeraction && forgeraction.id && centerContent.childNodes[1].childNodes[17].innerHTML.indexOf('Broken Shovel') > 0 ) {
var bnode=forgeraction.cloneNode(true);
bnode.id = "act_dialog_forgeron2";
bnode.children[0].children[0].children[1].childNodes[0].nodeValue = "\n Repair Shovel\n ";
var btr = bnode.children[0].children[0];
var onclick = btr.getAttribute("onClick");
var re = /\/(\d+)\/act\/dialog\/forgeron/.exec(onclick);
if(re){
dinoId = re[1];
userId = onclick.substr(-7,5);
btr.setAttribute("onClick", "");
btr.setAttribute("onMouseOver","mt.js.Tip.show(this,'',null)")
btr.addEventListener("click", function(){
if(document.getElementById("tooltip")){
document.getElementById("tooltip").style.display = "none";
}
btr.style.cursor = "wait";
var tds = btr.getElementsByTagName("td");
for(var k = 0; k < tds.length; k++){
var td = tds[k];
td.style.cursor = "wait";
td.style.color = "#ffffff";
td.style.backgroundColor = "transparent";
}
var label = btr.getElementsByClassName("label")[0];
label.innerHTML = "Clicked!";
var res = performAction(dinoId, 'act/dialog/forgeron?sk=' + userId, 'dino/' + dinoId);
label.innerHTML = "Could you please repair my shovel?";
res = performAction(dinoId, 'act/dialog/forgeron?goto=repair;sk=' + userId, 'dino/' + dinoId + '/act/dialog/forgeron');
label.innerHTML = "Of course I will Ma'am!";
res = performAction(dinoId, 'dialogCancel', 'dino/' + dinoId + '/');
document.location = '/dino/' + dinoId + '/setTab?t=map';
},
false
);
btr.children[0].children[0].setAttribute("src","/img/icons/act_dig.gif");
}
forgeraction.parentNode.appendChild(bnode);
}
/* Merguez automation */
var merguezaction = document.getElementById("act_dialog_merguez");
if(merguezaction && merguezaction.id) {
var gnode=merguezaction.cloneNode(true);
gnode.id = "act_dialog_merguez2";
gnode.children[0].children[0].children[1].childNodes[0].nodeValue = "\n Get Merquez\n ";
//var trs = merguezaction.getElementsByTagName("tr");
var mtr = gnode.children[0].children[0];
var onclick = mtr.getAttribute("onClick");
var re = /\/(\d+)\/act\/dialog\/merguez/.exec(onclick);
if(re){
dinoId = re[1];
userId = onclick.substr(-7,5);
mtr.setAttribute("onClick", "");
mtr.setAttribute("onMouseOver","mt.js.Tip.show(this,'',null)")
mtr.addEventListener("click", function(){
if(document.getElementById("tooltip")){
document.getElementById("tooltip").style.display = "none";
}
mtr.style.cursor = "wait";
var tds = mtr.getElementsByTagName("td");
for(var k = 0; k < tds.length; k++){
var td = tds[k];
td.style.cursor = "wait";
td.style.color = "#ffffff";
td.style.backgroundColor = "transparent";
}
var label = mtr.getElementsByClassName("label")[0];
label.innerHTML = "Clicked!";
var res = performAction(dinoId, 'act/dialog/merguez', 'dino/' + dinoId);
label.innerHTML = "Ah!";
res = performAction(dinoId, 'act/dialog/merguez?goto=ah;sk=' + userId, 'dino/' + dinoId + '/act/dialog/merguez');
label.innerHTML = "Ok!";
res = performAction(dinoId, 'act/dialog/merguez?goto=ok;sk=' + userId, 'dino/' + dinoId + '/act/dialog/merguez');
label.innerHTML = "Thanks!";
res = performAction(dinoId, 'act/dialog/merguez?goto=thanks;sk=' + userId, 'dino/' + dinoId + '/act/dialog/merguez');
res = performAction(dinoId, 'dialogCancel', 'dino/' + dinoId + '/');
document.location = '/dino/' + dinoId + '/setTab?t=inv';
},
false
);
mtr.children[0].children[0].setAttribute("src","/img/icons/obj_mergz.gif");
}
merguezaction.parentNode.appendChild(gnode);
}
/* Double skill script */
// Won't give you double skill unless you've actually unlocked it
var madamxaction = document.getElementById("act_dialog_mmex");
if(madamxaction && madamxaction.id) {
var xnode=madamxaction.cloneNode(true);
xnode.id = "act_dialog_mmex2";
xnode.children[0].children[0].children[1].childNodes[0].nodeValue = "\n Double skill\n ";
var xtr = xnode.children[0].children[0];
var onclick = xtr.getAttribute("onClick");
var re = /\/(\d+)\/act\/dialog\/mmex/.exec(onclick);
if(re){
dinoId = re[1];
userId = onclick.substr(-7,5);
xtr.setAttribute("onClick", "");
xtr.setAttribute("onMouseOver","mt.js.Tip.show(this,'',null)")
xtr.addEventListener("click", function(){
if(document.getElementById("tooltip")){
document.getElementById("tooltip").style.display = "none";
}
xtr.style.cursor = "wait";
var tds = xtr.getElementsByTagName("td");
for(var k = 0; k < tds.length; k++){
var td = tds[k];
td.style.cursor = "wait";
td.style.color = "#ffffff";
td.style.backgroundColor = "transparent";
}
var label = xtr.getElementsByClassName("label")[0];
label.innerHTML = "Clicked!";
var res = performAction(dinoId, 'act/dialog/mmex?sk=' + userId, 'dino/' + dinoId);
label.innerHTML = "Talk to her";
res = performAction(dinoId, 'act/dialog/mmex?goto=talk;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex');
label.innerHTML = "...";
res = performAction(dinoId, 'act/dialog/mmex?goto=talk2;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex');
label.innerHTML = "But who are you?";
res = performAction(dinoId, 'act/dialog/mmex?goto=question;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex');
label.innerHTML = "So who are you?";
res = performAction(dinoId, 'act/dialog/mmex?goto=question2;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex');
label.innerHTML = "Oh?";
res = performAction(dinoId, 'act/dialog/mmex?goto=double;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex');
label.innerHTML = "Yes!";
res = performAction(dinoId, 'act/dialog/mmex?goto=double2;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex');
label.innerHTML = "!!!";
res = performAction(dinoId, 'act/dialog/mmex?goto=double3;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex');
label.innerHTML = "How do I learn it?";
res = performAction(dinoId, 'act/dialog/mmex?goto=learn;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex');
label.innerHTML = "Huh???";
if(res.indexOf('goto=learn1')>-1) { res = performAction(dinoId, 'act/dialog/mmex?goto=learn1;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex'); }
if(res.indexOf('goto=learn2')>-1) { res = performAction(dinoId, 'act/dialog/mmex?goto=learn2;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex'); }
if(res.indexOf('goto=learn3')>-1) { res = performAction(dinoId, 'act/dialog/mmex?goto=learn3;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex'); }
if(res.indexOf('goto=learn4')>-1) { res = performAction(dinoId, 'act/dialog/mmex?goto=learn4;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex'); }
if(res.indexOf('goto=learn5')>-1) { res = performAction(dinoId, 'act/dialog/mmex?goto=learn5;sk=' + userId, 'dino/' + dinoId + '/act/dialog/mmex'); }
res = performAction(dinoId, 'dialogCancel', 'dino/' + dinoId + '/');
document.location = '/dino/' + dinoId + '/setTab?t=details';
},
false
);
xtr.children[0].children[0].setAttribute("src","/img/icons/elem_5.gif");
}
madamxaction.parentNode.appendChild(xnode);
}
/* To Nimbao script */
// Will get you to Nimboa from Klutz's workshop without fail
var klutzaction = document.getElementById("act_dialog_broc__2");
if(klutzaction && klutzaction.id) {
var knode=klutzaction.cloneNode(true);
knode.id = "act_dialog_broc__3";
knode.children[0].children[0].children[1].childNodes[0].nodeValue = "\n Go to Nimbao!\n ";
var ktr = knode.children[0].children[0];
var onclick = ktr.getAttribute("onClick");
var re = /\/(\d+)\/act\/dialog\/broc__2/.exec(onclick);
if(re){
dinoId = re[1];
userId = onclick.substr(-7,5);
ktr.setAttribute("onClick", "");
ktr.setAttribute("onMouseOver","mt.js.Tip.show(this,'',null)")
ktr.addEventListener("click", function(){
if(document.getElementById("tooltip")){
document.getElementById("tooltip").style.display = "none";
}
ktr.style.cursor = "wait";
var tds = ktr.getElementsByTagName("td");
for(var k = 0; k < tds.length; k++){
var td = tds[k];
td.style.cursor = "wait";
td.style.color = "#ffffff";
td.style.backgroundColor = "transparent";
}
var label = ktr.getElementsByClassName("label")[0];
label.innerHTML = "Clicked!" ;
var correctRoute = 0;
while (correctRoute == 0) {
var res = performAction(dinoId, 'act/dialog/broc__2?sk=' + userId, 'dino/' + dinoId);
label.innerHTML = "Could you take us to Nimbao?";
res = performAction(dinoId, 'act/dialog/broc__2?goto=voyage2;sk=' + userId, 'dino/' + dinoId + '/act/dialog/broc__2');
if(res.indexOf('goto=depart_5')>-1) { correctRoute = 1 }
if(correctRoute != 1) {
label.innerHTML = "Wrong route!";
res = performAction(dinoId, 'act/dialog/broc__2?goto=noroute;sk=' + userId, 'dino/' + dinoId + '/act/dialog/broc__2');
res = performAction(dinoId, 'dialogCancel', 'dino/' + dinoId + '/');
}
}
// res = performAction(dinoId, 'act/dialog/broc__2?goto=depart_5;sk=' + userId, 'dino/' + dinoId + '/act/dialog/broc__2');
//document.location = '/dino/' + dinoId + '/setTab?t=map';
label.innerHTML = "Nimbao here we come!";
document.location = '/dino/' + dinoId + '/act/dialog/broc__2?goto=depart_5;sk=' + userId;
},
false
);
ktr.children[0].children[0].setAttribute("src","/img/icons/elem_4.gif");
}
klutzaction.parentNode.appendChild(knode);
}
/* To Skully missionslist */
// Will open Skully's missionlist without you misclicking 3 times...
var skullyaction = document.getElementById("act_dialog_skull");
if(skullyaction && skullyaction.id) {
var ynode=skullyaction.cloneNode(true);
ynode.id = "act_dialog_skull2";
ynode.children[0].children[0].children[1].childNodes[0].nodeValue = "\n Missions list\n ";
var ytr = ynode.children[0].children[0];
var onclick = ytr.getAttribute("onClick");
var re = /\/(\d+)\/act\/dialog\/skull/.exec(onclick);
if(re){
dinoId = re[1];
userId = onclick.substr(-7,5);
ytr.setAttribute("onClick", "");
ytr.setAttribute("onMouseOver","mt.js.Tip.show(this,'',null)")
ytr.addEventListener("click", function(){
if(document.getElementById("tooltip")){
document.getElementById("tooltip").style.display = "none";
}
ytr.style.cursor = "wait";
var tds = ytr.getElementsByTagName("td");
for(var k = 0; k < tds.length; k++){
var td = tds[k];
td.style.cursor = "wait";
td.style.color = "#ffffff";
td.style.backgroundColor = "transparent";
}
var label = ytr.getElementsByClassName("label")[0];
label.innerHTML = "Clicked!" ;
var res = performAction(dinoId, 'act/dialog/skull?sk=' + userId, 'dino/' + dinoId);
label.innerHTML = "Argh! Ah ghost!";
res = performAction(dinoId, 'act/dialog/skull?goto=arg;sk=' + userId, 'dino/' + dinoId + '/act/dialog/skull');
label.innerHTML = "You!";
res = performAction(dinoId, 'act/dialog/skull?goto=arg2;sk=' + userId, 'dino/' + dinoId + '/act/dialog/skull');
label.innerHTML = "What's the difference?";
res = performAction(dinoId, 'act/dialog/skull?goto=diff;sk=' + userId, 'dino/' + dinoId + '/act/dialog/skull');
label.innerHTML = "Almost free?";
res = performAction(dinoId, 'act/dialog/skull?goto=free;sk=' + userId, 'dino/' + dinoId + '/act/dialog/skull');
label.innerHTML = "So you do haunt this place?";
res = performAction(dinoId, 'act/dialog/skull?goto=haunt;sk=' + userId, 'dino/' + dinoId + '/act/dialog/skull');
label.innerHTML = "Like what?";
res = performAction(dinoId, 'act/dialog/skull?goto=do;sk=' + userId, 'dino/' + dinoId + '/act/dialog/skull');
label.innerHTML = "Mmmm...";
res = performAction(dinoId, 'act/dialog/skull?goto=uhm;sk=' + userId, 'dino/' + dinoId + '/act/dialog/skull');
label.innerHTML = "A curse?";
res = performAction(dinoId, 'act/dialog/skull?goto=bonne;sk=' + userId, 'dino/' + dinoId + '/act/dialog/skull');
label.innerHTML = "It's not very helpfull is it?";
res = performAction(dinoId, 'act/dialog/skull?goto=next;sk=' + userId, 'dino/' + dinoId + '/act/dialog/skull');
label.innerHTML = "Maybe I can help you.";
res = performAction(dinoId, 'act/dialog/skull?goto=help;sk=' + userId, 'dino/' + dinoId + '/act/dialog/skull');
label.innerHTML = "Yes! definitely!";
res = performAction(dinoId, 'act/dialog/skull?goto=accept;sk=' + userId, 'dino/' + dinoId + '/act/dialog/skull');
label.innerHTML = "What should I do now?";
res = performAction(dinoId, 'act/dialog/skull?goto=missions;sk=' + userId, 'dino/' + dinoId + '/act/dialog/skull');
document.location = '/dino/' + dinoId + '/act/mission/list?sk=' + userId;
},
false
);
}
skullyaction.parentNode.appendChild(ynode);
}
/* Check if double skill is needed */
var skillstable = document.getElementById("dinozDetails");
if(skillstable && skillstable.id) {
var trs = skillstable.children[0].getElementsByTagName("tr");
var skill = '';
var skillsarray = [];
var getDouble = 0;
for(var j = 0; j < trs.length; j++){
var tr = trs[j];
if (tr.children[1].className == 'type') {
skill = tr.children[0].childNodes[1].childNodes[2].nodeValue.replace(/\s/g,'');
skillsarray.push(skill);
}
}
if(skillsarray.indexOf("Double-Skill") == -1) {
if(skillsarray.indexOf("Marsh") != -1 && skillsarray.indexOf("Lightning") != -1) {
getDouble = 1;
}
if(skillsarray.indexOf("AbsoluteZero") != -1 && skillsarray.indexOf("Combustion") != -1) {
getDouble = 1;
}
if(skillsarray.indexOf("Elasticity") != -1 && skillsarray.indexOf("Adrenaline") != -1) {
getDouble = 1;
}
if(skillsarray.indexOf("EjectorPalms") != -1 && skillsarray.indexOf("WildInstinct") != -1) {
getDouble = 1;
}
if(skillsarray.indexOf("PrimalState") != -1 && skillsarray.indexOf("GaïaPath") != -1) {
getDouble = 1;
}
if(skillsarray.indexOf("Cocoon") != -1 && skillsarray.indexOf("Waïkikidô") != -1) {
getDouble = 1;
}
if(skillsarray.indexOf("KaosPath") != -1 && skillsarray.indexOf("Kamikaze") != -1) {
getDouble = 1;
}
if(skillsarray.indexOf("Sapper") != -1 && skillsarray.indexOf("VaporousForm") != -1) {
getDouble = 1;
}
if(skillsarray.indexOf("Vengeance") != -1 && skillsarray.indexOf("Achilles'Heel") != -1) {
getDouble = 1;
}
if(skillsarray.indexOf("AqueousClone") != -1 && skillsarray.indexOf("MagicResistance") != -1) {
getDouble = 1;
}
if (getDouble == 1){
var node=trs[trs.length-1].cloneNode(true);
node.children[0].childNodes[1].childNodes[2].nodeValue = " !!! Get Double Skill !!!";
node.children[2].childNodes[1].children[0].attributes[0].nodeValue='';
node.children[2].childNodes[1].attributes[0].nodeValue = '';
node.children[2].childNodes[1].attributes[1].nodeValue = '';
//node.setAttribute("class","off");
trs[1].parentNode.insertBefore(node,trs[1]);
//node.setAttribute("class","off");
//trs[1].parentNode.appendChild(node);
}
}
/* Check for Invocator */
if(skillsarray.indexOf("Invocator") == -1) {
var avatarobj = document.getElementsByClassName("avatar");
var avatarMO = "" + avatarobj[0].onmouseover;
var dinozRace = avatarMO.substring(avatarMO.indexOf("")+4,avatarMO.indexOf("
"));
//alert(dinozRace);
var getInovator = 0;
var getAt = '';
switch(dinozRace)
{
case 'Moueffe':
if(skillsarray.indexOf("LavaFlow") != -1 && skillsarray.indexOf("DiamondFangs") != -1) {
getInovator = 1;
getAt = "Venerable's Lair (Lavapit) - Venerable";
}
break;
case 'Softpig':
if(skillsarray.indexOf("Fireball") != -1 && skillsarray.indexOf("FaroeHeritage") != -1) {
getInovator = 1;
getAt = 'Lavapit (Lavapit) - Soft Shaman';
}
break;
case 'Winks':
if(skillsarray.indexOf("MasterFisherman") != -1 && skillsarray.indexOf("Adrenaline") != -1) {
getInovator = 1;
getAt = 'Mutant Falls (Atlantean Islands) - Atlantean Huard';
}
break;
case 'Glidwings':
if(skillsarray.indexOf("Lightning") != -1 && skillsarray.indexOf("Elasticity") != -1) {
getInovator = 1;
getAt = 'Lavapit (Lavapit) - Elemental Master';
}
break;
case 'Castivorous':
if(skillsarray.indexOf("WildInstinct") != -1 && skillsarray.indexOf("VivaciousWind") != -1) {
getInovator = 1;
getAt = 'Market Place (Dinoland) - Isabella';
}
break;
case 'Rocky':
if(skillsarray.indexOf("ElementalFission") != -1 && skillsarray.indexOf("IncandescentAura") != -1) {
getInovator = 1;
getAt = "King's Citadel (Magnetic Steppes) - Rocky King";
}
break;
case 'Pteroz':
if(skillsarray.indexOf("BurningBreath") != -1 && skillsarray.indexOf("FetidBreath") != -1) {
getInovator = 1;
getAt = "University (Dinoland) - Professor Eugene";
}
break;
case 'Cloudoz':
if(skillsarray.indexOf(" LightningDance") != -1 && skillsarray.indexOf("VacuumDisk") != -1) {
getInovator = 1;
getAt = "Bruteforce (Dinoland) - Madam X";
}
break;
case 'Sirain':
if(skillsarray.indexOf("WithoutMercy") != -1 && skillsarray.indexOf("Vengeance") != -1) {
getInovator = 1;
getAt = "Dinotown Clinic (Dinoplaza) - Anna Tomie";
}
break;
case 'Hippoclamp':
if(skillsarray.indexOf("MartialArts") != -1 && skillsarray.indexOf("Concentration") != -1 && skillsarray.indexOf("Awakening") != -1) {
getInovator = 1;
getAt = "Mutant Falls (Atlantean Islands) - Master Hydragol";
}
break;
case 'Gorilloz':
if(skillsarray.indexOf("PrimalState") != -1 && skillsarray.indexOf("BurningHeart") != -1) {
getInovator = 1;
getAt = "Dinotown (Dinoland) - Michael The Guide";
}
break;
case 'Wanwan':
if(skillsarray.indexOf("Gathering") != -1 && skillsarray.indexOf("ForestKeeper") != -1) {
getInovator = 1;
getAt = "Blacksylva Door (Grumhel Forest) - Forest Warden";
}
break;
case 'Santaz':
if(skillsarray.indexOf("Tenacity") != -1 && skillsarray.indexOf("FetidBreath") != -1 && skillsarray.indexOf("TrickyHits") != -1) {
getInovator = 1;
getAt = "Klutz' Workshop (Atlantean Islands) - Klutz";
}
break;
case 'Feroz':
if((skillsarray.indexOf("BlowtorchPalm") != -1 || skillsarray.indexOf("Vigilance") != -1) && skillsarray.indexOf("FatalHit") != -1) {
getInovator = 1;
getAt = "Mr Bao Bob's House (Atlantean Islands) - Mr Bao Bob";
}
break;
case 'Kabuki':
if(skillsarray.indexOf("Awakening") != -1 && skillsarray.indexOf("Combustion") != -1) {
getInovator = 1;
getAt = "Totem Island (Atlantean Islands) - Yakuzi";
}
break;
case 'Mahamuti':
if(skillsarray.indexOf("Tornado") != -1 && skillsarray.indexOf("AcidBlood") != -1) {
getInovator = 1;
getAt = "Grandpa Joe's House (Dinoland) - Grandpa Joe";
}
break;
case 'Tofufu':
if(skillsarray.indexOf("Charisma") != -1 && skillsarray.indexOf("LightningDance") != -1) {
getInovator = 1;
getAt = "Bruteforce (Dinoland) - Master Zenith";
}
break;
case 'Etherwasp':
if(skillsarray.indexOf("PrecociousSpring") != -1 && skillsarray.indexOf("VivaciousWind") != -1) {
getInovator = 1;
getAt = "Observatory (Nimbao) - Sage Menthos";
}
break;
case 'Smog':
getInovator = 1;
getAt = 'Island Head (Nimbao) - Old Robot';
break;
}
if (getInovator == 1){
var node=trs[trs.length-1].cloneNode(true);
node.children[0].childNodes[1].childNodes[1].attributes[1].nodeValue = '/img/icons/elem_5.gif';
node.children[0].childNodes[1].childNodes[2].nodeValue = " !!! Get Invocator Skill !!!";
node.children[0].childNodes[1].attributes[1].nodeValue = "mt.js.Tip.show(this,'',null)";
node.children[1].childNodes[1].childNodes[0].nodeValue = 'S';
node.children[1].childNodes[1].attributes[1].nodeValue = "mt.js.Tip.show(this,'',null)";
node.children[2].childNodes[1].children[0].attributes[0].nodeValue='';
node.children[2].childNodes[1].attributes[0].nodeValue = '';
node.children[2].childNodes[1].attributes[1].nodeValue = '';
//node.setAttribute("class","off");
trs[1].parentNode.insertBefore(node,trs[1]);
}
}
}
/* Tournament opponent info */
var tournamentheader = document.getElementById("swf_title_BrutForce Tournament");
if(tournamentheader && tournamentheader.id) {
var tourframe = tournamentheader.parentNode.parentNode;
var divClear = document.createElement("div");
divClear.className = 'clear';
divClear.style.height = '10px';
var divskills = document.createElement("div");
divskills.className = 'right';
divskills.appendChild(tourframe.childNodes[5].childNodes[3].childNodes[5].cloneNode(true));
var dinolevel = divskills.childNodes[0].childNodes[3].innerHTML.slice(-2);
divskills.childNodes[0].removeChild(divskills.childNodes[0].childNodes[3]);
var skillslist = document.createElement("div");
skillslist.className = 'help';
skillslist.innerHTML = 'Details:
'
switch(dinolevel)
{
case ' 6': //HP Confirmed
skillslist.innerHTML += ' 100
Focus
'
break;
case ' 7': //HP Confirmed
skillslist.innerHTML += ' 100
Mistral
'
break;
case ' 8': //HP Confirmed
skillslist.innerHTML += ' 130
Focus
'
break;
case ' 9': //HP Confirmed
skillslist.innerHTML += ' 100
Focus
Perception
Water Cannon
Wrath
'
break;
case '10': //HP Confirmed
skillslist.innerHTML += ' 130
Burning Breath
Concentration
Perception
Water Cannon
Wrath
'
break;
case '11': //HP Confirmed
skillslist.innerHTML += ' 120
Focus
Korgon Reinforcements
Perception
Wrath
'
break;
case '12': //HP Confirmed
skillslist.innerHTML += ' 130
Cold Shower
Focus
Perception
Tricky Hits
Water Cannon
'
break;
case '13': //HP Confirmed
skillslist.innerHTML += ' 130
Focus
Water Cannon
Wrath
'
break;
case '14': //HP Confirmed
skillslist.innerHTML += ' 130
Focus
Mistral
Perception
Water Cannon
Wrath
'
break;
case '15': //HP Confirmed
skillslist.innerHTML += ' 150
Mistral
Korgon Reinforcement
Water Cannon
'
break;
case '16': //HP Confirmed
skillslist.innerHTML += ' 150
Korgon Reinforcement
Mistral
Water Cannon
Wrath
'
break;
case '17': //HP Confirmed
skillslist.innerHTML += ' 130
Burning Breath
Focus
Water Cannon
Wrath
'
break;
case '18':
skillslist.innerHTML += ' 150
Burning Breath
Fire Ball
Lava Flow
Waïkikidô
Water Cannon
Wrath
'
break;
case '19': //HP Confirmed
skillslist.innerHTML += ' 120
Korgon Reinforcement
Magic Resistance
Vines
Water Cannon
'
break;
case '20': //HP Confirmed
skillslist.innerHTML += ' 150
Korgon Reinforcement
Mistral
Vines
Water Cannon
'
break;
case '21': //HP Confirmed
skillslist.innerHTML += ' 100
Double Hit
Focus
Wrath
'
break;
case '22': //HP Confirmed
skillslist.innerHTML += ' 130
Double Hit
Flight
Focus
Mistral
Water Cannon
'
break;
case '23': //HP Confirmed
skillslist.innerHTML += ' 130
Blowtorch Palm
Burning Breath
Mistral
Vengeance
Wrath
'
break;
case '24': //HP Confirmed
skillslist.innerHTML += ' 120
Focus
Korgon Reinforcement
Primal State
Vines
Wrath
'
break;
case '25': //HP Confirmed
skillslist.innerHTML += ' 130
Double Hit
Flight
Focus
Mistral
Water Cannon
Wrath
'
break;
case '26': //HP Confirmed
skillslist.innerHTML += ' 150
Burning Breath
Fire Ball
Focus
Nap
Vengeance
Water Cannon
Wrath
'
break;
case '27': //HP Confirmed
skillslist.innerHTML += ' 150
Cold Shower
Fatal Hit
Focus
Gel
Marsh
Mistral
Tricky Hits
Water Cannon
Wrath
'
break;
case '28': //HP Confirmed
skillslist.innerHTML += ' 130
Burning Breath
Dodge
Flight
Focus
Mistral
Water Cannon
Wrath
'
break;
case '29': //HP Confirmed
skillslist.innerHTML += ' 130
Double Hit
Flight
Focus
Hermetic Aura
Lightning
Mistral
Water Cannon
Wrath
'
break;
case '30': //HP Confirmed
skillslist.innerHTML += ' 150
Cold Shower
Focus
Mistral
Perception
Water Cannon
Wrath
Tricky Hits
'
break;
case '31': //HP Confirmed
skillslist.innerHTML += ' 150
Burning Breath
Combustion
Fire Ball
Lava Flow
Mistral
Vengeance
Vines
Water Cannon
Wrath
'
break;
case '32': //HP Confirmed
skillslist.innerHTML += ' 130
Burning Breath
Combustion
Fire Ball
Lava Flow
Mistral
Nap
Vengeance
Vines
Water Cannon
Wrath
'
break;
case '33': //HP Confirmed
skillslist.innerHTML += ' 140
Dodge
Double Hit
Cold Shower
Flight
Focus
Gel
Mistral
Tornado
Tricky Hits
Water Cannon
'
break;
case '34': //HP Confirmed
skillslist.innerHTML += ' 150
Burning Breath
Cold Shower
Double Hit
Focus
Gel
Jump
Mistral
Vines
Water Cannon
Wrath
Tricky Hits
'
break;
case '35': //HP Confirmed
skillslist.innerHTML += ' 150
Cold Shower
Dodge
Focus
Korgon Reinfocement
Magic Resistance
Mistral
Precocious Spring
Primal State
Tricky Hits
Vines
Water Cannon
'
break;
case '36': //HP Confirmed
skillslist.innerHTML += ' 120
Blowtorch Palm
Burning Breath
Dodge
Flight
Focus
Jump
Korgon Reinforcement
Mistral
Water Cannon
Wrath
'
break;
case '37': //HP Confirmed
skillslist.innerHTML += ' 150
Double Hit
Flight
Focus
Hermetic Aura
Mistral
Saving Puree
Water Cannon
Wrath
'
break;
case '38': //HP Confirmed
skillslist.innerHTML += ' 150
Cold Shower
Double Hit
Focus
Gel
Korgon Reinfocement
Mistral
Tricky Hits
Vines
Water Cannon
Wrath
'
break;
case '39': //HP Confirmed
skillslist.innerHTML += ' 190
Blowtorch Palm
Combustion
Fire Ball
Focus
Korgon Reinforcement
Lava FlowMistral
Vengeance
Vines
Water Cannon
Wrath
'
break;
case '40':
skillslist.innerHTML += ' ???
Dodge
FocusGorriloz Spirit
Korgon Reinforcement
Precocious Spring
Primal State
Magic Resistance
Vines
Water Cannon
Wrath
'
break;
case '41': //HP Confirmed
skillslist.innerHTML += ' 170
Blowtorch Palm
Cold Shower
Combustion
Fire Ball
Focus
Lava Flow
Nap
Torch
Vengeance
Water Cannon
Wrath
'
break;
case '42': //HP Confirmed
skillslist.innerHTML += ' 170
Blowtorch Palm
Burning Breath
Combustion
Fire Ball
Focus
Jump
Nap
Perception
Self Control
Tricky Hits
Vengeance
Water Cannon
Wrath
'
break;
case '43': //HP Partially Confirmed
skillslist.innerHTML += ' ~180
Focus
Gorilloz Spirit
Korgon Reinforcement
Magic Resistance
Mistral
Precocious Spring
Primal State
Vines
Water Cannon
Wrath
'
break;
case '44':
skillslist.innerHTML += ' ???
Dodge
Flight
Focus
Hermetic Aura
Lightning
'
break;
case '45':
skillslist.innerHTML += ' ???
Cold Shower
Dodge
Double Hit
Flight
Focus
Mistral
Tornado
Tricky Hits
Water Cannon
Wrath
'
break;
}
divskills.appendChild(skillslist);
tourframe.childNodes[5].appendChild(divClear);
tourframe.childNodes[5].appendChild(divskills);
}
/* Mission info */
var missionheader = document.getElementById("swf_title_Mission:");
if(missionheader && missionheader.id) {
var missioncontrol = missionheader.parentNode.nextElementSibling;
}
if(missionheader && missionheader.id && missioncontrol.className == 'briefing') {
var missionframe = missionheader.parentNode.parentNode;
var missionscript = missionframe.childNodes[1].children[1].childNodes[0].data;
var rewardbox = document.createElement("p");
//rewardbox.className = 'story'
//var rewardbox = missionframe.childNodes[3].childNodes[9].nodeValue;
var mission = missionscript.substring(missionscript.indexOf(';sub=')+5, missionscript.indexOf('");',missionscript.indexOf(';sub=')));
var rewards = 'Rewards:';
switch(mission)
{
/* Grandpa Joe */
case "Fresh Fish":
rewards += '
- 20 ' +
'
';
break;
case "The Lost Dog":
rewards += '
- 15 ' +
'
' +
'-
';
break;
case "The Hills' Smashrooms":
rewards += '
- 30 ' +
'
' +
'- 500 ' +
'
';
break;
case "Wolf Hunting":
rewards +='
- 30 ' +
'
' +
'- 2000 ' +
'
';
break;
case "The Rose Bush in danger":
rewards += '
- 20 ' +
'
';
break;
case "The Recipe Book":
rewards += '
- 20 ' +
'
';
break;
case "The Stamps":
rewards += '
- 20 ' +
'
' +
'-
';
break;
case "The Confidential Letter":
rewards += '
- 20 ' +
'
';
break;
case "A Strange Monster":
rewards += '
- 30 ' +
'
' +
'- 500 ' +
'
';
break;
case "The Giants":
rewards += '
- 100 ' +
'
' +
'- 5000 ' +
'
';
break;
case "The Month Exploit":
rewards += '
- 200 ' +
'
' +
'- 8000 ' +
'
';
break;
/* Madam X */
case "The Black Briefcase":
rewards += '
- 10 ' +
'
' +
'- 300 ' +
'
';
break;
case "The Merchant Traitor":
rewards += '
- 
';
break;
case "Police Chase":
rewards += '
- 50 ' +
'
';
break;
case "Island it's Kool":
rewards += '
- 30 ' +
'
' +
'- 1000 ' +
'
'+
'
Needed for mission:
' +
'-
';
break;
case "The Ashpouk Conspiracy":
rewards += '
- 30 ' +
'
' +
'- 1000 ' +
'
';+
'
Needed for mission:
' +
'-
';
break;
/* Skully */
case "Prologue":
rewards += '
- 10 ' +
'
';
break;
case "On The Trail Of Moulder":
rewards += '
- 20 ' +
'
' +
'- 1000 ' +
'
';
break;
case "Miss Bao":
rewards += '
- 10 ' +
'
' +
'- 500 ' +
'
'+
'-
';
break;
case "The Annoying Tourists":
rewards += '
- 40 ' +
'
' +
'- 2000 ' +
'
';
break;
case "Napalm Shrimp":
rewards += '
- 30 ' +
'
' +
'- 5000 ' +
'
'
'
Needed for mission:
' +
'- 3 
' +
'- 5 
';
break;
case "The Reunion":
rewards += '
- 10 ' +
'
' +
'- 4000 ' +
'
' +
'- 
';
break;
/* Anna Tomie */
case "First Prescription":
rewards += '
- 10 ' +
'
' +
'
Needed for mission:
' +
'- 10
';
break;
case "Mushroom Medicine":
rewards += '
- 20 ' +
'
' +
'
Needed for mission:
' +
'- 5
';
break;
case "Bizarre Biotherapy":
rewards += '
- 30 ' +
'
' +
'- 500 ' +
'
';+
'
Needed for mission:
' +
'- 1
';
break;
case "Nasty Neighbours":
rewards += '
- 10 ' +
'
' +
'- 500 ' +
'
';
break;
case "Monster Invasion":
rewards += '
- 10 ' +
'
' +
'- 600 ' +
'
';
break;
case "First Aid":
rewards += '
- 20 ' +
'
' +
'- 500 ' +
'
';
break;
case "Curiosity Killed The Cat":
rewards += '
- 20 ' +
'
' +
'- 500 ' +
'
';
break;
/* Soft Shaman */
case "The Testing Ordeal":
rewards += '
- 20 ' +
'
';
break;
case "The Archelionscarer":
rewards += '
- 60 ' +
'
' +
'-
';
break;
case "Fire!":
rewards += '
- 40 ' +
'
' +
'- 2000 ' +
'
';
break;
case "The Crazy Barbecue":
rewards += '
- 40 ' +
'
' +
'-
';
break;
case "Quarrel":
rewards += '
- 30 ' +
'
' +
'- 1500 ' +
'
';
break;
case "Defend The Forges":
rewards += '
- 60 ' +
'
' +
'- 4000 ' +
'
' +
'-
';
break;
case "The Disappearing Package":
rewards += '
- 25 ' +
'
' +
'- 1000 ' +
'
' +
'-
';
break;
case "(Un)Fair Trade":
rewards += '
- 20 ' +
'
' +
'- 3500 ' +
'
';
break;
case "Ridiculous Ritual":
rewards += '
- 50 ' +
'
' +
'- 1500 ' +
'
' +
'-
';
break;
case "Hieroglyphics":
rewards += '
- 20 ' +
'
' +
'- 
'+
'Needed for mission:
' +
'-
';
break;
case "Carrier Pigeon":
rewards += '
- 100 ' +
'
' +
'- 5500 ' +
'
' +
'-
';
break;
/* Mr Bao Bob */
case "Birthday Gift":
rewards += '
- 30 ' +
'
';
break;
case "Barter in the Atlanteid Islands":
rewards += '
- 100 ' +
'
' +
'- 2000 ' +
'
';
break;
case "Kazkadine Hunt":
rewards += '
- 30 ' +
'
' +
'- 500 ' +
'
';
break;
case "Eeloz in Vinegar":
rewards += '
- 50 ' +
'
' +
'- 5000 ' +
'
';
break;
case "The Huge Hunt":
rewards += '
- 150 ' +
'
' +
'- 1500 ' +
'
';
break;
case "The Sardine Rally":
rewards += '
- 10 ' +
'
';
break;
case "The Fishes Rally":
rewards += '
- 20 ' +
'
';
break;
case "The Sharks Rally":
rewards += '
- 30 ' +
'
';
break;
case "The Whales Rally":
rewards += '
- 40 ' +
'
';
break;
case "The Dinoland Tour":
rewards += '
- 100 ' +
'
' +
'
-
';
break;
/* Nicolas Mulot */
case "The Perilous Road":
rewards += '
- 40 ' +
'
' +
'- 1500 ' +
'
';
break;
case "Allergies":
rewards += '
- 20 ' +
'
' +
'- 1500 ' +
'
';
break;
case "Cartography":
rewards += '
- 60 ' +
'
' +
'- 2500 ' +
'
';
break;
case "Remedy":
rewards += '
- 60 ' +
'
' +
'-
';
break;
case "Adventurer's Kit":
rewards += '
- 40 ' +
'
' +
'-
';
break;
/* Strange Prowler */
case "The Amnesiac Rice":
rewards += '
- 5000 ' +
'
' +
'- 
';
break;
case "The Dark Dinoz":
rewards += '
- 250 ' +
'
' +
'- 5000 ' +
'
';
break;
/* Elemental Master */
case "The Master's Shopping":
rewards += '
- 20 ' +
'
' +
'- 500 ' +
'
';
break;
case "Lesson 1 - Lightning":
rewards += '
- 30 ' +
'
' +
'- 1000 ' +
'
';
break;
case "Lesson 2 - Fire":
rewards += '
- 40 ' +
'
';
break;
case "Lesson 3 - Wood":
rewards += '
- 2000 ' +
'
' +
'Extra info:
' +
'You will need Devil Ointment
to cure the curse (costs 6000
)';
break;
case "Lesson 4 - Air":
rewards += '
- 10000 ' +
'
';
break;
case "Lesson 5 - Water":
rewards += '
- 20 ' +
'
' +
'Afterwards claim your reward from the master:
' +
'
OR ' +
'
OR ' +
'
OR ' +
'
OR ' +
'
';
break;
/* Dian Korgsey */
case "Like a Korgon To Water":
rewards += '
- 20 ' +
'
' +
'- ' +
'
';
break;
case "Northern Korgons, Southern Korgons":
rewards += '
- 40 ' +
'
' +
'- 2000 ' +
'
';
break;
case "Wood Steak":
rewards += '
- 40 ' +
'
' +
'- 2000 ' +
'
';
break;
case "Korgon Rivalry":
rewards += '
- 100 ' +
'
' +
'- 3500 ' +
'
' +
'-
';
break;
/* Forest Warden */
case "The Forest Warden":
rewards += '
- 110 ' +
'
' +
'- 3
';
break;
case "The Green Thumb":
rewards += '
- 30 ' +
'
' +
'-
';
break;
case "Right to cut":
rewards += '
- 40 ' +
'
' +
'- 3
';
break;
case "The King of the Jungle":
rewards += '
- 35 ' +
'
' +
'- 2500 ' +
'
' +
'-
';
break;
case "Make a Wish":
rewards += '
- 60 ' +
'
' +
'- 4
';
break;
case "A Jack For The Forest":
rewards += '
- 75 ' +
'
' +
'-
';
break;
case "Monkey money":
rewards += '
- 5 ' +
'
' +
'- 
' +
'- 
';
break;
/* Request Office */
case "Secure The Road":
rewards += '
- 70 ' +
'
' +
'- 1500 ' +
'
';
break;
case "Western Caravan":
rewards += '
- 100 ' +
'
' +
'- 3000 ' +
'
';
break;
case "Zest of Scorpwink":
rewards += '
- 80 ' +
'
' +
'- 2000 ' +
'
' +
'- 2 
';
break;
case "Secure The Crossroads":
rewards += '
- 80 ' +
'
' +
'- 3000 ' +
'
';
break;
case "The Greedy Thief":
rewards += '
- 80 ' +
'
' +
'- 2500 ' +
'
' +
'- 3 
';
break;
case "Dewormer":
rewards += '
- 100 ' +
'
' +
'- 2500 ' +
'
' +
'- 
';
break;
case "Wanted: Sahalami The Slicer":
rewards += '
- 80 ' +
'
' +
'- 2500 ' +
'
' +
'- 
';
break;
case "Wanted: Trip The Wimp":
rewards += '
- 90 ' +
'
' +
'- 3000 ' +
'
';
break;
case "Wanted: Boukanee The Immortal":
rewards += '
- 90 ' +
'
' +
'- 3500 ' +
'
';
break;
case "Wanted: Cervelah The Poisoner":
rewards += '
- 90 ' +
'
' +
'- 3500 ' +
'
' +
'- 2 
';
break;
case "A Mysterious Pendant":
rewards += '
- 90 ' +
'
';
break;
/* Al Zaimeur */
case "Al's Party":
rewards += '
- 80 ' +
'
' +
'- 3000 ' +
'
';
break;
case "Merguez or Nothing":
rewards += '
- 40 ' +
'
' +
'- 1000 ' +
'
';
break;
case "Al Cool":
rewards += '
- 40 ' +
'
' +
'- 1000 ' +
'
' +
'
Needed for mission:
' +
' - 3 Sharpened Flint 
' +
' -
';
break;
case "Licence To Party":
rewards += '
- 20 ' +
'
';
break;
case "Magnetic Excess":
rewards += '
- 100 ' +
'
' +
'- 1000 ' +
'
';
break;
/* Chen */
case "S.O.S":
rewards += '
- 80 ' +
'
';
break;
case "The Archdorogon's Tomb":
rewards += '
- 50 ' +
'
';
break;
case "Ingredients Hunt":
rewards += '
- 10000 ' +
'
' +
'- 
';
break;
case "Letter to the children":
rewards += '
- 50 ' +
'
' +
'- 2000 ' +
'
';
break;
case "On the stepes of Morgan":
rewards += '
- 60 ' +
'
' +
'- 1500 ' +
'
';
break;
/* Sgt Pepper */
case "Warrior Training":
rewards += '
- 40 ' +
'
';
break;
case "Mine Field":
rewards += '
- 50 ' +
'
';
break;
case "Mouktization":
rewards += '
- 3000 ' +
'
';
break;
case "Initiation":
rewards += '
-';
break;
case "The Capturer's Glove":
rewards += '
- 100 ' +
'
';
break;
}
rewardbox.innerHTML = '\n' + rewards;
missionframe.childNodes[3].insertBefore(rewardbox, missionframe.childNodes[3].childNodes[9]);
//missionframe.childNodes[3].childNodes[9].nodeValue = '\n ' + rewards;
}
/* Missing reward info */
var rewardheader = document.getElementById("swf_title_Mission Completed!");
if(rewardheader && rewardheader.id) {
var rewardframe = rewardheader.parentNode.parentNode;
var rewardscript = rewardframe.childNodes[3].childNodes[1].childNodes[0].data;
var rewardbox2 = document.createElement("p");
//rewardbox.className = 'story'
//var rewardbox = missionframe.childNodes[3].childNodes[9].nodeValue;
var missionreward = rewardscript.substring(rewardscript.indexOf('completed "')+11, rewardscript.indexOf('"!',rewardscript.indexOf('completed "')));
var rewards = '';
switch(missionreward)
{
/* Grandpa Joe */
case "the Lost Dog":
rewards += '
';
break;
case "The Stamps":
rewards += '
';
break;
/* Madam X */
case "The Merchant Traitor":
rewards += '

';
break;
/* Skully */
case "The Reunion":
rewards += '

';
break;
/* Anna Tomie */
/* Soft Shaman */
case "The Crazy Barbecue":
rewards += '
';
break;
case "Defend The Forges":
rewards += '
';
break;
case "The Disappearing Package":
rewards += '
';
break;
case "Ridiculous Ritual":
rewards += '
';
break;
case "Hieroglyphics":
rewards += '

';
break;
case "Carrier Pigeon":
rewards += '
';
break;
/* Mr Bao Bob */
case "The Dinoland Tour":
rewards += '
';
break;
/* Nicolas Mulot */
case "Remedy":
rewards += '
';
break;
/* Strange Prowler */
case "The Amnesiac Rice":
rewards += '

';
break;
/* Elemental Master */
case "Lesson 5 - Water":
rewards += '
Claim your reward from the master:
' +
'
OR ' +
'
OR ' +
'
OR ' +
'
OR ' +
'
';
break;
/* Dian Korgsey */
case "Korgon Rivalry":
rewards += '
';
break;
/* Forest Warden */
case "The Forest Warden":
rewards += '
3
';
break;
case "The Green Thumb":
rewards += '
';
break;
case "Right to cut":
rewards += '
3
';
break;
case "The King of the Jungle":
rewards += '
';
break;
case "Make a Wish":
rewards += '
4
';
break;
case "A jack for the forest":
rewards += '
';
break;
case "Monkey money":
rewards += '
- 
' +
'- 
';
break;
/* Request Office */
case "Zest of Scorpwink":
rewards += '
2 
';
break;
case "The Greedy Thief":
rewards += '
3 
';
break;
case "Dewormer":
rewards += '

';
break;
case "Wanted: Sahalami The Slicer":
rewards += '

';
break;
case "Wanted: Cervelah The Poisoner":
rewards += '
2 
';
break;
/* Al Zaimeur */
/* Chen */
case "Ingredients Hunt":
rewards += '

';
break;
/* Sgt Pepper */
case "The Capturer's Glove":
rewards += '

';
break;
}
rewardbox2.innerHTML = rewards;
rewardframe.childNodes[3].insertBefore(rewardbox2, rewardframe.childNodes[3].childNodes[9]);
}
/* Sticky swamp roadsign */
var stickyheader = document.getElementById("swf_map");
if(stickyheader && stickyheader.id) {
var stickycontrol = stickyheader.parentNode.children[2];
var mapframe = document.getElementById("menu");
}
if(stickyheader && stickyheader.id && (stickycontrol.innerHTML == 'Sticky Swamp' || stickycontrol.innerHTML == 'Mutant Falls' || stickycontrol.innerHTML == 'Coral Mines' || stickycontrol.innerHTML == 'Waïkiki Island' || stickycontrol.innerHTML == "Klutz' Workshop") && mapframe.id) {
var swampcontainer = document.createElement("div");
var swampheader = document.createElement("div");
swampheader.className="header";
swampcontainer.appendChild(swampheader);
var swampbox = document.createElement("div");
swampbox.className="bg";
//swampbox.className='mission help';
swampbox.style='cursor:default;';
var swampfooter = document.createElement("div");
swampfooter.className="footer";
var swamplist = document.createElement("ul");
var swampboxrow = document.createElement("p");
swampboxrow.style="font-variant:small-caps;font-weight:bold;font-size:9pt;color:#8e3e26;text-decoration:underline;";
swampboxrow.innerHTML = 'Swamp Roadsign:'
swamplist.appendChild(swampboxrow);
var curDate = new Date();
var curDay = curDate.getDay();
var weekday = new Array(8);
weekday[1] = "Monday";
weekday[2] = "Tuesday";
weekday[3] = "Wednesday";
weekday[4] = "Thursday";
weekday[5] = "Friday";
weekday[6] = "Saturday";
weekday[7]= "Sunday";
for(var i = 1; i < 8; i++) {
var swampboxrow = document.createElement("p");
if (curDay == i || (curDay == 0 && i == 7)) {
var style="font-variant:small-caps;font-weight:bold;font-size:9pt;background-color: #D19860;color:#fce3bc;margin:0px;"
}
else {
var style="font-variant:small-caps;font-weight:bold;font-size:9pt;color:#8e3e26;margin:0px;"
}
swampboxrow.style = style;
swampboxrow.innerHTML = weekday[i];
swamplist.appendChild(swampboxrow);
var swampboxrow = document.createElement("p");
swampboxrow.style=style;
if(i==1){ swampboxrow.innerHTML = '
'; }
if(i==2){ swampboxrow.innerHTML = '
'; }
if(i==3){ swampboxrow.innerHTML = '
'; }
if(i==4){ swampboxrow.innerHTML = '
'; }
if(i==5){ swampboxrow.innerHTML = '
'; }
if(i==6){ swampboxrow.innerHTML = '
'; }
if(i==7){ swampboxrow.innerHTML = '
'; }
swamplist.appendChild(swampboxrow);
}
swampfooter.appendChild(swamplist);
swampbox.appendChild(swampfooter);
swampcontainer.appendChild(swampbox);
mapframe.appendChild(swampcontainer);
}
/* Transfor old stone into ashpouk totem */
if(stickyheader && stickyheader.id && stickycontrol.innerHTML == 'The University'){
/* Old Stone in posession check */
if(centerContent.childNodes[1].childNodes[17].innerHTML.indexOf('Old Stone') > 0 ) {
var profaction = document.getElementById("act_dialog_prof");
if(profaction && profaction.id) {
var pnode=profaction.cloneNode(true);
pnode.id = "act_dialog_prof2";
pnode.children[0].children[0].children[1].childNodes[0].nodeValue = "\n Get Ashpouk Totem\n ";
var ptr = pnode.children[0].children[0];
var onclick = ptr.getAttribute("onClick");
var re = /\/(\d+)\/act\/dialog\/prof/.exec(onclick);
if(re){
dinoId = re[1];
userId = onclick.substr(-7,5);
ptr.setAttribute("onClick", "");
ptr.setAttribute("onMouseOver","mt.js.Tip.show(this,'',null)")
ptr.addEventListener("click", function(){
if(document.getElementById("tooltip")){
document.getElementById("tooltip").style.display = "none";
}
ptr.style.cursor = "wait";
var tds = ptr.getElementsByTagName("td");
for(var k = 0; k < tds.length; k++){
var td = tds[k];
td.style.cursor = "wait";
td.style.color = "#ffffff";
td.style.backgroundColor = "transparent";
}
var label = ptr.getElementsByClassName("label")[0];
label.innerHTML = "Clicked!" ;
var res = performAction(dinoId, 'act/dialog/prof?sk=' + userId, 'dino/' + dinoId);
label.innerHTML = "Professor Eugene";
res = performAction(dinoId, 'act/dialog/prof?goto=talk;sk=' + userId, 'dino/' + dinoId + '/act/dialog/prof');
label.innerHTML = "Ask A Question";
res = performAction(dinoId, 'act/dialog/prof?goto=question;sk=' + userId, 'dino/' + dinoId + '/act/dialog/prof');
label.innerHTML = "This Old Stone?";
res = performAction(dinoId, 'act/dialog/prof?goto=stone;sk=' + userId, 'dino/' + dinoId + '/act/dialog/prof');
label.innerHTML = "Of course, here it is.";
res = performAction(dinoId, 'act/dialog/prof?goto=stone_yes;sk=' + userId, 'dino/' + dinoId + '/act/dialog/prof');
res = performAction(dinoId, 'dialogCancel', 'dino/' + dinoId + '/');
document.location = '/dino/' + dinoId + '/setTab?t=map';
},
false
);
ptr.children[0].children[0].setAttribute("src","/img/icons/fx_totem.gif");
ptr.children[0].children[0].style = "width:25px;";
}
profaction.parentNode.appendChild(pnode);
}
}
}
function performAction(dinoId, action, referer){
var xmlhttp;
if(window.XMLHttpRequest){
xmlhttp = new XMLHttpRequest();
}
xmlhttp.open('GET','http://' + location.host + '/dino/' + dinoId + '/' + action, false);
xmlhttp.setRequestHeader('User-agent',window.navigator.userAgent);
xmlhttp.setRequestHeader('Accept','text/html,application/xhtml+xml,application/xml;');
xmlhttp.setRequestHeader('Referer','http://' + location.host + '/' + referer);
xmlhttp.setRequestHeader('Cookie',document.cookie);
xmlhttp.send();
return xmlhttp.responseText;
}