for Minecraft 1.12
This is a small step-by-step guide on how to add support for most mods or other default minecraft blocks/items:
First of all, you will need to know the registry names of the items you dont want to drop and the registry names of the blocks that drop these items. You can skip this step if you already know them. To get the registry names, simply launch up minecraft and join a singleplayer world (Of course you will need to launch minecraft with the mods that provide the blocks/items you wish to add). Here you switch to the creative mode and get the items and blocks you want. To see their registry names, activate the advanced tooltips by pressing F3 + H. In order to provide an example, i will prevent the redstone lamp from dropping itself when destroyed by a player.
Here you can see that the registry name of the redstone lamp is "minecraft:redstone_lamp".
Please note that some mods (ex. forestry) have multiple different registry names for their blocks (ex. "forestry:leaves", "forestry:leaves2, "forestry:leaves3" and so on). You will need to add all of them in order to secure that the modification will work.
Now search for your mod config folder and open the directory "DeltaHardMode". Here you should find two .json files. ("dropBlocks.json" and "removedDrops.json") If you dont find these two files, make sure you are viewing the right directory and launch minecraft with Delta Hard Mode once.
Now add the blocks you dont want to drop certain items. To do so, open the dropBlocks.json file with any text editor. It should look like this:
Insert the registry names of the blocks you dont want to drop certain items. Dont forget to add a comma after every but the last name. (ex. "minecraft:redstone_lamp")
Now add the items that should not be dropped. To do so, open the removedDrops.json file with any text editor. It should look like this:
Insert the registry names of the items you dont want to drop. Dont forget to add a comma after every but the last name. (ex. "minecraft:redstone_lamp" as well since the redstone lamp drops itself)