Skip to content

nem0/lumixengine_js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

84 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JavaScript plugin for Lumix Engine.

  • Documentation
  • Attach scripts to entities
  • All properties automatically accessible
  • Console to execute scripts in global or entity's context, with autocomplete
  • Debugger support
  • Using Duktape

Example JS code:

function localFunction() {
	ImGui.Text("Hello world")
}

({
	name : "Test",
	entity : _entity,
	update : function() {
		this.name = "new name";
		this.entity.camera.fov = 1.2;
		ImGui.Begin("xoxo")
		ImGui.Text("foo " + this.name)
		localFunction();
		ImGui.End()
	}
})

image

VS Code debugger:

js.mp4

Autocomplete in console:

js_autocomplete