I am new to Armory3D I am playing around with tank_script and I can Build and Play on Browser very well to http://localhost:8040/build_tanks/debug/html5/ but when built and exported from the linux console $ node khafile.js I am getting this error.
let project = new Project(‘Tanks’);
^
ReferenceError: Project is not defined
at Object. (//khafile.js:2:15)
at Module._compile (internal/modules/cjs/loader.js:1015:30)
at Object.Module._extensions…js (internal/modules/cjs/loader.js:1035:10)
at Module.load (internal/modules/cjs/loader.js:879:32)
at Function.Module._load (internal/modules/cjs/loader.js:724:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12)
at internal/main/run_main_module.js:17:47
Any idea or a tip ?
I tried to publish the tank_script project on Windows 10 and Linux Mint (20) on the latest version (git) of the Armory engine and everything works, here is the console output:
__________ [Armory] Compiling __________
Exporting Scene
Warning: Box users Box.007 and Box.002 differ in modifier stack - use Make Single User - Object & Data for now
Warning: Wall users Wall.003 and Wall.001 differ in modifier stack - use Make Single User - Object & Data for now
Warning: Plane.001 users Tank2 and Tank1 differ in modifier stack - use Make Single User - Object & Data for now
Scene exported in 0.9420545101165771
Info: Publishing project, check console for details.
Finished in 16.1720027923584
Warning: 3 warnings occurred during compilation
Exported HTML5 package to
…\tanks_script\build_tanks\html5
What do you mean by new version?
To get a version from git, in which improvements are made almost every day, fixes need to update the SDK using Edit - Preferences - Add-ons - Render: Armory - Update SDK.
It was on this version that I checked.
I didn’t say New version… I said that I am new here!
More over the problem is not compiling nor exporting. It did fine!
The problem is running node in my terminal as explained
$node khafile.js
output
let project = new Project(‘Tanks’);
^
ReferenceError: Project is not defined
at Object. (//khafile.js:2:15)
at Module._compile (internal/modules/cjs/loader.js:1015:30)
at Object.Module._extensions…js (internal/modules/cjs/loader.js:1035:10)
at Module.load (internal/modules/cjs/loader.js:879:32)
at Function.Module._load (internal/modules/cjs/loader.js:724:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12)
at internal/main/run_main_module.js:17:47
Sorry, English is not my native language, I misunderstood you.
khafile.js allows you to configure a new project for Kha. Here is the documentation (https://github.com/Kode/Kha/wiki/khafile.js) for it, maybe it helps.
Armory allows you to create a new project simply in Blender.