How can I do oregen in minetest 4.15 ?

Sires
Member
 
Posts: 30
Joined: Mon Jan 02, 2017 21:00
In-game: Sires

How can I do oregen in minetest 4.15 ?

by Sires » Mon Jan 02, 2017 21:15

I'm trying a lot to make an ore but I don't know why, I can't.
The code that I'm using now is
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
minetest.register_ore({
   ore_type         = "scatter",
   ore              = "niceblock:niceblock",
   wherein          = "default:air",
   clust_scarcity   = 8*8*8,
   clust_num_ores   = 4,
   clust_size       = 3,
   y_min            = -300,
   y_max            = 100,
   noise_params     = {offset = 0, scale = 1, spread = {x = 100, y = 100, z = 100}, seed = 420, octaves = 3, persist = 0.7},
   noise_threshhold = 0.5,
})

But that doesn't works, I copied and pasted a lot of codes from tutorials, no one worked
AY havy gud modys: Obdy, Codeblocks
Workingi ohn: EnergyFlow
 

LordNevar
Member
 
Posts: 14
Joined: Wed Dec 14, 2016 19:46

Re: How can I do oregen in minetest 4.15 ?

by LordNevar » Tue Jan 03, 2017 06:38

i'm having the same issue.

i placed the code in the default mapgen.lua and it works. but that defeats the purpose.
 

User avatar
Krock
Member
 
Posts: 3598
Joined: Thu Oct 03, 2013 07:48
GitHub: SmallJoker

Re: How can I do oregen in minetest 4.15 ?

by Krock » Tue Jan 03, 2017 09:44

Your mod needs a file called "depends.txt" with the content "default", to make sure your mod is loaded after default. This is important because that mod clears all previously registered ores.

There's also an issue in your code:
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
   wherein          = "default:air",
should be either
   wherein          = "air",
or more likely
   wherein          = "default:stone",
Newest Win32 builds - Find a mod - All my mods
ALL YOUR DONATION ARE BELONG TO PARAMAT (Please support him and Minetest)
New DuckDuckGo !bang: !mtmod <keyword here>
 

paramat
Member
 
Posts: 2662
Joined: Sun Oct 28, 2012 00:05
GitHub: paramat

Re: How can I do oregen in minetest 4.15 ?

by paramat » Tue Jan 03, 2017 22:04

What Krock wrote.
 

Sires
Member
 
Posts: 30
Joined: Mon Jan 02, 2017 21:00
In-game: Sires

Re: How can I do oregen in minetest 4.15 ?

by Sires » Fri Jan 06, 2017 00:44

Krock wrote:Your mod needs a file called "depends.txt" with the content "default", to make sure your mod is loaded after default. This is important because that mod clears all previously registered ores.

There's also an issue in your code:
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
   wherein          = "default:air",
should be either
   wherein          = "air",
or more likely
   wherein          = "default:stone",

That worked, thx
AY havy gud modys: Obdy, Codeblocks
Workingi ohn: EnergyFlow
 


Return to Modding Discussion

Who is online

Users browsing this forum: No registered users and 5 guests

cron