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

23
LINES

< > BotCompany Repo | #1002234 // Code generator (LIVE)

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

Libraryless. Click here for Pure Java version (1595L/11K/36K).

1  
!752
2  
3  
p{
4  
  makeBot("Code generator.");
5  
}
6  
7  
answer{
8  
  if (matchStart("make code *",s ,m)) {
9  
    S command = m.unq(0);
10  
    S encodedcmmnd = "";
11  
      command = command.replace("make code", "");
12  
      if(command == null){
13  
        ret null;
14  
      }
15  
      if(command.indexOf("newbot") != -1){
16  
        encodedcmmnd += "p{\n\tmakeBot('BOT NAME HERE');\n}\nanswer{\n\n}";
17  
      }else if(command.indexOf("if") != -1){
18  
        encodedcmmnd += "if{}";
19  
      }
20  
    //ntUpload(programID(), programID() + " generated code", encodedcmmnd);
21  
    ret encodedcmmnd;
22  
  }
23  
}

Author comment

Began life as a copy of #1002233

by @bgrgndz

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1002234
Snippet name: Code generator (LIVE)
Eternal ID of this version: #1002234/1
Text MD5: 036f476936ab9849110d835036ea9387
Transpilation MD5: 1a5d50d41f3163792c393ec3afd0093d
Author: stefan
Category:
Type: JavaX source code
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2015-12-30 21:19:02
Source code size: 573 bytes / 23 lines
Pitched / IR pitched: No / Yes
Views / Downloads: 543 / 586
Referenced in: [show references]