Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v1.0 - IEntity protocol #34

Closed
DougHamil opened this issue Sep 23, 2021 · 0 comments
Closed

v1.0 - IEntity protocol #34

DougHamil opened this issue Sep 23, 2021 · 0 comments
Assignees
Milestone

Comments

@DougHamil
Copy link
Owner

Replace the defcomponent macro with IEntity protocol.

The IEntity protocol allows users to register custom entities with threeagent. IEntity implementations will then be passed in to the threeagent.core/render function as a map, in the same manner as ISystem. This should provide a more consistent dev experience, and allows for more flexibility in defining new types of entities.

The protocol should have these methods:

  • create - creates an instance of this entity type, which should be a ThreeJS object
  • destroy - destroys an instance of this entity type
  • update - does an in-place update of an instance of this entity type, provided the original ThreeJS object and updated parameters

All built-in defcomponent should be replaced with this protocol.

@DougHamil DougHamil added this to the v1.0 milestone Sep 23, 2021
@DougHamil DougHamil self-assigned this Sep 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant