Now that we've learned the basics of the entity system, it's time to create our first entity. For this exercise, we'll be demonstrating the ability to create an entity in Lua, C#, and finally C++.
Lua entities are fairly simple to set up, and revolve around two files: the entity definition, and the script itself. To create a new Lua entity, we'll first have to create the entity definition in order to tell the engine where the script is located:
<Entity Name="MyLuaEntity" Script="Scripts/Entities/Others/MyLuaEntity.lua" />
Simply save this file as
MyLuaEntity.ent in the
Game/Entities/ directory, and the engine will search for the script at
Now we can move ...