NuiLab / code-vr

🐍 Program and explore real applications with virtual reality! Learn how to program, compete to build apps, and even collaborate with other people in realtime, in game or not!
MIT License
146 stars 13 forks source link

Scene Graph and Actors #10

Open alaingalvan opened 7 years ago

alaingalvan commented 7 years ago

CodeVR's scene system is modeled after the design of most game engines, there's a scene with actors, each behaving independently and each communicating with the engine state.

Destruction

Actors can destroy themselves or actors around them by calling engine_state.scene.destroy(..), which requires that they pass a condition for an actor in the scene to be destroyed for.