This first tutorial is a MUST TO READ. It deals with specific file and directory requirements for using the engine (HPL). Read it to save headache before starting to create models, maps and so forth.
When dealing with files and folders for the HPL directory there are a couple of important factors to know about. HPL does not care about directories! This means that if you place two files with the same name and extension at different locations, HPL will not be able to tell the difference and simply use the first one it finds.
Because of this it is very important to always give files unique names!
It seems odd? It's a choice made to allow moving files around and easing the locations of files when writing scripts and specific game files. This means that if you want to play a sound in the game you simply refer to the file name instead of having to refer to the exact path to the file.
HPL does not search all the directories on it's own, you have to tell HPL what directories there are for it to search. This is done with HPL Helper that edits the file ”resources.cfg”. To create a tutorial for this, lets use HPL helper to edit the “resources.cfg” file.
First go to the ”redist” directory and create a new folder called ”mystuff”. Launch HPL Helper and you should automatically be at the settings tab, this is the part of HPL Helper we want to use. Click ”Add” and locate your newly created directory and add it to the list. If done correctly you should now have a /mystuff at the bottom of the list.
Lets continue and add some more directories, first move the tutorial directory into the redist folder as well. We want to do this because it contains files we want to use for our tutorials. Using HPL Helper add the following directories:
tutorials tutorials/tutorial_1 tutorials/tutorial_2 tutorials/tutorial_3 tutorials/tutorial_4 tutorials/tutorial_5
Your resource directory list in HPL helper should now list these additional directories. When all is done press the “Save to File” button to save the settings. To see if you have done it right lets try and open a test model. Go to the ”Models” tab in HPL Helper and select browse. Navigate to tutorial_1 and select the ”tut_woodbox.dae” and test the view button. If all works correctly you should get a nice wooden box in the viewer and if you left click it you should be able to bounce it around.
That concludes the directory tutorial
Using HPL to create games requires about as much knowledge and time as using any other advanced game engine to create new content/mods. What differs HPL from the rest is that it does not use a specific map editor; rather it uses regular 3D editors. The only requirement is that the 3D editor supports the COLLADA format, http://collada.org. Following will be a kick-start on how to create a very basic model and to get it working in the game. Following that will be creating a level consisting of one room and making that room contain the model created. This tutorial will use pre-made textures; details for textures will come later.
To get started, search and locate a module/extension/library for your editor that gives it support for COLLADA. Install it properly and start your editor, make sure you are able to export and import collada files. It's important that you check the ”export polygons as triangles” option for exporting in collada.
First thing to do in your 3D editor is to make sure the units are set to equal 1 meter. The HPL-Engine uses the SI standard for all un