Jump to content

SpiderPig

Developers
  • Posts

    2,258
  • Joined

  • Last visited

Posts posted by SpiderPig

  1. But I have no way of tracking them. ;)  I mean my project is large and materials are being created and deleted left right and centre.  I've already discovered I'll need to move all my icons for inventory items into one texture and draw them in the inventory via manipulating tex-coords.  If I don't know how many there currently are I don't know where to make improvement's.  256 materials will be used pretty quick, that's only 256 unique objects. ^_^

  2. Okay thanks.  So it's pretty much just a memory game.  I thought there might also be a maximum amount of entities and materials too as the shaders look them up in an array.  Maybe those arrays have no set size like the textures do.

  3. Sure can.  This is the material I set to a line mesh.

    debug_material = CreateMaterial();
    debug_material->SetShaderFamily(LoadShaderFamily("Shaders\\Unlit.json"));
    debug_material->SetLineStipple(LINE_STIPPLE_DASHED);

    Line mesh was created like this and then the model scaled to the right size.

    model = CreateModel(world);
    model->SetRenderLayers(render_layers);
    
    mesh = model->AddMesh(MESH_LINES);
    mesh->AddVertex(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 1.0f);
    mesh->AddVertex(1.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 1.0f, 1.0f);
    mesh->AddVertex(1.0f, 1.0f, 0.0f, 0.0f, 0.0f, 0.0f, 1.0f, 0.0f);
    mesh->AddVertex(0.0f, 1.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
    
    mesh->AddPrimitive(0, 1);
    mesh->AddPrimitive(1, 2);
    mesh->AddPrimitive(2, 3);
    mesh->AddPrimitive(3, 0);

     

    • Thanks 1
  4. SetLineStipple() has to be the single most best thing about Ultra.  :wub:

    I'm using it here to debug my widget system.  Different coloured borders are used to identify different types of containers.  I've pretty much implemented Godot's UI system into Ultra.  You can see the various containers and how they expand in different ways to fill their parents.  There are a few issues on the left with the scroll containers, hence the debugging mode. ;)

    Debugging_UI.thumb.png.e324b12cceb4f0022e5a3fc0e33262bf.png

  5. Just want to get a clear idea on what are some of the limits for these things so I can be sure to not exceed them.  As I understand it only so many materials, textures, entities and maybe other things can be passed to the shaders.

    What are the max:

    • Entities
    • Materials
    • Textures
    • Any thing else?
    • Upvote 1
  6. I loaded this into the model viewer and re-saved it from there.  In C++ it still says only 1 LOD is available and it has a mesh size of 0.  Even though the output says it loaded the other LOD and it renders perfectly.

  7. Thought I'd change this post to track the work in progress of my game instead.  :)

    I've been spending time on procedural foliage generation.  I create a volume and then add different items to that volume.  It then procedurally places them inside the volume based on growth rates, shadow and collision radius and eventually height map data.

    The green bounding box is the foliage volume.  The blue is where a sound will fade in when you enter it.  The distance between the blue and green bounding boxes dictates the sound volume.  I'll have to make a video of this soon.

    ProceduralFoliage_001.thumb.png.1cf95bda2d187c6e410293c40b4e7912.png

     

    Each tree has an interaction assigned to it.  This is a system I made in Leadwerks.  The player has a box that it's bounds are used to get overlapping entities, if any of those entities have an interactable object assigned to it a label will appear on screen telling you what can be done.  For these trees they will supply bark to your inventory.  All the coloured shapes are debugging visualizers.

    ProceduralFoliage_002.thumb.png.63642153c0e51e9bf97ac886b4a65e7c.png

     

  8. I can do it in C++ but how to set it in the JSON material? <_<

    {
    	"material":
    	{
    		"version": 100,
    		"color": [ 1.0,  1.0,  1.0,  1.0 ],
    		"emission": [ 0.0,  0.0,  0.0 ],
    		"metallic": 0.0,
    		"roughness": 0.0,
    		"transparent": false,
    		"occlusionInfo": true,
    		"occlusionScale": 1.0,
    		"normalScale": 1.0,
    		"shaderFamily": "PBR"
    	}
    }
    

     

  9. I think what I need is to disable depth testing but it didn't do what I expected.  The models that this material is applied to are small and are sometimes inside other objects, I just want them to be always onto of everything.

    debug_point_material = CreateMaterial();
    debug_point_material->SetShaderFamily(LoadShaderFamily("Shaders\\Unlit.json"));
    debug_point_material->SetShadow(false);
    debug_point_material->SetDepthMask(false);
    debug_point_material->SetDepthTest(false);

     

  10. Yeah it is a tough one.  I think I've found a way in Audacity to normalise sounds to a specific dB rating.  Even if it's not exact it doesn't matter, just as long as the sounds have the right volume compared to each other.  A few of the systems like dialogue, music and effects will have a master volume.  I think I'll have to use a chart like this, just to get an idea on where things should be to make them at least a little realistic.  I'll probably make my own chart based on this and insert my sounds at the correct dB rating and then just test it!  See if that works.

    noiselevelchart.thumb.png.b19668f3877e2bca5796a1f85483bfdd.png

     

    • Like 1
  11. I assume most of you, like me, have various sounds gathered over the years but all of them are at varying levels of volume.  Even simple things like, the footsteps on stone might be 10x louder than the footsteps for grass.  I wonder if anyone knows if there is a standard volume sounds should be converted to in dB?  I mean there are sounds which should be louder than others like explosions vs footsteps but are there pre-defined levels they should be at or is it just a guessing game?  Curious to hear any thoughts you guys might have.  :)

×
×
  • Create New...