Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

30
LINES

< > BotCompany Repo | #1002952 // Simple Point Bot (UNUSED)

JavaX source code [tags: use-pretranspiled] - run with: x30.jar

Transpiled version (1654L) is out of date.

1  
!752
2  
3  
static BigInteger points;
4  
5  
p {
6  
  load("points");
7  
}
8  
9  
answer {
10  
  if (match("plus one", s) || match("good", s) || match("nice", s)
11  
    || match("nice one", s)
12  
    || match("gut", s) || match("jawohl", s)) {
13  
    plusPoint();
14  
    ret "OK";
15  
  }
16  
  
17  
  if (match("how many points you got", s)
18  
    || match("wie viele punkte", s))
19  
    ret str(points);
20  
}
21  
22  
static void plusPoint() {
23  
  points = points.add(bigint(1));
24  
  log("+1");
25  
  save("points");
26  
}
27  
28  
static void log(S s) {
29  
  print(s);
30  
}

download  show line numbers  debug dex  old transpilations   

Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1002952
Snippet name: Simple Point Bot (UNUSED)
Eternal ID of this version: #1002952/1
Text MD5: 71e564637a6d8908d3ec296c51faad3a
Author: stefan
Category: javax
Type: JavaX source code
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2016-04-10 18:38:58
Source code size: 510 bytes / 30 lines
Pitched / IR pitched: No / No
Views / Downloads: 451 / 490
Referenced in: [show references]