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

20
LINES

< > BotCompany Repo | #1001699 // Botifier (developing)

JavaX source code - run with: x30.jar

1  
// Botifier takes a program with an "answer" function and turns it into a bot.
2  
3  
!747
4  
5  
m {
6  
  static S botID = "#1001694";
7  
  static S botName = "Points Bot.";
8  
  
9  
  p {
10  
    L<S> tok = javaTok(loadSnippet(botID));
11  
    L<S> main = getMainProgram(tok);
12  
    tokAppend(main, "makeAndroid(" + quote(botName) + ");");
13  
    createTempProgram(join(tok), botName);
14  
  }
15  
  
16  
  // destroys the CNC structure but keeps the length intact
17  
  static void tokAppend(L<S> tok, S text) {
18  
    tok.set(tok.size()-1, tok.get(tok.size()-1) + text);
19  
  }
20  
}

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: #1001699
Snippet name: Botifier (developing)
Eternal ID of this version: #1001699/1
Text MD5: 8ee80df4d77157bc47b66d7d3e99351f
Author: stefan
Category: javax
Type: JavaX source code
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2015-11-05 16:22:20
Source code size: 543 bytes / 20 lines
Pitched / IR pitched: No / Yes
Views / Downloads: 451 / 421
Referenced in: [show references]