Jump to content

tjheldna

Members
  • Posts

    938
  • Joined

  • Last visited

Posts posted by tjheldna

  1. platform movement is smoother but the character still doesn't follow it unless i keep moving on it

     

    Actually Yes that's exactly why you need to use a joint, the player wont follow the platforms position otherwise. I've created a moving platform using a slider joints and the player follows the platform where ever it goes.

     

    Another thing to take into consideration using this method is to create a custom collision type for the platform that doesn't collide with the "Scene" else it can send it off course.

     

    There are these scripts in the default MyGame Project.

     

    Objects\Physics\Platform.lua

    Objects\Physics\PlatformWaypoint.lua

     

     

    I can get you the files if you can't find them.

  2. Yes, the modular thing in LE didn't work for us with the size of the project we are looking at. You can keep it modular, but I recommend build your structures in your modeling program and export as much as you can as one piece. We did a lot of testing in the initial stages of our project to see what is possible.

  3. Here is a Simple C++ only GUI system for Leadwerks 3.5 named tjui. This project includes full source and a working example (a game settings window for now).

     

    Why use this? For starters it's free! Secondly it uses a mixture and expands on Leadwerks functionality like drawText and drawRect, so there is no messy linking or setup. The system is extremely flexible and in which you can create your own widgets from combinations available.

     

    Download full project here including source

     

    Download tjui_1.3.zip

     

    To use copy the contents to where your projects are found import via the LE editor

     

    What's New in Version 1.3 (Current 26/4/15)

    • Updated the way widget events occur and they are now as optimised as I can get them to date.
    • Renamed variables so they are to US spelling i.e color compared to colour.
    • New modifier class fade in/out/pulsate.
    • Before if widgets overlapped and the cursor overlapped both, the event would trigger for both. This has now been fixed to only trigger for the topmost widget.
    • Works with Leadwerks 3.5.

    What's New in Version 1.2

    • If you downloaded any previous version you will need to update to this build. Most if not all changes happen in the base code and shouldn't effect anything else.
    • Made a mistake setting the root list to only accept windows. I have reversed this. The root node should be the only node without a parent and if you Detatch() you will need to delete the detached widget manually.
    • Fixed an iterator bug with Modifiers. This is a show stopper if you use one.
    • Use the Remove() function to remove any widget either a base window or widget.
    • Added overloaded function to Detatch(), you now can pass an iterator and return it, in case you are using the function in a loop.
    • Removed UpdateWidget() and the functionality happens elsewhere and more efficiently.
    • Added a few random optimisations as I saw them

    What's New in Version 1.1

    • Fix bug with SetPosY due to last minute variable name change.
    • Overhaul of standard Button Widget code.
    • Widgets children now use lists not vectors.
    • The Interface only accepts windows to be added at the root level.
    • Many optimisations.
    • Settings window. I've started to create a settings window so you don't have to!

    Supported Widgets

    • Border
    • Button
    • CheckBox
    • GroupWidget
    • Icon Button (Image button with an image icon overlay)
    • ImageBox (Draw Image)
    • ImageButton (3 different images for the different states)
    • Label (Draw text)
    • LineTextBox (Label with lines)
    • ProgressBar (Vertical or Horizontal)
    • Quad (Draw Rect)
    • Radio Button
    • RadioButtonGroup
    • SingleImageTextButton (Single image with text overlay)
    • SingleImageButton (Image Only)
    • GUIWindow
    • Widget (Base Class)

    Future Plans

    • Create a main menu window
    • Create a credits window
    • Cursor widget. This is done I just need to cut it over.
    • Widget: Horizontal Rule.
    • Self destruct modifier, this will delete it's associated widget after a period of time.

    If you have any ideas on how to improve pm me, or post here. I really hope this can be put to good use. Also if this system is used in your game i'd like to know!

    • Upvote 4
  4. Would be cool in the texture editor if you can have an option to halve the size of the texture, nothing too complex, just a check box or something.

     

    For example I have a rifle texture that I want to work on in 1024 x 1024 res, I want to keep working on it in 1024 x 1024, but when I export it I want it 512 x 512.

     

    If there was an option like that I can continue to work on my art as is, and know that the engine will optimise it for me. If your working on a texture over time and overwriting it constantly like I do, it's only a matter of time till you forget to resize it when saving it to the editor.

     

    You could also see in real time if reducing the size of the texture makes any noticeable impact and can be an instant unexpected resource save.

     

    Just a thought.

    • Upvote 4
  5. Hi Josh,

     

    In the last couple of days I've changed over the floor collision of houses to the 'poly mesh' type as I am now able to generate navmesh with it which is a better solution than using hints. Since doing that this issue is presenting particularly devastating one as an exact pick is a major part of game play.

     

     

    I added code a sphere to be created at the location in the main game and the picks at times are nowhere near where the cursor is, angles of objects appear to play a part in it too.

     

     

    Add this to the pick to visually see where the pick is going in the provided project....

     

    model = Model:Sphere()

    model:SetScale(0.04, 0.04, 0.04);

    model:SetCollisionType(0);

    model:SetColor(1.0,0.0,0.0)

    model:SetPosition(pickInfo.position)

     

     

    If you could look into what's going on with picking that would be fantastic! Its really put the project in a bad state.

     

    Thanks

  6. On further thinking about using the CollisionHull method I realised it wont work for our example. When you enter a building I need to be able to have control over the various floors collision type as the player traverses a building, so it needs to be an entity.

     

    Currently I'm exporting a collision mesh->generate shape on it and overwriting the existing models .phy shape. When I do this the "Show Physics" of the mesh does not update in the model editor or the map, which can be problematic. The shape is also wiped if I re-save the original model so I could accidentally revert to the original collision mesh without realising very easily.

     

     

    I wouldn't say its a pain in the *** to do, but it's hacky and prone to error.

     

    I'm still gunning for a "Custom Collision" option back in.

    • Upvote 1
  7. I took a look at the wobbler02 file only and found your issue and I should have picked up on the issue quicker...

     

    In Leadwerks have you created material and assigned to the model? Then in the material to use an animated shader? The folder is Shaders\Model\Animated\

     

     

    As soon as I did that it started animating in the model editor.

     

     

     

    Reading your first post again, I have never heard of the technique that you are using with a secondary rig, sounds more complicated than it needs to be, and could be opening yourself up to more issues, but whatever.

     

     

    There used to be a GREAT tool in the model editor to show the skeleton, but it has since been removed which I think is strange as it was a vital tool to check your skeleton for any import problems. This is a prime example where it would be useful. If this tool was there you would have seen that the skeleton was animating.

     

    Please Josh put the show skeleton option back in!!

    • Upvote 1
  8. If you change the collision type in the model editor then save it the setting, model settings such as collision type, navmesh, in fact ALL your settings from the "Appearance" tab, "Physics" tab but does not appear to effect the "Scripts tab are reset to default for all instances in the world.

     

     

    If an instance is already selected in the Scene graph, and you save the model in the model editor the settings wont show this issue till you re select it.

     

    So I have 50 instances of a model with various settings like "View Range" set to "Near", "Nav Obstacle" checked etc and I decide that a model needs to be updated, and need to save it again in the model editor, I'm going to have to go over every single instance in the editor and reset those settings all back.

     

     

    We need have be able to update the model and physics component of the entity without effecting all the instance settings in the editor.

  9. Ok I did a test and found something really frustrating..... The navmesh check box needs to be checked to generate on the polymesh, that's fine I got that.

     

    If you change the collision type in the model editor then save it the setting, model settings such as collision type, navmesh, in fact ALL your settings from the "Appearance" Tab, "Physics" tab are reset to default for all instances in the world. If an instance is already selected in the Scene graph, it wont show this change till you re select it, which is what was happening in my case and why was thinking it should be working when it wasnt.

     

     

    So I have 50 instances of a model with various settings like "View Range" set to "Near", "Nav Obstacle" checked etc and I decide that a model needs to be updated, and need to save it again in the model editor, I'm going to have to go over every single instance in the editor and reset those settings all back. As map content increases, how the hell you supposed to manage that???

     

    Artists have be able to update the model and physics component of the entity without effecting all the instance settings in the editor.

×
×
  • Create New...