Updated Components
OK, I’ve finished updating the components to get them ready with the editor and the serializer. I haven’t organized them, so I’ll just link the whole engine project:
http://www.innovativegames.net/upload/GameEngineTutorial/UpdatedComponents/ie.zip

hey i was just wondering what exactly you changed i dont see a lot of difference. I see some serialization stuff but what did you do to get it ready for the editor?
I cleaned up a few classes, fixed (hopefully) the various physics objects, changed many public members to properties (so some work can be done when they are changed and so they show up in the PropertyGrid), changed the material system quite a bit, and added serialization code. I think some services may have been modified as well. Some of the classes have also been changed to not crash the game when not all of their properties have been set yet. (ie: the heightmap texture hasn’t been set on the terrain yet, so it should not draw because it hasn’t generated vertices yet). I also changed Actor to use the ModelProcessor, which I haven’t posted the code for yet.
Sweet, Now I can snyc my version, I finished all that a couple of days ago, I want to see what you did better and I did better so I can learn more
Thanks
Hold on, I’m fixing a few things!
OK, it’s back up.
Wow That was one long learning experience, so many things to pick up, but good none the less.
[...] it’s based on the Innovation Engine source provided here, which is the latest available complete source; everything that’s in this source, is in [...]
I am receiving the following error with the updated components when trying to deserialize the file:
No parameterless constructor defined for this object.
It is referring to this line:
Component component = (Component)Activator.CreateInstance(t);
Any ideas?
Thanks for this… Your tutorial is very good…
However I’m having hard times finding Materials.cs (and its relatives) in the project you uploaded…
Where did they go? Did you remove them?
Also, it would be nice if you could post a class tree picture or something like that which lists all the classes/elements in your Engine, it would be really useful.
Thanks ^^
Eey Sean is it possible that the new version is a bit slower with loading new content ? In the previous version the shooting of new boxes was very quick. But now the game stops a bit when shooting a new box.
Do you have the same problem ?
P.S. Great tutorial
greetings
Did you purposely not add serialization code to SphereObject?
Here it is if you need it.
public SphereObject(float Radius, Vector3 Position, Vector3 Rotation)
: base()
{
InitializeBody();
SetupSkin(Radius);
this.Position = Position;
this.EulerRotation = Rotation;
}
// Sets up the object
void SetupSkin(float Radius)
{
CollisionSkin.RemoveAllPrimitives();
CollisionSkin.AddPrimitive(new Sphere(Vector3.Zero, Radius),
PhysicsMaterial);
}
Sorry copied wrong code without looking
here’s the sphere serialization code
public override void LoadFromSerializationData(SerializationData Data)
{
base.LoadFromSerializationData(Data);
this.Radius = Data.GetData(“SphereObject.Radius”);
}
public override void SaveSerializationData(SerializationData Data)
{
base.SaveSerializationData(Data);
Data.AddData(“SphereObject.Radius”, Radius);
}
I have to ask. What was your planning process in this? How did you retrofit the entire project for this? It just seems like a huge undertaking, And this would have taken weeks for me without your tutorial.
These are great tutorials Sean, thanks for putting in the time and effort.
Just adding a tip which I wish I knew when I was updating my solution to match your Updated one. I didn’t just copy and paste all the changed code,
I wanted to keep my own TestEnvironment project, but with the new IEModelProcessor the cubes I added to the scene didn’t have any textures. It turned out I had to change the Content Processor property of the models in the TestEnvironments Content project to use the “Inovation Engine Model Processor”.
A simple enough change, if you know where it is. Took me a while to figure it out though.