Fun projects

Discussion in 'Art' started by Coffeeburrito, Apr 24, 2009.

  1. chrono

    chrono Member

    Messages:
    190
    Likes Received:
    0
    Trophy Points:
    0
    the link is the firing animation for the cannon. (corrently done for NF heavy tank)
    https://www.dropbox.com/s/87xeqnjdhc5i7z9/0001-0240.avi

    i agree that cannon model modification is not high priority.

    what is LOD?

    it would be important that you can tell us the code process so that themachenism would be understood and synchronized toward implementation.
     
    Last edited: Dec 5, 2013
  2. D.D.D. Destroyer

    D.D.D. Destroyer Member Staff Member Moderator

    Messages:
    9,509
    Likes Received:
    111
    Trophy Points:
    0
  3. Grantrithor

    Grantrithor Member

    Messages:
    9,820
    Likes Received:
    11
    Trophy Points:
    0
    An LOD is a lower quality model. Because from farther distances the detail in a normal quality model will be less discernible, the engine could choose to render the lower quality model instead which would pretty much show the same amount of detail at that distance. The buildings in the game for instance have lower quality models which don't have crates surrounding them and the interior isn't rendered, something that you can't properly make out from a distance anyway. The vehicles on the other hand don't have these and that's an issue because players will be rendering details they can't see, and the maps in empires tend to be very large.
     
  4. chrono

    chrono Member

    Messages:
    190
    Likes Received:
    0
    Trophy Points:
    0
    are you suggesting creating low level detail for exsistin vehicles ?
     
  5. LordDz_2

    LordDz_2 Strange things happens here

    Messages:
    2,956
    Likes Received:
    93
    Trophy Points:
    0
    Yes, for example this is the mdldecompiler.qc file for the NF soldier.
    Code:
    $lod 8
     {
      replacemodel "nf_soldier_Kant" "lod1_nf_soldier_Kant"
    }
    $lod 16
     {
      replacemodel "nf_soldier_Kant" "lod2_nf_soldier_Kant"
    }
    $lod 36
     {
      replacemodel "nf_soldier_Kant" "lod3_nf_soldier_Kant"
    }
    $lod 80
     {
      replacemodel "nf_soldier_Kant" "lod4_nf_soldier_Kant"
    }
    $shadowlod
    {
      replacemodel "nf_soldier_Kant" "lod5_nf_soldier_Kant"
    }
    While the imperial medium tank doesn't have any lods.
     
  6. chrono

    chrono Member

    Messages:
    190
    Likes Received:
    0
    Trophy Points:
    0
    ok, so is textures needs to be altered too? or is it just a modelling thing? (i noticed the VF of NF changes to simpler texture from distance, or am i wrong)

    also, what vehicle would u say is most used in game?

    also, graniter you said it is an issue, i can understand it would be an issue 5 years ago, but, doesnt most people have recent (2010) pc purchased capabilities? i mean a cheap computer these days can handle alot. so how is it still an issue?
     
    Last edited: Dec 5, 2013
  7. Grantrithor

    Grantrithor Member

    Messages:
    9,820
    Likes Received:
    11
    Trophy Points:
    0
    APC for both sides.
     
  8. LordDz_2

    LordDz_2 Strange things happens here

    Messages:
    2,956
    Likes Received:
    93
    Trophy Points:
    0
    Would be nice. :)
     
  9. chrono

    chrono Member

    Messages:
    190
    Likes Received:
    0
    Trophy Points:
    0
    also,
    how do i extract model from blender, into an *.mdl file?
    i downloaded source tools lordz linked me to, but those arent the formats.
    what else do i need?
    i can export it to obj files with blender.

    also theres another (problem?). which is, every model i import to blender from the empires game, have hundreads of useless vertices, double vertices.
    i just imported the apc, it had 1750 double vertices.
    is it the "crafty" export problem? or is it known for empires models to have this waste of vertices?

    also,
    to do this effectively, i would have to know if whats important here is the amount of vertices, amount of faces, amount of edges, or all of them together.
     
    Last edited: Dec 5, 2013
  10. Candles

    Candles CAPTAIN CANDLES, DUN DUN DUN, DUN DUN DUN DUN.

    Messages:
    4,251
    Likes Received:
    10
    Trophy Points:
    0
    The textures don't *have* to be altered, but lower resolution textures fit hand-in-hand with LOD models. However, there is something to be said about if you just use the same texture repeatedly, then it only has to be stored in the VRAM once instead of multiple increasingly smaller textures.

    I'd say at any given time, the most common vehicle will be whichever chassis was the most recently researched. But over the length of the whole round, I feel that APC's will get used more than anything else.

    Finally, there's a good number of players who have computers well older than three years. Hell, some of us still run Windows XP.
     
  11. Grantrithor

    Grantrithor Member

    Messages:
    9,820
    Likes Received:
    11
    Trophy Points:
    0
    It's more about efficiency. Programmers love efficiency. The resources freed up by the LOD can be then put to better use. You want a video game to be as optimized as possible, no matter if modern PCs can run it unoptimized.

    And like candles said, people who play source mods are running 5 year old computers. That's pretty much our demographic here.
     
  12. LordDz_2

    LordDz_2 Strange things happens here

    Messages:
    2,956
    Likes Received:
    93
    Trophy Points:
    0
    It's a bit of a hazzle.
    You added the tool so you can export the model into an .smd?
    You should have this in your menu in that case:
    [​IMG]
    Pressing that and you will probably get an exporting error.

    On the menu on the right (notice the icon that is pressed) you need to fill in the folders needed.

    On extract, choose which folder you want to extract to.
    On engine you're supposed to go to your steam folder/steamapps/username/sourcesdk/bin/source2007/bin and apply as this is the engine we're extracting for.

    [​IMG]
    This should be set to SMD.

    A bit further down you find this:
    [​IMG]
    Set it to //..\..\..\..\Games\Steam\SteamApps\common\Empires\empires\
    (navigate and select the folder, don't copy the above).

    In the QC path you input your mdldecompiler.qc that you were given when you decompiled the model.

    Then you go to file->Export->Source Engine. Hopefully everything will work and you will have your .smd file in the folder where you saved it.

    [​IMG]
    Take this file and copy it into the folder where the files are from the decompiled model.

    [​IMG]
    Remove the old file and rename your .smd file to that filename.
    So here I take the nf_soldier_Kant.smd, remove it and replace it with nf_soldier_Kant.001.smd which I rename to nf_soldier_Kant.smd

    Open the mdlcompiler.qc with a text editor. I prefer Notepad++

    https://dl.dropboxusercontent.com/u/7315285/Mapping/Empiresmod/Exporting%206_cd.PNG
    Somewhere in the mdlcompiler.qc you should find a line like "$cd "D:\Misc\Modding\Models\2. Decompiled Models" (this is the folder were your decompiled model is), replace it to the folder where your model is.

    [​IMG]
    The files for the brenodi medium cannon.

    Now there is just one last step left to do.
    Download GUIStudioMDL

    [​IMG]
    Place it in this folder. It's very important that you place it in this folder or it will not run.

    [​IMG]
    Click on the add button to add the gameinfo for the game you wish to compile the model for. I did not manage to get it to work with the Empires gameinfo.txt, so I choose the gameinfo.txt for Obsidian Conflict (any mod located in your sourcemods folder should probably work).

    Then you just click on the file->Load QC file, find the mdlcompiler.qc file for your model, and then hit compile. Hopefully everything should work.

    I know it seems like a lot of steps, but I did add a lot of images to try to make it as simple as possible to understand. Good luck! :)
     
  13. LordDz_2

    LordDz_2 Strange things happens here

    Messages:
    2,956
    Likes Received:
    93
    Trophy Points:
    0
    It's 9 steps.
     
  14. chrono

    chrono Member

    Messages:
    190
    Likes Received:
    0
    Trophy Points:
    0
    i have read all that have been posted.
    umm
    so okay, apc... assuming the 1750 vertices is a mistake of the program rather than then the responsebility of the one who made it(although i dont belive so), ...then i decreased atleast 250 vertices. which is kinda alot(alot after got rid of 1750)
    while doing it i stumbled across some 50 that are inside the model and are not noticeable even from close range, ...so they could be taken off the original model as well.
    it looks like it is a mess...and it is a bit.

    congratulations lordz on your new icon.
    it is better i think
     
    Last edited: Dec 5, 2013
  15. wealthysoup

    wealthysoup Lead Tester

    Messages:
    1,857
    Likes Received:
    0
    Trophy Points:
    0
    I haven't tried it yet but the new GUI beerdude is working on will (hopefully) go some way to resolving this problem.


    Edit: Chrono if you aren't sure about how something works in Source then here is a good place to start.

    Specifically for modelling then you want this subsection

    Theres a bit about LOD's specifically there aswell.

    Edit 2: A good aim for LOD's is to reduce the poly count whilst not making the model look noticeably worse at any distance. I.E. Remove the finest details with the first LOD then the slightly less fine details with the second and so on.
    For example if you have 3 LOD's, even a saving of 100-150 polys/vertexes or whatever you call them at each LOD level will make a reasonable saving over the map. (Obviously the saving is determined by the amount of detail in the first place)
     
  16. LordDz_2

    LordDz_2 Strange things happens here

    Messages:
    2,956
    Likes Received:
    93
    Trophy Points:
    0
    Yeah, that would really be awesome.
     
  17. chrono

    chrono Member

    Messages:
    190
    Likes Received:
    0
    Trophy Points:
    0

    the link doesnt answer really, but has good information, but still, what is important in the lod?
    you said polygon reduce. is a polygon, a vertice? an edge?
    i mean, im sure im reducing polycount, but ive googled polygons in modelling and i still cant figure out what has the most wieght here, faces edges vertices or all of them together.
    i guess its all of them together, and it works as if like the less data it needs to save (like 4 ertices with 5 edges against 4 ertices with only 4 edges) the better. which means basically, whatever(edges/vertices/faces) you can reduce, then reduce.

    ive looked at the commander vehicle...and it would possibly have much more vertices than others.
    ill think ill for that one next.
     
    Last edited: Dec 7, 2013
  18. Grantrithor

    Grantrithor Member

    Messages:
    9,820
    Likes Received:
    11
    Trophy Points:
    0
    A polygon is a simple 2-dimensional shape, made up of vertices. The simplest polygon is the triangle and as far as I know all polygons in computer graphics are simplified to triangles even though you may work with squares, pentagons, etc. What you want to do is to reduce polygons, because that's what the GPU computes, polygons, and the more polygons, the longer the computations take.
     
  19. flasche

    flasche Member Staff Member Moderator

    Messages:
    13,299
    Likes Received:
    168
    Trophy Points:
    0
    polygon is misleading it should be tris or triangle. a vertex is a point an edge a connection of two verices, a triangle is what is formed by 3 verts.
     
    Last edited: Dec 5, 2013
  20. LordDz_2

    LordDz_2 Strange things happens here

    Messages:
    2,956
    Likes Received:
    93
    Trophy Points:
    0
    So in short: Remove lots of vertices that cannot be seen from distance, and do it in several models.

    Original model -> Shadow lod 1 -> Shadow lod 2 -> Shadow lod 3 -> Shadow lod4 ..
     

Share This Page