Our community blogs

  1. Josh
    Latest Entry

    By Josh,

    Distance fog is one of the most basic visual effects in 3D graphics, going back to the 1990s.  Here is the effect in the Quake 3 Arena map "Fatal Instinct", which was shrouded in a dense orange fog:


    Leadwerks Game Engine 2 had this available as a built-in effect, while the more flexible effects system of Leadwerks 3/4 had several Workshop shaders available to use, including one by Klepto and another one more recently added by myself.  However, this has not been part of the official SDK until version 4.4.  Why is that?

    The Problem
    When water is rendered in Leadwerks, a low-quality render is performed of the world with the camera scale inverted on the Y axis.  Because the reflection is distorted by ripples, we render to a lower-resolution buffer with all settings on low and effects disabled.  This is important because it gives a faster performance and image quality that is still acceptable.  The water plane also uses occlusion culling so that the extra pass is only rendered if part of the water plane is visible.  All post-processing effects are disabled in the reflection pass, which makes good sense, except in the case of fog.  If the world is shrouded in dense fog but the reflection in the water is clear, it creates an obvious problem.  In the screenshot below, a post-processing effect is applied to the world.  Although the water does have fog applied to it, the reflected image on the water does not have any fog, creating a stark problem, because post-processing effects are disabled in the reflection pass.


    Pre-Rendering Fog
    One option would have been to allow the user to mark some post effects as visible in reflection passes, but that seemed complicated and error-prone.  I came up with the idea build a simple fog calculation into the first ambient or directional lighting pass.  Here it is applied in the directional light pass:


    And here is what happens when the fog effect is applied in the directional light pass in the water reflection as well:


    We can modify the water shader itself to add the same fog calculation to the surface of the water.  Now our water matches the world.


    Removing Artifacts
    There was still more to do.  We are rendering fog first and other stuff later.  Anything rendered after the main lighting pass has to use the fog calculation to substract its effect from the scene.  For example SSAO will add shaded areas on top of fog, which we definitely don't want.  See the bridge and trees in the distance.


    The solution is to add the same fog calculation into the SSAO shader:

    	float fogeffect = 0.0f;
    	if (fogmode==true)
    		fogeffect = clamp( 1.0 - (fogrange.y - length(worldCoord - cameramatrix[3].xyz)) / (fogrange.y - fogrange.x) , 0.0, 1.0 );
    		if (fogeffect==1.0f)
    			fragData0 = outputcolor;

    And then use the fog level to lessen the impact of the effect:

    fragData0 = outputcolor * fogeffect + outputcolor * (sumao / float(passes)) * (1.0 - fogeffect);

    The underwater artifacts are a separate issue that were solved by adding another calculation.  Here is the result:


    The same fog calculation had to be added to all light shaders, light volumes, and probes, to make sure lights faded into the fog.  Other effects can make use of four new built-in uniforms which will provide all the fog information the shader needs:

    uniform bool fogmode;
    uniform vec2 fogrange;
    uniform vec4 fogcolor;
    uniform vec2 fogangle;

    On the client side, eight new commands have been added to the camera class to control the fog appearance, which are also available in Lua:

    virtual void SetFogColor(const float r, const float g, const float b, const float a);
    virtual void SetFogAngle(const float start, const float stop);
    virtual void SetFogRange(const float start, const float stop);
    virtual void SetFogMode(const bool mode);
    virtual Vec4 GetFogColor();
    virtual Vec2 GetFogAngle();
    virtual Vec2 GetFogRange();
    virtual bool GetFogMode();

    This was the solution I've had in mind for some time, but I haven't had a chance to implement it until now.  It works really well and provides robust fog that looks correct under a wide variety of settings.


  2. The easiest, but none the less effective, way to optimize a large outdoor scene is setting a view range for an entity. Here are some basic rules that I used during the rebuild of the Return to the Zone project.

    • Max: Here you can think of essential buildings and large structures. Think about distant buildings, powerlines, bridges and entities that stick out above the vegetation or water plane.
    • Far: Here we have the larger props: containers, trains, vehicles, walls, statues. This also contains props that are exposed in open areas. Think about road side props like stone piles, crates or oilddrums.
    • Medium: Props that are placed inside buildings can have either Medium or Near as a view range. When a building has several large indoor areas or contain a lot of windows and doors use the medium setting.
    • Near: Tiny props, like cans, toys, garbage and pretty much all props that are placed inside confined rooms.

    Also, a few static camera points showcasing the Zone:


  3. 0A7625F01AC8903577882B9E223032CF33CA6CFB

    Luawerks has been updated for Leadwerks 4.4, taking advantage of the new GUI system while adding new features and commands that allow you to develop your game better.


    Developer Console Refresh

    The Developer Console is the stable of the framework. Thanks to the GUI, you can now scroll through your history, highlight, and move the cursor around! Page through your history using the Page Up and Page Down keys! Having a console is vital for development as it allows developers to change maps and other values in-game instead of restarting the program after changing some code. You can add your own commands easily as well. For more information, see the page about the Console here.



    An Integrated Menu

    The standard release of Leadwerks 4.4 comes with a menu. I shipped my own standard menu with Luawerks to be more integrated with the rest of the framework. Unlike the official menu script, the Luawerks menu uses 2 GUI's; one for the main menu, and the other for the panels/windows. You can just edit the main menu without effecting the panels, and vise versa. Menu also calls the panels via console commands. 



    The Gotcha's Fixed

    Upon installing Luawerks into the project, I recommended that the user calls SetCamera() instead of Camera:Create(), so that the world class would know what camera to reference. This caused a problem when the user switched maps, so I also requested that the user releases the camera too. I replaced this with a for loop in the GetCamera() function, and calling camera:Release() isn't necessary.

    You can now load maps in-which their names have spaces! 


    Load Models as Copies

    I added a second parameter to the LoadModel() function. If set to true, the function will load a model, create and return a copy of the model, and release the original asset. This allows you to manipulate that model without effecting other references. This is great if you want one model to use multiple skins.

    This image shows two of the same models loading two different materials.



    Here is an example on how to create a copied/unique model:

    self.mymodel = LoadModel("Models/MyModel.mdl",true)


    LOD Models [Experimental]

    An experimental feature I've added is an object with multiple models and it switches the models based on the camera's distance from the entity. This only works on Static objects as I didn't calculate velocity and mass.

    You'd need to make it an object script like so:

    function Script:Start()
    	self.model = ModelLOD("Models/LodTest/main.mdl")
    function Script:UpdateWorld()

    As I said before, this was something I was playing with, and I don't think it's ready for full use yet. Although it'll help with poly counts, each ModelLOD needs to be updated to get the distance of the camera, so you'd need to weigh your costs.

    On top of all that, bug fixes were made, new commands were added, and more things are planned for future releases. Documentation will continue to be updated here.


    About Luawerks

    Luawerks is a Lua framework for video games developed on the Leadwerks Game Engine. It supplies developers with additional functions, handles the game loop and allows them to debug their code with a developers console. With all that out of the way, you can focus on making your game fun!

    You can purchase Luawerks from the Leadwerks Workshop Store for $9.99.

    For documentation and bug reporting, please visit the GitHub page.

  4. A new build is available on the beta branch.  I am putting it out tonight because I want to give you guys as much lead time as possible.

    I have not tested all hardware yet, and there were a lot of shader updates, so there could easily be a compile error on AMD or Intel cards.  Will test those out in the morning.

    New camera commands for fog:

    virtual void SetFogColor(const float r, const float g, const float b, const float a);
    virtual void SetFogAngle(const float start, const float stop);
    virtual void SetFogRange(const float start, const float stop);
    virtual void SetFogMode(const bool mode);
    virtual Vec4 GetFogColor();
    virtual Vec2 GetFogAngle();
    virtual Vec2 GetFogRange();
    virtual bool GetFogMode();

    This is scheduled to be released on the default branch this Tuesday.

    Also useful:


  5. In my other blog ( I talked about the component architecture I was using. I've since teamed up with Roland on this idea and together we have fleshed it out more. It's not 100% ready to be released yet but I realized that we've come a long way and that where we are today might seem confusing to someone if they weren't along for the ride. So I thought I'd use this blog to start down the journey we went on.

    The main goal for our journey was as follows:

    - Components will NEVER depend on other components. Decoupling as much as possible was priority #1. So the idea of events and actions(functions) is still at the core of the system. Now components need to work together obviously but the lowest level of dependencies the system has is via the arguments that events send along to actions. If you're hooking an action to an event you need to know what args that    event is sending you. This is primitive data vs classes and it's as decoupled as you can get while still allowing interactions between components.

    One day Josh asked about coroutines and if anyone knew anything about them. I've used coroutines in the past so I replied and did some examples (still need to finish that for him). Then one day on my way home from work it hit me. Since we have a common communication method in having actions (functions) being called from events we had a centralized place where all component actions (functions) were being called (the event class). This meant incorporating coroutines into our system was simple. Thanks to Roland for fleshing the idea out, all component actions are now coroutines automatically created (no work on the component creator's part). This was very exciting as it meant action functionality that required sequential coding could be done right in the action directly. This helped eliminate the need for most components needing an update() method that might not be doing anything except in certain situations. Situations that are now all handled in an action itself. It also meant a lot less state variables were needed to manage this sequential code. Roland had a doAddHealth() action where he instantly added the value passed in to the players health. This resulted in a snapping of the UI to the new health value. While that clearly works and you can do it that way, the test of our system was to make that health slowly increase to the final value over time, giving it a nice visual animation of increasing health. We were able to do it directly in that doAddHealth() function with about 2-3 more lines of code. It was insanely easy and much more logical in nature. Roland had never used coroutines before and he was able to get it working in a couple mins because it's just very logical and intuitive to work with when you don't have to deal with the details of the coroutine setup and management. You simple work with coroutine.yield() inside your action and that's all you really need to understand. This is an idea I'd like to see Josh think about with normal LE script functions as I think it can make life easier. Tim and I are working on a turn based game. Everything in the game is basically a sequence of actions over time so this idea of all actions are coroutines has been HUGE for our game. More on that at the end of Aug.

    Entity to Entity Communication!

    We fleshed out the entity to entity communication. My last blog talked about component communication with other components inside the same entity (the event system). This works great because all the components are inside the same entity and can access each others events and actions to hook up. But how can a component in entity A do something because a component in entity B wants it to, without those components knowing anything about each other? It was a challenge to get the right idea for this. We wanted to stay with the idea of events for this but we also didn't want entities to know about each other's internals.Decoupling of entities is important or else you end up with dependency hell and tigh coupling. We ended up with giving entities a SendMessage() function and an onReceiveMessage event. So from entity B we can hook up one of it's components events to the entity action SendMessage. The arguments for these required 2 special variables. Dest and Message. Dest is the entity to send the Message to. To get the Dest entity you're component is doing some kind of picking or GetNeighbors(). Dest can be 1 entity or a table of entities. On the receiving entity(s) the onReceiveMessage event is raised so that you can hook it's component actions to a received message. So all communication is done via the event system in some way.

    This introduced 2 needed features to our event system. When you get an event onReceiveMessage is raised no matter what event you got. However you'd only want certain events to trigger certain component actions. This requires some kind of routing of string messages to actions being called. We did this currently with a filter function on the event's subscribe() method. When the event is raised and a filter function exists it'll call the function passing in the arguments of the event and if the function returns true, raise call the action method. If false it wont call the action method. So generally what you do is pass a function that checks the args.Message for the value you want to call the action.

    self.onReceiveMessage:subscribe(self.healthComponent, self.healthComponent.doHurt, function(args)
            if args.Message == "hurt" then
                return true
            return false

    In the above event hookup when the Message is "hurt" then we hook it up to our healthComponent doHurt action. Because this is a very common thing to do, it can be bloated to have to define the function that does exactly this but for different string messages, you can just pass a string instead of a function to make it more streamlined:

    self.onReceiveMessage:subscribe(self.healthComponent, self.healthComponent.doHurt, "hurt")

    As you can see communication is NOT done inside the component. We didn't want components handling communication. We view component functionality and how that functionalty is communicated as 2 different types of coding. Communication is done inside the event hookups and functionality is done inside the component. Because of this and staying with the SendMessage/onReceiveMessage idea, we introduced another idea to the event subscribe() function. Another callback that is called before the action is fired. This also passes in the args and exists to let you modify the args before the action is called. This is used mostly when hooking a component event to SendMessage so that at that point you can give the string Message value. This way the component itself isn't concerning itself with the message which helps keep it more generic. This makes communication implementation specific to YOUR game and not the component. The component is just doing it's ONE job and raising events. That's it. What that means to your game is up to you to code. An example of this is:

    -- nil is the routing/filter function we talked about above which we don't need because we are sending out not receiving in
    self.inputComponent.onPicked:subscribe(self, self.SendMessage, nil, function(args)
            args.Message = "use"

    The inputComponent will raise an onPicked event when an entity is picked by left clicking. It doesn't care what you want to do with that. That's your part of coding your game and is game specific. It will fill in the args.Dest value with the entity but we need a place outside the component to specify what we want our message to be for our game. The supplied function does just that. It let's us create the Message variable on the args and fill it in. On the receiving side then it's up to us to hook up to that entities components when the message is "use" like above in the onReceiveMessage examples. This idea of 2 types of coding I think really helps create more separation and isolation of code which helps with maintainability and reusability. If components were to define the Message value inside then their influence starts to leak out as another component needs to be programmed to deal with that exact Message. We don't want that. We want the messages to be game specific and decided on by the user of the component system not the component creators. There is an alternative syntax to the above code where instead of a function you can specify a table. This table will be merged into the args parameter.

    self.inputComponent.onPicked:subscribe(self, self.SendMessage, nil, { Message = "use" })

    So to summarize entity communication, when sending messages the arguments callback function (or table that gets merged) is useful. When receiving messages the filter/routing callback function (or string message) is useful.

    Cool Side Effects!

    And interesting side effect to to the event system is that they are raised in the order they were subscribed to. You can use that to your advantage if you want to modify the args in any way between multiple components. Tim and I use this concept in our game. When we get a "hurt" message come into a character entity we first pass it through a Stats component which stores information about the player armor and other defenses. The args has a value property on it that is how much damage we should take, but by first running through our Stats component we can reduce that value by our armor. The 2nd component it's hooked up to is the health component which will reduce our health by the value property but now it's less because our Stats component reduced it. Since args is a table and tables are passed by reference the change to an args property in one component is visible to subsequent components.


    Having a common communication protocol between components and entities has been a big help in structuring my code for maintainability, adding new features, and reusability. One of the benefits of Lua is that table properties can be accessed via their string name. So something you might notice about event hookups to actions given knowing that Lua table properties can be accessed via string names, is that hooking up events is really just configuration. Even though the above examples is code that code can be made very generic where the property names are string values stored in a file. For example the above inputComponent hookup is the same as:

    self["inputComponent"]["onPicked"]:subscribe(self, self["SendMessage"], nil, { Message = "use" })

    Because it's a common structure all event hookups follow the same pattern. So imagine this information is coming from a json file and that json file is built from a visual editor. You would code your components in a code editor but hookup your components in a visual editor as you select the event source, event, action source and action from drop down menus. Thanks to Roland, we will have more to come on that in the next few months...


  6. So slowly I think I understand blender. I have created a few models by myself.

    Specifically, the clips the bullets and the RPG7

    The body is of fuse.  After Rigging in Mixamo i imported the FBX to blender and make some changes . Now I can use the RPG7 in the game.




    and dont forget to use the Modifier "Decimate" to use. So you can reduce the plycount!!













    • 2
    • 13
    • 2050

    Recent Entries

    Latest Entry

    Main post available here


    I first presented my PBR work about a year ago, since then I've been tweaking and making improvements.


    Over the past 6 months Leadwerks has had some great updates for graphics junkies like me tongue.png .The HDRi and environment probe features look great and have helped with 2 of the main issues with the last PBR system. Now what you see in the editor is what you get in the game, and HDR means proper tonemapping and a wider range of possible light intensities. Both of which are important for realistic PBR.


    I currently plan on using this for my current project, so expect consistent updates as I battle test it.

    The current build is available on github. Any issues and suggestions to help improve it are welcome.







    Limitations / improvements

    • Requires a gamma-correction post process shader. Not a huge issue, adding a pp is pretty easy but still something to remember.
    • Currently the built in environment probes are stored in a low dynamic range. This leads to clamping and precision errors as HDR values move towards extremes. this limits the usefulness of HDR. This is an engine issue.
    • Probes also use simple mipmapping for different roughness values, PBR often performs a convolution on stored cube-maps to better match reflection blurring due to roughness. A fix may be possible for this, but would require C++.




  7. Hi! It has been a while. Here's an update on my networking library EvayrNet which is available for C++ users of Leadwerks:


    While implementing it into the test project in Leadwerks, I saw that the use case had some flaws which made it really hard to debug what's going on. I figured that I should be spending some time on fixing some flaws. After a few weeks I came up with the following upgrades:

    1. Debugging class
    2. Simulation mode
    3. More debugging information available

    Here's some detailed explanation:


    Debugging class

    I was using a lot of "printf" before which made it hard to:

    • Find out where it's being called
    • Disable whenever I don't need it anymore

    This is when I decided to make a debugging class. I replaced the printf with a custom Print function which allows you to do the same as before - except you can disable any kind of printing whenever you want (like during release builds).


    I also realized that capturing data is a pretty cool feature to have, which makes it easier to visualize the data you want to debug. For that I created a SaveText function which accepts a string and a filename as arguments so you can separate data like "Pings per interval", "Bytes sent per second", etc.


    Here is an example what you can do with it:



    Simulation mode

    This is an interesting one that I just had to implement. A connection cannot always perfect, and it can be hard to always expect a good outcome (while you might not notice it because of your tests on localhost). This is why I introduced the manipulation of the following networking stats:

    1. Minimum latency (in ms)
    2. Random latency (in ms)
    3. Packet drop percentage
    4. Packet duplication percentage

    It's also very easy to activate and deactivate. All you have to do is NetworkManager::StartSimulation(...) and StopSimulation(). Here is it in the command line when you activate it:



    More debugging information available

    At last I added more ways to debug the network statistics to really see what is going on. Are you not receiving data anymore? Are you flooding the network? The following information is now ready to be displayed:

    • Newest ping (either to the server or from a specific client)
    • Average ping (this as well^)
    • Incoming amount of packets per second
    • Outgoing amount of packets per second
    • Packets per second lost
    • Incoming data per second (in bytes)
    • Outgoing data per second (in bytes)
    • Current active connections (primarily for the server)

    That's... quite a lot more than before! Previously you could only see if you're connected and if you're the server. I hope this information will make it easier for users to visualize traffic and debug any problems they might be having. And of course, you can mix this up with the debugging class to make cool graphs like above!


    Final words

    I'm still planning on making some extra information, like on specifics to see what kind of message is creating the amount of bytes send/received. This should help debugging even more. Other than that there are still some enhancements I'd like to put in such as encryption. These can be seen here.


    I hope you liked this blog post! Next time I will probably be showing how to implement EvayrNet into your C++ Leadwerks project, so you can toy around with it. wink.png

  8. Forest with different models using the vegetation tool:






  9. blog-0502497001488979347.png

    In an effort to further boost production values and the general quality of the cinematics in Enshrouded World I implemented facial animation for the characters and as the title suggests rather inelegantly.





    Below is one way of going about implementing facial animation but it's most likely not the best.




    - Sift through thousands of frames of mocap facial animation and export the model every five frames.

    - Load and release the vertex data of each of the hundreds of models needed for one cutscene to reduce RAM usage.

    - Set the positions of the vertices in the base face to the positions of the vertices in the next model (This requires interpolation and continues to the next model every 83 milliseconds).



    As you would expect the first step there was very tedious and despite my efforts there are still issues with the framerate whenever the facial animation is being rendered.

  10. I have made a small class for helping with reading and writing parameters between C++ and LUA and also calling LUA functions from C++. I'm sharing this little thing here.




    Using the class is quite simple as shown below


    LUA - part



    C++ - part



    I have included is a test project which looks like this in the editor



    And like this when executed



    Here is the LuaBridge class source




    And the complete test project


    Note: Its says 'Click for next test', should be 'Hit Spacebar for next test'

  11. It should be great if you can create a game world which has exact real-life object's dimensions. If you are using Blender to make game props for Leadwerks, these are some simple steps to help you archive the dimension match up.


    Step 1:

    - In Blender, go to Properties panel > Scene tab > Unit group

    - Choose "Meters" from list.

    - Make sure Length = Metric, Angle = Degree, Unit scale = 1


    Step 2:

    - This step is optional but can make you feel better with grid floor

    - In 3D View, Press N to open Properties region > Display group

    - Change Lines = 256, Scale = 0.1




    From now on, you can adjust object's dimensions parameters in Properties region to match real-life dimensions, it will be the dimensions when you import models into Leadwerks.


    Don't for get to Apply Transformation for object model, it is important. Do this before adjust object's dimensions. In blender Use Ctrl + A > Location / Rotation & Scale.




    Step 3: Fbx export

    - Menu File > Export > Fbx

    - Choose Version = FBX 7.4 binary

    - Scale = 0.01




    Step 4: Adjust exported model in Leadwerks Game Editor

    - Double click mdl file in Assets Explorer to open it in model editor.

    - Menu Tools > Collapse. This make sure model local rotation is correct.

    - Menu Files > Save.


    I attached my template .blend file below this post. It included a 1.7m height human model for better reference.

    • 2
    • 7
    • 429

    Recent Entries

    Latest Entry

    Ive decided to plan better and fix milestones so i can actually finish this game, the main problem is lack of time.But i have patience.


    I got a domain and in the process to setup a website and a blog.The plan is to have a small release every 15 days.

    Will see how it goes, it would be nice to work full time on this but not possible at this time, still have to go to work for a living.


    Currently im about to finish a somewhat starcraft like resource gathering mechanic.

    A mine has a 1 transporter that gather resources from asteroids.

    I limited to just 1 resource transporter per mine so that the user has incentive to expand (build mines) for more resources.


    Will come back with a movie.


    For development stuff i want to say Object::GetAddress method is great.

    Besides the debugger, really helped to investigate some strange crashes.





  12. blog-0568459001486305707.jpg

    One More Day - Performance Updates


    So it’s been a while since my last blog update on One More Day but recently I had a look to see if I could do anything with improving the performance of the game. As it turns out there were still some optimisations to be made that have helped boost performance.


    V0.1.6 on the Game Launcher


    Here are the main performance related changes I’ve made which were recently published to the Game Launcher:

    1. I changed some of the furniture models to lower poly versions. Some of these models were about 3000polys and are now replaced with lower poly versions with no real visual difference in-game. So about 10 or so models that were repeated more than once around the level were shaved in poly detail by about a third.
    2. I halved the draw distance on camera range and increased the fog a bit to compensate. I believe this helped more for when you are some distance outside the town but less so when you are in the town.
    3. I removed some rogue geometry in the map (wasn’t much), and also a few objects that weren’t really needed.
    4. I went back over every object to ensure it’s viewing range was as minimal as I could afford without creating too much pop-up. This is something I have always done but still sometimes you end up missing a few things.
    5. I spaced out some detailed areas on the map (ie. the power station got moved out further) to try to reduce the number of objects being shown at any one time.
    6. I made sure physics shapes set in model viewer were as simple as possible and removed collision from some small objects.
    7. I removed some workshop objects that had very big textures.


    All these changes stacked on to the latest version of Leadwerks which also includes performance improvements have given a noticeable performance improvement to the game.


    One thing I had to add in (sparingly) was some grass using the vegetation system as I felt it added nice detail to the level and was worth a small performance hit. That’s what makes optimising the game hard, trying to balance between good visuals, content and good performance. Unfortunately sometimes sacrifices have to be made. But even with the grass added the new version is running better than before. I would like to add volumetric spot lights for light coming in the windows but for now I resist that temptation as they would add up to a significant performance hit. Maybe I will add them as a high graphics option in the future.


    Other Improvements


    As well as performance improvements the game download size is now smaller thanks to the newly added ogg support and also removal of some unused files that were being published. One thing I noticed when publishing a game in Leadwerks is that if you have files with the same filename in two different folders both files will be packaged even if only one of them is used. So there were some unneeded texture files etc. being packaged from unused workshop content. Going forward I will have to keep an eye out for duplicate filenames.


    More performance in the works


    The following changes are in my current dev build which hasn’t been released yet but are showing even more performance increases:


    1. Converted the CSG houses and bungalows to models. Simplifying and reducing object/entity count. This should allow me to add more houses to the map with less of a performance impact.
    2. Further reduced the camera range and increased the fog to compensate. This allows me to reduce the view range on many bigger outdoor objects and buildings from Max to Far whilst minimizing popup and also reduce the vegetation view range. This will result in a much more foggy look to the game (see screenshot) which will create a slightly different atmosphere than previous versions and with less viewing distance it might make approaching zombies a bit more dangerous.
    3. I identified SSAO was making quite a performance impact so I have disabled this for now and might re-introduce it as a high graphics option when I get around to creating an options menu. For outdoor map SSAO is probably not as important or worth the hit but it is nice to have when inside the buildings.


    After all these performance improvements and v1.7 is released I am optimistic that most people should get at least a 30fps game experience with OMD. Fingers crossed!

  13. After going radio silent for a week I return with some really, really good news.


    First and foremost, the last level of the first episode is finished, I'm currently testing it out and seeing if I can break it before I upload a beta build to steam. After a couple days of it being there, if there aren't any issues, I will be launching the game on february 10th. Yes, you can quote me on that.



    I have to tell you though, making this level was not easy at all, I had so many ideas that never saw the light of day, but I hope that the way I created things work out for the better and I hope to use those scrapped ideas in the future someway.


    So here's a bit of information for the last level for those of you who've been wanting to play it:


    There's a way to kill the demon.

    There's a way to escape without killing him.

    The last level has 5 different variations depending on what you do.



    It goes without saying that there are multiple endings for what happens when you finish the last level as well, but I'll leave that for you to find out.





    That's it for now! I've probably already said too much so I hope you'll like what's in store for you.

  14. It's finally done!


    You can find it here on the workshop:


    And now i'm going to share a bit about the progress of the last few weeks, stick around if you like :)


    I'm so glad i made it in time, there were still a few "optional" things i would've loved to add (like a final boss wave) but due some in real complications (losing my phone..) and overal internship time consumption i still managed to get quite a game here!


    I am pretty proud of it too, might sound silly for such small game but it's my second game that i marked as "complete"! Also special thanks to my wife for creating all the model textures & GUI textures!


    For both me and my wife it was the first time we actual worked with 3D models (creating them from scratch and texturing them from scratch) this was quite a cool experience, i'm really glad with the results

    and i got more experienced in the tools i can use to make things look nice without too much complications.


    I personally think the cartoon-ish style was a great start for the modeling / texturing matter as this are my first proper game models that i build from scratch like mentioned above. I did have a small glimpse and trying to add bones, but i personally left it aside for now as i didn't really need them and i wanted to invest my time more in the game to reach the finish line.


    Overal in general, the progression went smooth (sometimes a stupid mistake like uppercase instead of lowercase.. You know the deal hehe), this was also my first time actual creating a wave system which i enjoyed a lot! I must say, tweaking & balancing each wave was harder then i honestly expected at first but i think i found quite a balance :)


    I don't really know what more to add haha, perhaps writting this after a day programming session wasn't the best idea.


    Thanks for reading and i hope you guys enjoy the game as much as i did creating it!

    • 2
    • 8
    • 91

    Recent Entries

    In my day job I get a lot of experience with different technologies. Mostly related to mobile or website, but there is a lot of bleed over in the game industry. I've done a few Ruby on Rails applications, it's not my primary toolbox, but it has some benefits. Mostly the ease and speed of development.


    I switched to using Ruby on Rails for the data management layer of my game. At the moment there isn't much data, only about 300 rows in a database for everything in the game. This is expected to more than triple within the next few months as I add achievements, more items, 7 new quests, and shops!


    Eventually this will go extremely large and hard coding all that data will become very error prone and next to impossible to manage.


    Ruby on Rails has the ability to have command line tasks which can be used to generate data.


    Sample task:

    namespace :codegen do
    task :achievement_types => :environment do
     erb ='lib/tasks/codegen/achievement_types.erb'))
     params = binding
     params.local_variable_set(:achievementTypes, AchievementType.all)
     data = erb.result(params)
     f ='codegen/AchievementType.h', 'w')


    What this code does is it loads an ERB file which is a templating file for Ruby.

    Queries the database for all AchievementType objects,

    Then creates a local binding scope for the template,

    Renders the template to a string

    Presto, Generated C++.


    Erb file in question:

    <% achievementTypes.each do |at| %>
    #define <%= at.macroname %> <%= %>
    <% end %>


    Code generated:



    The use case above is fairly simple, but more complex situations can occur, such as Npc Conversations. Currently my NpcConversation_Gen.h file is 500 lines long. with lists of data similar to this:


    new NpcConversation(34, 0, "69488b5b-cfd1-4255-bd74-a6b7eeb0e939",
     new NpcConversationAction(27, "AddInventoryItem", 39, 1),
     new NpcConversationAction(28, "CompleteMilestone", 3, 15),
     new NpcConversationConditional(12, "StartedQuest", 3, 0),
     new NpcConversationConditional(13, "HasItem", 57, 10),


    Maintaining that code by hand would triple the amount of time to create quests.


    So if your game uses a large amount of data, I really recommend using a web framework (Ruby on Rails, Codeigniter, Cakephp, Revel, Django, Spring, ect) to manage all your game data!

  15. blog-0813764001483675955.png

    I've finished the main concept of my game "Ball Hopper", which you can play at


    It was inspired by CS:GO surfing and the Impossible Game and your goal is to reach the checkpoints and get to the end. Checkpoints, for a lack of a better word aren't what you'd expect of them. They're really just points that you need to touch to be able to finish the level. Some level end points are right at the start, so would be a bit silly if you could just get to the finish and win, so that's what those are for. You don't actually respawn at those points.


    This blog post is mainly to gather feedback before the end of the tournament, so let me know if you have any suggestions.

  16. Hey!


    More stuff will come in the next version, my objective is to improve the Prologue to use as a demo for a Greenlight campaign to the next chapter. Much of the work this week (besides fixing stuff) was to detail the scenes a bit more to help you guys understand the water flood and how deep the water is.


    I removed the cars of the starting area, because floating cars in that place makes no sense.



    You can now even see the noisy bird (what a time to be alive!)


    The water in the game is really deep, the buildings you see in the game are the rooftops and the facility that you start the game barely survived to the cataclysm.


    Some additional rooms were planned for prologue but they were left out, I'll add them in the new version! So if you have already played the prologue you will have some surprises in the Uncut version.



  17. Ludum Dare 37 starts in 12 hours (as I type this)



    Most of you probably know (I think), but Ludum Dare is a game dev competition where you have to complete a game in 48 hours from scratch (no externals assets I think).


    The JAM portion of the event is a bit more relaxed and gives you 72 hours (if my memory serves me right - I really should check the rules) You can use external assets (I think - again I should have checked the rules before posting this right smile.png ).


    In the past I have sometimes participated unofficially and used it as a focus point to force myself to try to do a game in very tight timescale and so be forced to jettison most of the fluff you waste your time with normally.


    I think I might give the JAM (not the DARE) a go this year but probably just unofficially for my own benefit. Don't necessarily plan to submit anything as currently I already know I will have limited time over this weekend so it just might not happen. I suppose one outcome could be that I come up with the start of a small game I can enter into the Leadwerks Winter Tournament in just 2 days and can then either choose to submit that or continue on with my main idea.


    It can be a useful event to try out something that you've never got round to before in a bit of software (e.g. Leadwerks) and to refine your workflow.


    Sometimes there are also offers on software around this time which area usually highlighted on the site though I can't see any information on it at this time


    As I type this the theme is currently accepting voting still.


    Having a theme helps focus your mind but also think of things that might be outside your preferred area (space zombies etc.)


    If anyone decides to enter, officially or unofficially then good luck.

  18. Draws a box from one vector to another.

    To be used as some kind of arrow.


    Need feedback if its a better way to do this, but so far seem to be ok for my purposes.


    Example usage:

    ArrowUi *t = new ArrowUi(Vec3(0.0, 0.0, 0.0), testshadow->GetModel()->GetPosition());


    class ArrowUi {
        Model *model;
        Entity *pivot;
        Vec3 from;
        Vec3 to;
        float distance;
        ArrowUi(Vec3 from, Vec3 to);
        void From(Vec3 from);
        void To(Vec3 to);
        void Draw();
    ArrowUi::ArrowUi() {
       model = NULL;
       surface = NULL;
       pivot = NULL;
       from = NULL;
       to = NULL;
    ArrowUi::ArrowUi(Vec3 from, Vec3 to) {
       this->from = from;
       this->to = to;
    void ArrowUi::From(Vec3 from) {
       this->from = from;
    void ArrowUi::To(Vec3 to) {
       this->to = to;
    void ArrowUi::Draw() {
       pivot = Pivot::Create();
       pivot->SetPosition(from, true);
       distance = from.DistanceToPoint(to);
       model = Model::Box(0.05, 0.05, distance, pivot);
       model->Move(0, 0, distance/2);
       pivot->AlignToVector(to - from, 0);
       pivot->AlignToVector(to - from, 1);
       pivot->AlignToVector(to - from, 2);

  19. blog-0128326001476525058.jpg

    TinyGom Racing PC Game is available !


    New demo : at: (register)


    or if you have an account on :


    lot of bugs corrected:

    • menu appearance now conform to what it should be
    • all sub-menus revisited
    • in game cosmetics adjustments
    • time trial mode now fully fonctionnal
    • screen resolution detection improved and working with multi monitors
    • no more bugs at the first launch of the demo

    SDMG-STUDIO production presents

    the fruit of my very long work,my completed game : TinyGom Racing


    Why 'TinyGom' ?

    because there are small tires... rolling !


    What is TinyGom Racing ?

    It is a solo PC game about driving remote control vehicles around levels in different environments.

    3 Game modes : Quick Race, Time Trial, Championship

    3 environments : School, Mall, Warehouse

    6 levels , 6 different rc vehicles with one mystery car (more levels and cars to come...)





    All races will be different because of the random placement at start, Music and AI racing are changing randomly too.

    Passing through the semi-transparent "red gates" you will progress along the level and finally loop a lap.

    When a bonus is available, going through it will give you three ping-pong balls to throw at opponents, wisely.




    Car abilities:

    Accelerate (!)

    direction left/right (good start, no ?)



    Flip car (in case of upside down)

    Replace car, Levels have saveposition tags, a "savepos message" will pop up when done.(see each mode for detail)

    Shooting balls (bonus gives you 3 balls to throw at opponents)

    Looking at 180° view right or left side of your car

    Position camera view from the rear of your car zooming + or -

    Pitch camera view angle from the rear (all positions of the camera are recorded and restored at start)




    Game Modes:

    Quick Race mode : you just race for fun, 5 opponents and clock ticking though, level lap record to beat too,

    you can choose the number of laps to run before racing.Simple ranking will show at the end of the race.

    Replacing the car in this mode will replace your car at the last "saveposition" recorded, from 3 to 9 savepositions spots are placed according to each level.

    In this mode you can also looking for the mystery car parts scattered around all levels by the naughty clown.

    With all the parts gathered you will unlock the mystery car and then be able to drive around with it.




    Time Trial mode : you will fight the clock and yourself with the ghost of your best lap running with you.

    If you beat the best ghost time, your lap will be recorded and you will racing against it then.

    At start in a new session you can choose to load the best ghost file so you will fight against it or

    if not, recording a new ghost as you drive and to race against it after the first lap, all over the session trying to improve it.

    If you ever beat the best ghost time (recorded in file and loaded in memory), you will then establish the new reference ghost record for future sessions.

    The game is, for now, solo but you can already exchange the ghost record files of your own with others players

    who have the game and then race against them through their ghost file.

    This is a fun part of this challenge.

    Replacing the car will replace you at the starting position of the level and restarting the clock.(no "saveposition" works in this mode)




    Championship mode : is based on the player name you enter (or leaving to "none")

    so you can leave the championship after a race in a level, quit the game and resume the championship later using the same name of player.

    Helping you by hitting the "restore last session" option in the main menu to retrieve your last session and resume the championship where you leave it.

    Replacing the car will replace your car at the last "saveposition" recorded, from 3 to 9 savepositions spots are placed according to each level.

    You will need to race 5 laps on each level to complete the Championship.

    You wont be able to redo a specific race before completing Championship, you will need to restart a Championship to do that.

    Points are distributed according to the finish positions of each level race : 100 for position 1, 80 to 2, 60 to 3, 40 to 4, 30 to 5, 20 to 6, 10 to 7 and 0 to position 8 (last one)

    Ranking is made after finishing a race level.

    Podium with global ranking will close the Championship at the end of the last race. Congrats if you are on the first step !


    Various objects, sometimes, will be throwing at you and the others along the levels slowing your race, putting little spice in your meal...

    Some objects are movable but a lot don't, you'll see.

    Mystery Car parts are seldom hidden from the direct view, you will need to rub the walls with your vehicle to discover the part-item then.


    Supported devices:

    mouse (menu)

    standard keyboard

    joypad X360 microsoft® controller

    Supported OS:

    Windows 7, 8, 8.1, 10


    Is the game ready ?

    yes :

    or here:


    Demo ?

    yes :








    This project was seriously started several (more than 5) years ago, after toying with Leadwerks engine for a while,

    decided to find the "make a game(mine)" function and finally found it works !

    I have counted 13419 lines of lua code, sweating on some...not counted the polys though !


    Thankful to Leadwerks Engine for enduring all my trials and errors and to restitute fluidly the render from my ideas.

    I need to give credits to a lot of people here : first to my wife Pascale, for her patience and her presence

    second my son and my daughter who always encouraged me to progress at it.


    And for all technical parts, in not particular order (sorry for those i forget to mention) : Josh Klint for the Leadwerks Software Engine.

    Forum People : MackleBee, Rick, Marley's Ghost, Tyler_H, Aggror, Gordonramp, Pixel_perfect, Shadmar...

    All these folks helped me directly or not, special mentions to MackleBee giving always good advices and good code examples,

    Rick for coding the joystick.dll (without it, i would never be here) and to Marley's ghost who gave me a great piece of code base of my main mecanics.

    Finally thanks to the great Leadwerks community, where i found so much usefull posts.


    Started from nothing, bought one Pure3D starting pack, grabbing most textures from others from my camera.

    Made all 3D models by myself, modeling,uvmapping,texturing and converting to gmf.

    Software used: Hexagon, Photoshop, 3DCoat, UU3D, Audacity, Leadwerks converting tools.


    I get a regular job so i have spent most of my spare time at my game.

    I started with Leadwerks 2.5 and stand with it because scene files (sbx) and all scripts in Lua

    would be a nightmare to redo and i love the 2.5 lighting (even if, the GI lighting Josh demonstrated is promising).

    Sure TinyGom is not perfect and could be more polished or more complete.

    My project is to extend the game even after the release, supporting bugs too.

    Hoping to compensate a bit the funds that i have put in this game, music bought at Partnersinrhyme®, pack from Pure3D® and the time dedicated,i have considered putting a fair price to the game,

    fee at a fast-food meal or a cinema ticket.

    Whatever happens, my reward is already there, accomplish the release of the game was my main objective,

    i am satisfied and relieved now.




    Videos are also visible on my web site too.


    Hope you will enjoy the videos, test the demo if you want,

    feedback welcome at

    The game and the demo are already available on my web site now :

    Excuse my english.

    Thank you for reading.


  20. Quick demo video of my Utility and Needs Based UI test framework.



    Click to see video on workshop



    This is a quick demo video of my Utility and Needs Based UI test framework.


    There are several things going on here to cause the AI actors to decide what to do:


    - A scoring function runs every tick that updates the score for each available action. The top scoring action is marked as the active mode; if the mode changed since the last tick, startup logic runs for the new mode and the new animation loop is activated.


    - The sleep action takes into account a "need", which is tracked as an increasing number from 0-100. It slowly increases over time, somewhat differently for each actor. Around when the need reaches 100, the score function for sleep does as well, eventually exceeding all other action's scores, activating sleep. When sleeping, scores for all other actions drop since it is difficult to do anything when you're tired. The script then activates the sleep animation.


    - While performing the sleep action, the actor receives a reward each tick that they are performing this action.


    - When awake, the actors currently switch between idle and wander actions since there is currently no other input in the environment to change the score of the other actions. These actions have an internal, random time limit which varies slightly for each actor. When the time limit expires, the action is disabled (turning it red). This allows for breaking score ties for time based actions.


    It's not an ideal framework but it's a start.

  21. A year has passed, time for an other update.

    Exspecially in the last weeks, I have been thinking and working onmy Game for long hours.

    yay !

    A Video from exactly a year ago shows the early Game functions which no longer will be as they are in the final game, unfortunately. (Youtube: Slastraf)

    Today I am focusing on Game Art, not as much as -programming , just because when I got into making Games, I started off and like to work with 3D programs such as Blender or Designing Levels with the built in Editor.

    So I needed to compromise and make my Game visually looking better and make the Player interact more with the surroundings , and less with things that are time intensive to program (Mirrors Edge's FPSplayer or something like huge RPG games).


    I have read somewhere that Games in general are more interesting and fun to play , if one has lots of decisions to make.. Looking at that, it took a while for me to think of an Point-and-click style adventure game, where the Player is able to visit much and different areas of the deadly Surface of the Planet.

    But not only did I want the Player to be on the surface, but be in an Underground Vault-style Construction,

    and fight enemies that are lurking inside of it.

    (Theres going to two boss fights in 3D and also the mentioned 2.5D , but later more.)





    These both Style of Games added up , lead to the Story.

    In late 2014 I first modeled a poor looking Space Station (Yes, I originally wanted to make a space Game) which was part of a Game where the player could flee in a capsule to the nearby Planet.

    Now I taught I will start the Game right where the protagonist does A crash Landing on the Surface.


    The main Objective is now , to find a way to survive the conditions of the Planet, since it has much Gravitation, less atmospheric pressure, and temperature (extreme long hot days, cold nights).

    I dont want to start talking about the over agressive hunter animals (Bosses).

    Of course you are not the only one to crash on the surface, you are able to get main Gear from the evil alien race Survivor,

    I have already modeled the Laser Blaster, but theres going to be a Blaster Pistol, and a multifunctional ,

    hand-attachable Taser, which generates a holographic protective shield . Only the latter will be available on the Surface to fight the boss, and in the later Game theres gun battles between Inhabitants, inside the Underground construction.


    All things Planned so far:

    Coast area, (will be big part of the plot , but I dont want to spoiler)

    Cliff area,(Crash site)

    Forest area,(First casual fight)

    Swamp area( First jumbo Monster boss fight ,, no spoiler )

    Interior maps of Underground Construction


    Things I am thinking of possibly putting in the game:

    Abandoned Small city

    Long Road in Desert


    I am looking forward to extend my knowledge, Make 3D Assets, and Share my game wink.png


    Some more WIP:

    Skyboxes By chrisV, thank you !


    Crash Capsule:



    Blaster Gun ( Am going to Upload timelapse on my Youtube Channel soon)



    Cliff area: