Modding Help Need Help: Adding items to loot tables.

Discussion in 'Starbound Modding' started by DJOkamical, Dec 8, 2013.

  1. DJOkamical

    DJOkamical Space Kumquat

    Alright, so~
    I'm trying to get a new item to drop from player grown crops:
    here's the item i'm adding:

    "itemName" : "wheatcard",
    "rarity" : "Common",
    "inventoryIcon" : "wheatcard.png",
    "dropCollision" : [-2.5, -2.0, 2.5, 2.0],
    "description" : "Card #1/37 of the Farming Set!",
    "shortdescription" : "Wheat Card"

    And here's the code I modified to the farmables file "wheatseed.item" :

    "interactionTransition" : {
    "2" : {
    "dropOptions" : [
    0.4,
    [
    {
    "name" : "wheat",
    "count" : 1
    },
    {
    "name" : "wheatseed",
    "count" : 1
    }
    ],
    [
    {
    "name" : "wheatseed",
    "count" : 1
    },
    {
    "name" : "plantfibre",
    "count" : 1
    }
    ],
    [
    {
    "name" : "wheat",
    "count" : 1
    }
    ],

    [
    {
    "name" : "wheatcard",
    "count" : 1
    }
    ]

    ],
    "command" : "die"
    }
    },
    "growing" : {
    "0" : {
    "duration" : [300, 420],
    "success" : 1,
    "failure" : 3
    },
    "1" : {
    "duration" : [300, 420],
    "success" : 2,
    "failure" : 3
    }
    },
    "stageAlts" : {
    "count" : 4,
    "2" : 5
    }
    }



    I can't seem to get my custom item to spawn, though~

    (wheatcard is in the same folder as wheat)
     
  2. DJOkamical

    DJOkamical Space Kumquat

    nvm, got it working!
     
  3. Cadz

    Cadz Void-Bound Voyager

    Would you mind telling me what you did to fix your problem?
     
  4. DJOkamical

    DJOkamical Space Kumquat

    I removed "dropCollision" : [-2.5, -2.0, 2.5, 2.0],
    and it started working, a minor error on my part.
     
    Cadz likes this.
  5. Cadz

    Cadz Void-Bound Voyager

    Thanks! So removing the dropcollision function won't completely make the item go wonky?
     
  6. DJOkamical

    DJOkamical Space Kumquat

    Apparently so!
    After removing it, the card started falling normally from wheat, as I intended.
     
  7. Cadz

    Cadz Void-Bound Voyager

    Good to know. Thanks again and good luck on your project!
     

Share This Page