Welcome to Keen Software House Forums! Log in or Sign up to interact with the KSH community.
  1. You are currently browsing our forum as a guest. Create your own forum account to access all forum functionality.

Example: Adding new model

Discussion in 'Modding Guides and Tools' started by Ondrej.Petrzilka, Nov 1, 2013.

Thread Status:
This last post in this thread was made more than 31 days old.
  1. scragnog Trainee Engineer

    Sounds like a perfect way to do it! Garrys Mod had something very similiar. When you joined a modded server, you'd get all of the 3rd party files upon joining. It was a simple, seamless experience and worked great!

    I would think that you guys could think of a simple solution to this, but I would guess instead of adding new modded blocks into CubeBlocks.sbc, it'd make sense to have each mod have its own sbc file specifying the models it uses. So like 'PHXWeaponPack.sbc' for example. That would save the CubeBlocks.sbc file being overwritten every time a new mod is loaded with custom models.

    I can't wait for this though! :-D
  2. GeneralApathy Apprentice Engineer

    Yes, yes, yes!
  3. Bort Trainee Engineer

    Thank you, that sounds good. I forgot that there are also options within privately owned Valve game servers, too, within the server's config file, where the server owner or an administrator can set up certain things required by all the players joining that server to be downloaded from a separate server. I've actually modded a game (Empires) and put the required, changed, files on the download server and used the config file so anyone that joined would automatically download our modifications. So that is very possible too. The downfall with that is that

    1. it may take forever to download depending on the size of the mod. I don't think there is a file compression thing available for this through or on steam game servers. I could be wrong. It would also be up to the user/player if they wanted to wait for a long download or not.
    2. ...security risks. Which...should be left to the individual players to decide whether they want to join that server and download the modifications and take that risk or not. Which is how it is anyway.
    I was just curious as to how you(the devs of Space Engineers) were considering doing it. It would be nice to have all options available, which it seems that's what's being considered. Thanks for answering!
  4. RastionSigne Trainee Engineer

    Yes! Official mod support built into the core game would be amazing. IMO that is where Minecraft is most lacking, they continuously focus on content but the community can generate way more content if a stable API of sorts is put into place.
  5. Sims_doc Junior Engineer

    Just sorta curious anyone know if the developers allow users extracting models? because i want to use the current models as reference so i can make a few custom turrets and a better control chair, passenger chair.
  6. Bort Trainee Engineer

    They are obviously in support of player creativity. I would just do it. If they have a problem with it they'll let you know. Everything is in the Terms of Service. If you're that concerned, read the TOS in full and make sure what you're doing is ok. If the TOS doesn't say you can't...you can.
    It's also safe to assume any model you can open, you can use as reference or even edit it. Keep in mind, of course, if you edit a current model it may not work very well when they release multiplayer.
  7. Sims_doc Junior Engineer

    Thanks for the update, sadly someone told me about the pre extracted stuff recently and i've been using that for reference instead.
  8. xMoneyShadow Apprentice Engineer


    After the new update today, you WILL
    need to change the blockposition from


  9. camsedin Trainee Engineer

    Block position is not needed. it just goes into what ever block slot is free.
  10. ripptide Trainee Engineer

    Thanks for the info camsedin, thought I was losing it when adding some blocks. Do you know if you can set placement (in order to keep blocks grouped) or is that section of CubeBlocks.sbc no longer used?
  11. flintread Trainee Engineer

    I have found that you can export from lightwave with this method save your lwo. file then open deep exploration save as fbx. from deep exploration and you will not suffer from lightwaves strange habit of making strange smoothing artifacts and your smoothing data and uv map will import intact :D happy lightwaving another 3d application user base enters the fray!
  12. Sims_doc Junior Engineer

    Would someone please create a video tutorial on this subject so it can be attach to the thread ASAP.

    [Edit] Also because i wouldn't mind doing this myself quickily without having to contact another person and wait a week for a few models to be ported while he does a dozen in the meantime..
  13. Rareden Trainee Engineer

    My game crashes on startup if i modify the cubeblocks.sbc with a custom block
              <Side Model="Models\Cubes\small\armor\small_half_squareFront" PatternWidth="4" PatternHeight="2" />
              <Side Model="Models\Cubes\small\armor\small_half_squareFront" PatternWidth="4" PatternHeight="2" />
              <Side Model="Models\Cubes\small\armor\small_half_squareFront" PatternWidth="4" PatternHeight="2" />
              <Side Model="Models\Cubes\small\armor\small_half_squareFront" PatternWidth="4" PatternHeight="2" />
              <Side Model="Models\Cubes\small\armor\small_half_square" PatternWidth="2" PatternHeight="1" />
              <Side Model="Models\Cubes\small\armor\small_half_square" PatternWidth="2" PatternHeight="1" />
            <Component Subtype="SteelPlate" Count="10" />
          <CriticalComponent Subtype="SteelPlate" Index="0" />
            <MountPoint Side="Front" StartX="0" StartY="0" EndX="1" EndY="1" />
            <MountPoint Side="Back" StartX="0" StartY="0" EndX="1" EndY="1" />
            <MountPoint Side="Left" StartX="0" StartY="0" EndX="1" EndY="1" />
            <MountPoint Side="Right" StartX="0" StartY="0" EndX="1" EndY="1" />
            <MountPoint Side="Bottom" StartX="0" StartY="0" EndX="0.5" EndY="0.5" />
            <MountPoint Side="Top" StartX="0" StartY="0" EndX="0.5" EndY="0.5" />
            <Variant Color="Red" Suffix="_red" />
            <Variant Color="Yellow" Suffix="_yellow" />
            <Variant Color="Blue" Suffix="_blue" />
            <Variant Color="Green" Suffix="_green" />
            <Variant Color="Black" Suffix="_black" />
            <Variant Color="White" Suffix="_white" />
          <BuildProgressModels />
          <ExcludedAreaForCamera />
          <CenterOffset xsi:nil="true" />
  14. darth_biomech Senior Engineer

    I just don't get it. Textures are in right places, name of materials is identical in both FBX and XML, but I still get black model ingame.

    <?xml version="1.0"?>
    <Model Name="Default">
      <BoneGridSize d2p1:nil="true" xmlns:D2p1="http://www.w3.org/2001/XMLSchema-instance" />
      <Parameter Name="Centered">false</Parameter>
      <Parameter Name="RescaleFactor">1000.00</Parameter>
      <Parameter Name="RescaleToLengthInMeters">false</Parameter>
      <Parameter Name="SpecularPower">10</Parameter>
      <Parameter Name="SpecularShininess">0.8</Parameter>
      <Material Name="01 - Default">
        <Parameter Name="SpecularIntensity">0</Parameter>
        <Parameter Name="SpecularPower">2</Parameter>
        <Parameter Name="DiffuseColorX">255</Parameter>
        <Parameter Name="DiffuseColorY">255</Parameter>
        <Parameter Name="DiffuseColorZ">255</Parameter>
        <Parameter Name="Texture">Textures\Models\Cubes\large_hydrophonic_de.dds</Parameter>
        <Parameter Name="NormalTexture" />
  15. nanobot Trainee Engineer

    You need to add a _ns (normal/spec) texture.
    RGB channel for normal and alpha channel for the specular.

    place in the same location as the diffuse texture,
    then fill in the normal map parameter in your model .xml (before generating your .mwm file)

    In your case change:
    <Parameter Name="Texture">Textures\Models\Cubes\large_hydrophonic_de.dds</Parameter>
        <Parameter Name="NormalTexture" />
    <Parameter Name="Texture">Textures\Models\Cubes\large_hydrophonic_de.dds</Parameter>
        <Parameter Name="NormalTexture">Textures\Models\Cubes\yourNSTextureNameGoesHere.dds</Parameter>
    Supposedly you can leave the NormalTexture parameter as you have it (with no file location) if you save your ns file with the same name, but with
    a _ns instead of _de, and if they are located in the same folder. But I haven't actually tested this. Note that if you do use my placeholder below you
    will have to either change the parameter as I said above to the correct name, or just rename the texture to (using the above example) :
    If you don't know how to make a normal/spec texture feel free to use my placeholder ns file below.

    I would just post the texture here but most image boards won't let you upload .dds files.
    Let me know if you, or anyone else, has problems downloading it from google Docs.
  16. darth_biomech Senior Engineer

    Yeah, thanks, but it is not the case. I found my problem anyway, and it was that I turned off texture in material to bake lightning in, and forgot to turn it back on afterwards. But missing normalmap instead messing up with model smoothgroups, so even blank one is required.
  17. EctoSage Trainee Engineer

    Does this still work? Because for the life of me I cannot get any new objects to show up in the object selection screen.

    ***Edit: Got it all to work... after so many damn hours of fiddling with all this coding nosense. . . Except teh Collision Mesh... For some reason the collision on my object is showing up as a large Cube.

    ----------XML File---------------------------------------
    <?xml version="1.0"?>
    <Model Name="CryoPod">
    <BoneGridSize d2p1:nil="true" xmlns:D2p1="http://www.w3.org/2001/XMLSchema-instance" />
    <Parameter Name="Centered">false</Parameter>
    <Parameter Name="RescaleFactor">0.01</Parameter>
    <Parameter Name="RescaleToLengthInMeters">false</Parameter>
    <Parameter Name="SpecularPower">10</Parameter>
    <Parameter Name="SpecularShininess">0.8</Parameter>
    <Material Name="CryoPod_M">
    <Parameter Name="SpecularIntensity">0</Parameter>
    <Parameter Name="SpecularPower">2</Parameter>
    <Parameter Name="DiffuseColorX">255</Parameter>
    <Parameter Name="DiffuseColorY">255</Parameter>
    <Parameter Name="DiffuseColorZ">255</Parameter>
    <Parameter Name="Texture">Textures\Models\CryoPod_de.dds</Parameter>
    <Parameter Name="NormalTexture">Textures\Models\CryoPod_ns.dds</Parameter>

    ----------CubeBlocks File Snippit------------------------
    <div> &lt;Definition>
    &lt;Component Subtype="Construction" Count="8" />
    &lt;Component Subtype="InteriorPlate" Count="12" />
    &lt;Component Subtype="SmallTube" Count="4" />
    &lt;CriticalComponent Subtype="Construction" Index="0" />
    &lt;MountPoint Side="Top" StartX="0" StartY="0.8" EndX="1" EndY="1" />
    &lt;MountPoint Side="Bottom" StartX="0" StartY="0" EndX="1" EndY="0.2" />
    &lt;MountPoint Side="Left" StartX="0" StartY="0" EndX="0.2" EndY="1" />
    &lt;MountPoint Side="Right" StartX="0.8" StartY="0" EndX="1" EndY="1" />
    &lt;BuildProgressModels />
    &lt;ExcludedAreaForCamera />
    &lt;CenterOffset xsi:nil="true" />
  18. johncage Trainee Engineer


    this needs to happen asap
  19. Balmung Senior Engineer

    Short Description how to make your own Custom Block Survival Mode ready:

    I use the Large Gatling Turret as Example

    1. You need the finished Model and for every Build Step you want an extra Model (+ Textures).

    At our Example that would be:

    GatlingTurret.mwm &lt;- the complete Model

    GatlingTurretConstruction_1.mwm &lt;- 1. Build Step
    GatlingTurretConstruction_2.mwm &lt;- 2. Build Step
    GatlingTurretConstruction_3.mwm &lt;- 3. Build Step

    2. The "CubeBlocks.sbc" File:
            &lt;SubtypeId />
          &lt;Size x="3" y="3" z="3" />
          &lt;ModelOffset x="0" y="0" z="0" />
          [COLOR= #0000ff][B]&lt;Components>[/B][/COLOR]
    [COLOR= #003366][B]        &lt;Component Subtype="SteelPlate"[/COLOR] [COLOR= #008000]Count="5"[/COLOR] />[/B]
    [COLOR= #003366][B]        &lt;Component Subtype="Construction" Count="25" />[/B][/COLOR]
    [COLOR= #003366][B]        &lt;Component Subtype="SmallTube" Count="6" />[/B][/COLOR]
    [COLOR= #003366][B]        &lt;Component Subtype="LargeTube" Count="1" />[/B][/COLOR]
    [COLOR= #003366][B]        &lt;Component Subtype="Motor" Count="8" />[/B][/COLOR]
    [COLOR= #003366][B]        &lt;Component Subtype="Computer" Count="10" />[/B][/COLOR]
    [COLOR= #003366][B]        &lt;Component Subtype="Construction" Count="5" />[/B][/COLOR]
    [COLOR= #003366][B]        &lt;Component Subtype="SteelPlate" Count="15" />[/B][/COLOR]
    [B]      [COLOR= #0000ff]&lt;/Components>[/COLOR][/B]
          [B][COLOR= #993300]&lt;CriticalComponent Subtype="Computer" Index="0" />[/COLOR][/B]
            &lt;MountPoint Side="Bottom" StartX="1" StartY="1" EndX="2" EndY="2" />
    [B]      [COLOR= #0000ff]&lt;BuildProgressModels>[/COLOR][/B]
    [COLOR= #003366][B]        &lt;Model BuildPercentUpperBound="0.33"[/COLOR] [COLOR= #008000]File="Models\Cubes\Large\GatlingTurretConstruction_1"[/COLOR] />[/B]
    [COLOR= #003366][B]        &lt;Model BuildPercentUpperBound="0.66" File="Models\Cubes\Large\GatlingTurretConstruction_2" />[/B][/COLOR]
    [COLOR= #003366][B]        &lt;Model BuildPercentUpperBound="1.00" File="Models\Cubes\Large\GatlingTurretConstruction_3" />[/B][/COLOR]
          [B][COLOR= #0000ff]&lt;/BuildProgressModels>[/COLOR][/B]
          [B][COLOR= #993300]&lt;BuildTimeSeconds>30&lt;/BuildTimeSeconds>[/COLOR][/B]
    The new &lt;Components>&lt;/Components> Area have the Data what you need on Components to build this Block.

    This Data's are in this Area:

    -The Order in which the Components are used/needed (1. Line = 1. Component / Last Line = Last Component)
    -The Type of the Component (Subtype="&lt;Component Type>")
    -The Number of this Component (Count="&lt;Number>")

    After this Area there is a &lt;CriticalComponent> Flag, this mark where the 100% Place is, the thin red Line on the Construction Window, when this Component is build the Block is ready for use and the normal Model of the Block is used. For our Example means this, that the Gatling Turret can be used when the Computer Components are build into the Block. If you have for example three "SteelPlate" Component Entries and you want that the last one is the Critical one, then you must set Index to 2 (Index="2"), the Number of the Entry -1.

    The new &lt;BuildProgressModels>&lt;/BuildProgressModels> Area have the Data when which Construction Model of your Block should be used.

    -Up to which percent the Model should be used (BuildPercentUpperBound="&lt;Number>") 0.00 = 0% / 1.00 = 100% from &lt;CriticalComponent>
    -The Path and Filename without the ".mwm" Extension of the Construction Models

    At the End is a &lt;BuildTimeSeconds> Flag, that should be the Time you need to build the Block, but I'm a bit confused. I stop the Time to build the Gatling Turret up an get 40 Seconds, but there stand 30 Seconds.

    On some other Blocks there are a "&lt;DisassembleRatio>2.5&lt;/DisassembleRatio>" Flag directly after the last Flag above. I'm not sure what exactly that is but for me it sounds it is the Ratio how much faster you can disassemble a Block than assemble it, depending on &lt;BuildTimeSeconds>.

    Note: some Things I have tested to get sure that I'm right, but I didn't made a Custom Block to check all of this, but as far I could see there is no reason you can't made this.
  20. darth_biomech Senior Engineer

    As may some of you know that last update broke mods, Devs changed file format for models and it's now causes game to crash when trying to load old model. I found out why. Devs lifted restrictions about collision meshes. Custom ones is now possible!
  21. TheKotU Apprentice Engineer

    That's good to know that they lifted that, hoping to get updates from mod authors so i can update my Mod List
  22. Fus Apprentice Engineer

    Any chance of telling us what changed?

    None of my models load, but I can make a new "box" and get that in game.
    I don't want to have to make completely new models if I don't have to, so what changed ?
  23. darth_biomech Senior Engineer

    You just need to recompile your fbx into mwm again, that's all.
  24. kolt16 Trainee Engineer

    I have a problem with maya 2014 models, if I assign any material to my model I get a crash in game.

    crash log: (let me know if you need the whole log file)

    Importing asset Models\Cubes\Large\Gratefloor, ...
    Exception occured: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.ArgumentOutOfRangeException: Length cannot be less than zero.

    The only reference I found is on Se-Modz, but no answer is given there, at least not yet, if I get one I'll post it both ways, so the next unfortunate who runs into this will have something to find.

    I did run a bunch of test on this. Model complexity and material type, and export options seem to be irrelevant (tested with original models and combinations)

    My best guess at the moment is that it has to do with uv mapping, but how or why I have no idea. If anyone ran into this before please let me know what the hack to do about it..

    Solved, I'm an idiot :D

    Anyway if this happens the reason is you defined the texture wrong in the xml file for the mwm conversion. Should have checked for it sooner, I just assumed from something that .dds is added by default, it isn't.. :D
  25. Denesta Trainee Engineer

    I don't suppose there is anyway through some kind of plugin to do collision in Blender is there? I really want to make my own models for this but I can't afford Maya or 3DsMax.
  26. KC8DEE Apprentice Engineer

    if you are in school or a student you can get Maya for free
  27. Denesta Trainee Engineer

    I am past the student stage. That's why I was hoping there was an alternative.
  28. Embershard Senior Engineer

    Yeah, there is a free alternative. Let me find it and I'll edit this post with the download link. Don't use it myself, but one of the modders in the community does, so it works.
  29. Shaostoul Senior Engineer

    You could always find a modder who has access to Maya to build it, if you wanted to go that route.
  30. Embershard Senior Engineer

    Here you go Denesta, took a bit to find it.

Thread Status:
This last post in this thread was made more than 31 days old.