How to create custom blocks ?

    Joined
    Jul 9, 2013
    Messages
    23
    Reaction score
    0
    Hi ! Today I've worked on a ship and I've get an idea : Create custom Crystal block like a green crystal. So I make the texture and place it in t002 .

    Now I create a new Entry for Block ID I use : UNUSED_TEST , Use my own texture ID and generate Icon name and category : So now I get my block but when I try to create another I must go at the config file for add new entry so I go in but I don't know how to make another one without breaking the game

    Can someone help ? Did anyone have a Tutorial for it ?
     
    Joined
    Jun 23, 2013
    Messages
    295
    Reaction score
    0
    • Legacy Citizen 2
    • Legacy Citizen
    and simplest way I\'m aware of and use is to directly go in the files.

    First:

    ~\\StarMade\\data\\config\\BlockTypes.properties

    It\'s a big list. Of blocks and IDs. Step one is to add your new block. Give it a name and an ID that\'s not taken. (Just go for a number higher than 350 by a large margin and you\'re 100% safe.)

    Secondly:

    You already know this because you\'ve used the test one, but I\'m going to go over the Block Editor for those who haven\'t.
    So you launch the starter. Then start the whole launcher full of settings, up there you\'ll find \"Modding\". In there select the Block Editor Tool. It\'s pretty much a no brainer from here on now. If you saved your BlockTypes.properties file right, then you should now see your new block in the dropdown list when creating a new block.

    Some notes:

    • From the texture picker in the block editor, picking the first frame of any sheet (very top left) won\'t let you press OK. You\'ll have to assign those from the block config file directly.
    • Sometimes custom blocks mess up the advanced build mode.
    • Updates tend to flush your textures. Make sure you keep a backup of your custom texture files.

    Hope I could help,
    Charlie.
     
    Joined
    Jul 9, 2013
    Messages
    23
    Reaction score
    0
    But what is the Icon ID ? Did we need it\'s the same of the given ID in properties file ?
     
    Joined
    Jun 23, 2013
    Messages
    295
    Reaction score
    0
    • Legacy Citizen 2
    • Legacy Citizen
    it\'s for the icon displayed in inventory in game. I know that right now my blocks don\'t have any.
     
    Joined
    Jul 9, 2013
    Messages
    23
    Reaction score
    0
    But how get these custom items ? the shop don\'t have any ? There is any command to give a specific ID ?
     
    Joined
    Jun 21, 2013
    Messages
    1
    Reaction score
    0
    • Legacy Citizen 2
    • Legacy Citizen
    you can use the /giveid command but its admins only...
     
    Joined
    Jul 14, 2013
    Messages
    5
    Reaction score
    0
    • Legacy Citizen 2
    • Legacy Citizen
    how do you get your own textures? i am thinking of making my own custom block but i don\'t know where the texture file is so i could copy one and remake it. could someone help?
     
    Joined
    Jul 5, 2013
    Messages
    8
    Reaction score
    0
    From what I\'ve been able to figure out, in order to add your cuustom textures, you must go to, in your starmade directory, starmade\\data\\textures\\block, open t002.png and edit a single square for your texture. So if my new block only has one texture, all you need to do is replace one pink square with your new texture. From there you open starmade, click the modding dropdown menu, and click block editor. You then go to Edit>Create New Entry. To add your custom texture, under Texture ID, click pick, then move over to the t002 tab and select your texture and hit ok.



    I hope this helps ya! Don\'t forget to follow the steps above as well, all I did was outline how to import the texture.
     
    Joined
    Jul 31, 2013
    Messages
    132
    Reaction score
    0
    But currently server can\'t \"impose\" textures to connected clients so people would have to download and install your texture file by themselves when they\'re going to your server. Or they\'d see pink block.