@@ -10,26 +10,6 @@ import * as Backend from './Backend.js'
1010import chalk from 'chalk'
1111import { createSpinner } from 'nanospinner'
1212
13- /*function Compile(){
14- const tokens = Tokenizer.tokenize(fs.readFileSync('./Delay.frw').toString())
15-
16- const ETree = ExecutionTree.generateETree(tokens)
17-
18- if(ETree instanceof Backend.Error){
19- console.log('\x1b[31m Error: ' + ETree.message + '\x1b[0m')
20-
21- return
22- }
23-
24- const compiled = Compiler.compile(ETree)
25-
26- if(compiled instanceof Backend.Error){
27- console.log('\x1b[31m Error: ' + compiled.message + '\x1b[0m')
28-
29- return
30- }
31- }*/
32-
3313function CompileFile ( source , path , endPath , config ) {
3414 //console.log('Compiling entity from ' + source + ' to ' + endPath + ' with ' + path)
3515
@@ -82,7 +62,7 @@ export async function Start(path, com){
8262 await ( sleep ( 100 ) )
8363 }
8464
85- // try{
65+ try {
8666 let mainfest = null
8767
8868 while ( ! mainfest || ! fs . existsSync ( com + '/development_behavior_packs/' + projectName + ' BP/entities/' ) ) {
@@ -171,9 +151,8 @@ export async function Start(path, com){
171151
172152 fs . writeFileSync ( com + '/development_behavior_packs/' + projectName + ' BP/manifest.json' , JSON . stringify ( mainfest , null , 2 ) )
173153 }
174- /*}catch (err){
175- console.log(chalk.hex('#ffc825').bold('Warning:'), 'Ignored error!')
176- console.log(err.toString())
177- }*/
154+ } catch ( err ) {
155+ console . log ( chalk . hex ( '#ffc825' ) . bold ( 'Warning:' ) + ' Ignored error: ' + err . toString ( ) )
156+ }
178157 }
179158}
0 commit comments