Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var line = new Array();
- line[1]="a1|b1|c1|d1|e1|f1|g1|h1=r|n|b|q|k|b|n|r";
- line[2]="a2|b2|c2|d2|e2|f2|g2|h2=p|p|p|p|p|p|p|p";
- line[3]="a3|b3|c3|d3|e3|f3|g3|h3=1|1|1|1|1|1|1|1";
- line[4]="a4|b4|c4|d4|e4|f4|g4|h4=1|1|1|1|1|1|1|1";
- line[5]="a5|b5|c5|d5|e5|f5|g5|h5=1|1|1|1|1|1|1|1";
- line[6]="a6|b6|c6|d6|e6|f6|g6|h6=1|1|1|1|1|1|1|1";
- line[7]="a7|b7|c7|d7|e7|f7|g7|h7=p|p|p|p|p|p|p|p";
- line[8]="a8|b8|c8|d8|e8|f8|g8|h8=r|n|b|q|k|b|n|r";
- var def = line;
- function onTextAfter(u,tx){
- var move = tx.split(" to ");
- t1=move[0].substring(1);
- if(line[t1].search(move[0])>-1){
- string = line[t1];
- m = string.substr(string.split(move[0])[0].length).split("|")[0];
- print(string.replace(m, "\x06"+m+"\x06").split("=")[0]+" will be replaced to 1 = empty");
- string = string.replace(m, 1).split("=")[0];
- line[t1]= string; // update
- print(line[t1].search(move[0])); // fail
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement