Difference between revisions of "Team:Groningen/Coding"

Line 206: Line 206:
 
 
 
function advanceStage(prev){
 
function advanceStage(prev){
var idx = prev.idx,
+
var cur = stages[idx],
cur = stages[idx],
+
idx = (prev.idx + 1) % stages.length,
 
data = prev.data,
 
data = prev.data,
 
disp;
 
disp;
 
console.log(cur);
 
 
 
 
if(!cur){
 
if(!cur){
Line 235: Line 233:
 
elCur.innerHTML = stages[currentStage.idx].name;
 
elCur.innerHTML = stages[currentStage.idx].name;
 
elDesc.innerHTML = stages[currentStage.idx].description;
 
elDesc.innerHTML = stages[currentStage.idx].description;
 
currentStage.idx = (currentStage.idx + 1) % stages.length;
 
 
}
 
}
 
 
Line 243: Line 239:
 
}
 
}
 
 
elEnc.onkeyup = resetStage;
+
elEnc.oninput = elEnc.onkeyup = resetStage;
elKey.onkeyup = resetStage;
+
elKey.oninput = elKey.onkeyup = resetStage;
 
elStage.onclick = showStage;
 
elStage.onclick = showStage;
 
 

Revision as of 14:25, 26 August 2016

CryptoGE®M
Team
Project
Biology
Computing
Human Practice
Acknowledgements

SpyGEM coding

Encryption


Enter the message you want to secure here

Message

Key

Enter your secret key/password here


Plain text


Oop top