<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://www.renevo.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Engines</title><link>http://www.renevo.com/files/folders/engines/default.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>3D Real-Time Strategy</title><link>http://www.renevo.com/files/folders/engines/entry1638.aspx</link><pubDate>Fri, 07 Dec 2007 22:27:28 GMT</pubDate><guid isPermaLink="false">a8ef4eea-64fd-4ef8-98da-84783c31fc63:1638</guid><dc:creator>vloktboky</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;The 3D Raeal-Time Strategy engine is an accumulation of two months of research and development. It encorporates many techniques including an abstract rendering system, Lua scripting engine and entity management system, and the Intermediate Mode Graphical User Interface paradigm.&lt;/p&gt;
&lt;p&gt;The engine is capable of loading an exported level and run-time entity creation and manipulation, including Picking control and Quad-tree Scene Management. Below is an extract from the documentation that covers some of its key features:&lt;/p&gt;

&lt;p class="MsoNormal"&gt;There are three major aspects that this engine illustrates:&lt;/p&gt;

&lt;ol style="margin-top:0in;"&gt;
&lt;li class="MsoNormal"&gt;Entity
     Management system which operates through the Lua scripting language.&lt;span&gt;&amp;nbsp; &lt;/span&gt;All entity behavior is externalized in
     special scripts attached to an entity based on its class type.&lt;/li&gt;
&lt;li class="MsoNormal"&gt;Abstract
     rendering system with OpenGL and Direct3D 9 implementations.&lt;/li&gt;
&lt;li class="MsoNormal"&gt;Intermediate-Mode
     Graphical User Interface controls for HUD updating/rendering.&lt;/li&gt;
&lt;/ol&gt;

&lt;p class="MsoNormal"&gt;The entity manager works in conjunction with a class
definition table which is defined in a special Lua script.&lt;span&gt;&amp;nbsp; &lt;/span&gt;Entity classes are given a unique ID and
name, a type definition, and a behavior script.&lt;span&gt;&amp;nbsp;
&lt;/span&gt;The name and ID classify the entities and are used to create them.&lt;span&gt;&amp;nbsp; &lt;/span&gt;The type definition is used by the engine
when creating the C++ class object to represent the entity.&lt;span&gt;&amp;nbsp; &lt;/span&gt;No type means a basic CEntity object is used;
however, the type "Unit" means the CXUnit object is used.&lt;span&gt;&amp;nbsp; &lt;/span&gt;This is important as the class object
controls what member functions can be called on the entity in the scripts and
what special behavior runs internally.&lt;span&gt;&amp;nbsp; &lt;/span&gt;A
basic entity cannot be selected, but a "Unit"-typed entity can.&lt;span&gt;&amp;nbsp; &lt;/span&gt;The behavior script is also executed and a
clone of the entity script object (the table that shares the same name as the
class name) is connected to the entity.&lt;/p&gt;

&lt;p class="MsoNormal"&gt;When an entity is created, it is added to an internal
list.&lt;span&gt;&amp;nbsp; &lt;/span&gt;Special callbacks in the attached
entity's behavior script are called at certain intervals, allowing the entity
to externally initialize its behavior, update itself, and render special
controls to the HUD.&lt;span&gt;&amp;nbsp; &lt;/span&gt;Internal routines
such as the quad tree management and collision detection are handled by the
engine itself and are not apart of the behavior script.&lt;span&gt;&amp;nbsp; &lt;/span&gt;However, such logic as position changes, 3d
model representation, HUD information, and basic behavior are confined to the
script and are operated by special functions exported to the script.&lt;span&gt;&amp;nbsp; &lt;/span&gt;When the entity's C++ object is created, a
special class called a ScriptObject class is also created and maintained during
the entity's lifetime.&lt;span&gt;&amp;nbsp; &lt;/span&gt;This ScriptObject
class exposes special C++ functions and certain member variables of the entity
to its Lua script object and allows it to change its position or load a model
during runtime.&lt;span&gt;&amp;nbsp; &lt;/span&gt;For an example of this,
see the following C++ source files and Lua scripts: &lt;i&gt;CXUnit.cpp, CScriptObjectUnit.cpp, TestEntity.lua&lt;/i&gt;.&lt;/p&gt;

&lt;p class="MsoNormal"&gt;The abstract rendering system is written in such a way that
special concrete classes can be utilized for handling the physical rendering of
the scenes, loading texture data, and controlling the camera.&lt;span&gt;&amp;nbsp; &lt;/span&gt;OpenGL and Direct3D 9 concrete objects have
already been coded and utilized in the system.&lt;span&gt;&amp;nbsp;
&lt;/span&gt;The abstract classes declare simple functions to handle everything from
basic initialization and rendering processes to explicit sprite/line and texture
loading operations.&lt;span&gt;&amp;nbsp; &lt;/span&gt;The system also
utilizes 3d object loading routines and scene management systems that
incorporate a hierarchy of rendering nodes.&lt;span&gt;&amp;nbsp;
&lt;/span&gt;Such a list is constantly sorted for each scene in such a way that
hardware switches are minimized during the rendering process.&lt;span&gt;&amp;nbsp; &lt;/span&gt;Heavy use of instancing and frustum culling
is also utilized to cut down on resource usage and minimizing the cost of
collision detections and sending data to the graphics card.&lt;span&gt;&amp;nbsp; &lt;/span&gt;The scene manager also manages a quad tree that
splits up the terrain data and contains a list of entities used for such things
as picking logic.&lt;/p&gt;

&lt;p class="MsoNormal"&gt;Finally, the IMGUI paradigm is heavily used for rendering the HUD of the
game.&lt;span&gt;&amp;nbsp; &lt;/span&gt;Basic routines such as drawing
sprites, text, and lines are called from the HUD and entity scripts for
rendering the physical HUD.&lt;span&gt;&amp;nbsp; &lt;/span&gt;Everything
from the console system to the green box around selected entities and on-screen
text print out function from this very control.&lt;span&gt;&amp;nbsp;
&lt;/span&gt;The "Create Entity" button also works with this paradigm.&lt;span&gt;&amp;nbsp; &lt;/span&gt;There is no physical C++ widget object in
memory that represents this button.&lt;span&gt;&amp;nbsp; &lt;/span&gt;It
is instead contained entirely in the Lua engine and is merely just a table of
data that holds its dimensions, color, and current behavior with special Update
and Draw routines.&lt;span&gt;&amp;nbsp; &lt;/span&gt;A white box (1x1
white pixel texture) is drawn with an appropriate color and scale to achieve
the correct rectangular representation of the button and is drawn on the HUD
each time it is redrawn.&lt;span&gt;&amp;nbsp; &lt;/span&gt;Settle changes
are made to reflect if the button is currently hot, has focus, or has been clicked
based on its last update call.&lt;span&gt;&amp;nbsp; &lt;/span&gt;You can
see this for yourself in the following Lua scripts: &lt;i&gt;HUD.lua, HUD_Button.lua&lt;/i&gt;.&lt;/p&gt;</description><enclosure url="http://www.renevo.com/files/folders/1638/download.aspx" length="2726726" type="application/zip" /></item></channel></rss>