Jump to content
tdxev

treasure hunter (reteaua.emag.ro)

Recommended Posts

Posted

In cazul in care mai oragnizeaz? vreun concurs de "treasure hunter" (Stai treaz, cauta comori si castiga un iPad 2! @ eMAG Blog)

Deschide?i o consola JavaScript in pagina cu harta (reteaua.emag.ro/reteaua) copy/paste ap?sa?i RUN ?i a?tepta?i sa apar? comorile. Scriptul caut? si trimite codul secret automat.

JavaScript:


function attak()
{
$.ajax({
type: "POST",
url: "/show_treasure",
success: function(msg){
points = jQuery.parseJSON(msg);
$.each(points, function(index, value)
{
if(value.parola)
{
console.log("Send Password:" + value.parola );
saveCode(value.parola);
}
else
{
console.log("no password");
}
});
}
});
}

function checkTime(){
var currentTime = new Date();
var hours = currentTime.getHours();
var minutes = currentTime.getMinutes();
var seconds = currentTime.getSeconds();
console.log(minutes+ ":" + seconds);

if ((minutes in {0:'',15:'',37:'',45:''}) && (seconds in {5:'',45:''}))
{
console.log("Ataca!");
attak();
}


if ((minutes in {59:'',14:'',29:'',44:''}) && (seconds in {10:'',20:'',40:'',50:''}))
{
showMoreMarkers(map);
}

}


window.setInterval( "checkTime()", 1000);

PS. S-ar putea sa nu ave?i parte de primul premiu dar m?car men?iune ceva acolo tot lua?i. :)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...