Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tong/armory_electron_runtime
https://github.com/tong/armory_electron_runtime
armory armory3d debug electron runtime
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/tong/armory_electron_runtime
- Owner: tong
- Created: 2022-12-13T17:35:56.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2022-12-21T09:17:40.000Z (about 2 years ago)
- Last Synced: 2024-05-02T00:12:14.873Z (8 months ago)
- Topics: armory, armory3d, debug, electron, runtime
- Language: Haxe
- Homepage:
- Size: 82 KB
- Stars: 5
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# armory_electron_runtime
Electron based player and html5 debug runtime for armory.
## Build
```sh
git clone https://github.com/tong/armory_electron_runtime.git
cd armory_electron_runtime# Install haxelib dependencies
haxelib install build.hxml# Install application dependencies
cd app && npm install && cd ..# Install project dependencies
npm install# Build main process js
npm run build# linux|darwin|windows
npm run pack:linux
```## Usage
Set the custom launch command for the html5 player (change `os` and `arch` to your machine):
Use an absolute path to the executeable if it's not in your `PATH`.
```sh
export ARMORY_PLAY_HTML5='//armory-electron-runtime-linux-x64/armory-electron-runtime --devtools --window ${width}x${height} ${dir}/debug/html5/index.html'`
```If you want to have this permanently put it somewhere like `.zshrc` or `.bashrc`.
Start blender and `Play` the `Browser` target.
The (X) window class name is `armory-electron-runtime` if you want to apply some custom settings.
For accessing the electron api from haxe add [hxelectron](https://github.com/tong/hxelectron) to your khaconfig.js:
```sh
project.addLibrary('electron');
```### Logging
```sh
export ELECTRON_ENABLE_LOGGING=true
```Supported environment variables: https://www.electronjs.org/docs/latest/api/environment-variables
### Flags
- `--devtools` Open devtools when application starts
- `--window ${width}x${height}` Window width, heightSupported electron command line switches: https://www.electronjs.org/docs/latest/api/command-line-switches