forked from mtcontrib/farming
seed drops from short grass more rare (thx skaapdev)
This commit is contained in:
parent
37ea21fdaf
commit
e33dd0e275
10
grass.lua
10
grass.lua
@ -1,6 +1,8 @@
|
||||
|
||||
-- Override grasses to drop seeds
|
||||
|
||||
local rarity_lookup = {[1] = 50, [2] = 50, [3] = 50, [4] = 5, [5] = 5}
|
||||
|
||||
if minetest.registered_nodes["default:grass_1"] then
|
||||
|
||||
for i = 1, 5 do
|
||||
@ -9,8 +11,8 @@ if minetest.registered_nodes["default:grass_1"] then
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"farming:seed_wheat"}, rarity = 5},
|
||||
{items = {"farming:seed_oat"},rarity = 5},
|
||||
{items = {"farming:seed_wheat"}, rarity = rarity_lookup[i]},
|
||||
{items = {"farming:seed_oat"},rarity = rarity_lookup[i]},
|
||||
{items = {"default:grass_1"}}
|
||||
}
|
||||
}
|
||||
@ -26,8 +28,8 @@ if minetest.registered_nodes["default:dry_grass_1"] then
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"farming:seed_barley"}, rarity = 5},
|
||||
{items = {"farming:seed_rye"}, rarity = 5},
|
||||
{items = {"farming:seed_barley"}, rarity = rarity_lookup[i]},
|
||||
{items = {"farming:seed_rye"}, rarity = rarity_lookup[i]},
|
||||
{items = {"default:dry_grass_1"}}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user