You are browsing as a guest. Sign up (or log in) to start making projects!

3h 11m 12s logged

more EngineLib work

Implemented several improvements to the scripting and entity systems.

changes

prefab caching

  • Added caching for prefabs to improve performance when repeatedly instantiating entities

Entity Access in Scripts

  • Added GetEntity, which returns the entity Object that the script is attached to.
  • Added support for the this keyword in ObSL scripts.

this is a wrapper around GetEntity() to provide direct access to the current entity

custom components

Added support for script-defined components:

  • entity.AddCustomComponent
  • entity.GetCustomComponent

This allows scripts to attach and retrieve custom data/components without requiring engine side component definitions

entity validation

Updated all entity object calls (such as GetComponent) to validate the entity before executing
(in both native bindings & engine source code)

Entity operations now check:
registry.isValid(id)
before accessing the entity.

This prevents errors caused by accessing deleted entities during scenarios such as scene unloading/loading cleanup

0
3

Comments 0

No comments yet. Be the first!