I just committed the v2.0 updates (as they stand so far) which has taken me the better part of a week to do. I still haven't touched the physics package. I was able to get the vector demo (Asteroids Evolved) running on Firefox, but not in Chrome. Tutorial 1 is also converted and running in Firefox. So, for the time being, v2.0 is very sick but is getting better all the time.
Everything is different. Yep, I introduced the "R" namespace, renamed some of the classes, renamed all of the components (removed "Component" from the end of the class name), moved some files around, and did other things to make my life very difficult. Trust me, it's taking a lot for me to get used to it. I've been working with this engine since 2008 and it's a huge change to do what I've done. I'm still making mistakes when I write class names.
Anyways, if you're curious you can look at the code in the v2.0 repo. There's still time that something might change, but I'm thinking that this is how the final layout will look.
Oh yeah, biggest change was the namespace but it also allowed me to change the Linker. Yep, now Linker is a very simple class which uses the predefined class dependencies to determine what needs to be loaded. It doesn't do any parsing or symbol table checking. It's a lot faster and it's a lot simpler. You can write your code in more ways than you used to be able to (however, I suggest keeping it clean).
Feedback is appreciated.
This is a great step, and it looks much better.
ReplyDeleteThis may look like a color of the bike shed discussion, but the concept of "HostObject" in TRE is not much different from what is called an "Entity" or "GameObject" in other component-based game engines (in js, TRE is the only I know that uses this approach). This could be added to the docs or, for the sake of familiarity, TRE could adopt these more common names.
Thanks. I'm glad you like the look of things, as it was a lot of work (with more to do, yet). Yeah, I've seen Entity and GameObject in other engines myself. I used to work with the Torque Game Engine, and that is where I got the idea. HostObject could probably become either of those, since it was originally named because it "hosts" the components.
ReplyDeleteAlthough, I might even argue that HostObject is more like Entity (a general component container) and Object2D is like GameObject. I wanted to, and still hope to, eventually have an Object3D.