Time |
Nick |
Message |
00:49 |
Exio |
that with a hunger game |
00:49 |
Exio |
s/game/mod |
01:25 |
khonkhortisan |
canyons, rivers, lakes, mountains, caves with rivers, islands/ocean as opposed to lakes, all these we should have |
01:36 |
Exio |
there are ravines |
01:37 |
NakedFury |
we also need ravines or fissures or rifts that lead very deep underground |
01:51 |
hmmmm |
the ravines aren't as long as i thought they'd be so i'm thinking maybe i should do it like minecraft does |
01:51 |
VanessaE |
how's tht? |
01:51 |
VanessaE |
that* |
01:52 |
hmmmm |
a random walk |
01:52 |
VanessaE |
actually that's how I'd do it. |
01:52 |
VanessaE |
if you're thinking like I am anyway. |
01:54 |
VanessaE |
plot line between two points, random walk along that line twice, then erase everything between the two walked paths. |
01:54 |
VanessaE |
perlin noise or something similar to set the floor elevation. |
01:56 |
hmmmm |
how would you randomly walk along a line? |
01:57 |
hmmmm |
agh, looks like l_register_biome_groups() is back since the scriptapi split... i should check so that it isn't using an outdated version of l_register_biome() |
01:57 |
VanessaE |
start from point "A", pick a random number between -45 and +45, walk say 2-3 nodes in that direction, relative to the line. Repeat until you get to the end of the line. |
01:57 |
VanessaE |
that way your path always follows the line but looks quite natural in width |
01:58 |
hmmmm |
ah |
01:58 |
hmmmm |
yeah, that's probably better than totally random |
01:59 |
VanessaE |
in theory, longer runs of nodes between random numbers would be faster, at the expense of smoothness. |
02:00 |
VanessaE |
hm, you'll need two layers of perlin to sculpt the inside of the chasm - one for the floor elevation, and another to manage the vertical tapering of the walls |
02:00 |
VanessaE |
(so you have outcroppings, etc) |
02:03 |
VanessaE |
you might want to also consider a "lightning bolt" algorithm to get the initial line along which to walk |
02:04 |
hmmmm |
hmm |
02:04 |
VanessaE |
(which would probably just be another path, but with a narrower degree range) |
02:04 |
hmmmm |
lightning bolt would also be useful for rivers |
02:04 |
VanessaE |
*nod* |
02:04 |
VanessaE |
(..with a narrower degree range and a much longer step between turns, say 20 nodes or so) |
02:05 |
hmmmm |
sorta wondering if i should commit the simple decoration type without the cutoff handling |
02:05 |
hmmmm |
and i'll add that in a later commit |
02:06 |
VanessaE |
probably couldn't hurt - it's not like v7 is ready for general use yet anyway |
02:06 |
VanessaE |
so you don't need to worry too much about breaking maps yet :) |
02:15 |
hmmmm |
hrmmm |
02:15 |
hmmmm |
my new plan makes a dent in the code i already had |
02:15 |
hmmmm |
can't believe i wrote all this without realizing that it wouldn't work |
02:19 |
|
sweetbomber joined #minetest-dev |
02:19 |
sweetbomber |
hello guys |
02:20 |
sweetbomber |
hmmmm: do you have any experimental structure-generation code? so that i can skip that part on my algorithm? |
02:21 |
hmmmm |
erm, not yet |
02:21 |
hmmmm |
that's what i'm continuing on actually |
02:21 |
sweetbomber |
by structure generation, i mean the part that defines the structure itself |
02:21 |
hmmmm |
i haven't done minetest anything for a while |
02:21 |
hmmmm |
err, http://pastebin.com/J96s5dPQ |
02:21 |
sweetbomber |
what do you have in mind to define complex structures ? C++ or lua? |
02:21 |
hmmmm |
this |
02:22 |
hmmmm |
the lua api for this, you just pass the filename of the schematic |
02:23 |
hmmmm |
to create the schematic file, i'm thinking that i should have a command in minetest to do this; mark two points, then save it, mask out certain kinds of nodes for having different probabilities or whatever |
02:23 |
sweetbomber |
ok, so i have freedom to create the structure model from scratch |
02:24 |
sweetbomber |
do you mind if i redesign it? |
02:24 |
hmmmm |
kinda yes |
02:24 |
sweetbomber |
ok, just another thing |
02:24 |
hmmmm |
there are specific reasons for everything in there |
02:24 |
sweetbomber |
just installed an IDE |
02:24 |
sweetbomber |
(i only used terminal and vim so far till now) |
02:24 |
hmmmm |
from what i understand, you want to be able to paste certain parts of the structure together |
02:25 |
sweetbomber |
(qt-creator, quite impressive IDE. if you havent tried, i recommend giving a try) |
02:25 |
hmmmm |
if you want to do that, then i guess it could be in the probability field |
02:25 |
sweetbomber |
(and quite light, 60mb) |
02:25 |
hmmmm |
add a flag on the highest bit |
02:25 |
hmmmm |
or something |
02:26 |
hmmmm |
i use codeblocks which is pretty good |
02:26 |
sweetbomber |
im thinking of an hierarchy |
02:26 |
hmmmm |
you see, the thing is |
02:27 |
hmmmm |
this schematic format was made for things that don't have multiple segments |
02:27 |
hmmmm |
sure, it's pretty static.... |
02:27 |
hmmmm |
but it's what works for things such as trees |
02:28 |
kahrl |
there should probably be two lua APIs for this, one in the environment and another for voxelmanipulators |
02:29 |
hmmmm |
sweetbomber, if your variation of the schematic format is significantly different (which i think it might be) don't forget that we can just add it as a separate decoration type |
02:30 |
hmmmm |
i don't think it'd be a good idea to have one format that tries to do it all and ends up not being so simple and lightweight anymore |
02:30 |
sweetbomber |
i think that the best way to make structure scripting more efficient would be the following: lua registers structures (like is doing with biomes) and then is no longer executed |
02:30 |
sweetbomber |
ill make an efficient algorightm |
02:30 |
sweetbomber |
btw, regarding efficiency |
02:30 |
sweetbomber |
i profiled minetest |
02:30 |
sweetbomber |
and found out a cancer |
02:30 |
hmmmm |
that is how decoration registration is done anyway, yes... |
02:31 |
hmmmm |
what is it, find_nodes_in_area()? |
02:31 |
sweetbomber |
why is getTextureId using strings? |
02:31 |
sweetbomber |
it consumes about all cpu |
02:31 |
hmmmm |
really? |
02:31 |
sweetbomber |
(ok, not so much, but a really lot!) |
02:32 |
sweetbomber |
the number of calls to strcmp is astonishing |
02:32 |
hmmmm |
yeah, if it were up to me, that'd be a hashtable |
02:33 |
kahrl |
doesn't it use a std::map<std::string, int>? |
02:34 |
kahrl |
so that's a logarithmic number of strcmp calls |
02:34 |
sweetbomber |
yes it does |
02:35 |
hmmmm |
logarithmic is still a lot when you have like 500 textures, and it's being called like every millisecond |
02:35 |
kahrl |
is it? |
02:35 |
hmmmm |
well |
02:35 |
kahrl |
ah, for the animated textures I guess |
02:35 |
hmmmm |
it's clearly enough to make it stand out from a profiler's perspective |
02:35 |
kahrl |
and the hotbar and inventory images |
02:35 |
sweetbomber |
i think that the textures must be all loaded at the start |
02:35 |
kahrl |
sweetbomber: of course they are |
02:36 |
sweetbomber |
i mean, the "string parsing" part |
02:36 |
sweetbomber |
it is too human friendly in a section that requires performance |
02:36 |
hmmmm |
the slowness of string parsing is downplayed throughout minetest |
02:36 |
hmmmm |
it's like that for settings as well |
02:37 |
sweetbomber |
anyway, i confess my profiling was quite superficial |
02:37 |
sweetbomber |
ill try it with a game |
02:37 |
VanessaE |
500 textures? pfft. try 4000+ :D |
02:37 |
sweetbomber |
like vanessa's |
02:37 |
sweetbomber |
which has loads of stuff to try |
02:38 |
Exio |
4000? you missed some blocks have more than one textures |
02:38 |
Exio |
s/s$// |
02:38 |
Exio |
i would say "6000+" |
02:38 |
Exio |
:P |
02:39 |
VanessaE |
Exio: I was counting just what's in HDX. my game has 3319 textures. |
02:39 |
Exio |
ah |
02:41 |
sweetbomber |
im reprofiling it now |
02:43 |
VanessaE |
hmmmm: are you sure that all of the textures are being walked through at that rate? That can't be right... |
02:44 |
hmmmm |
huh? |
02:44 |
VanessaE |
[06-13 22:35] <hmmmm> logarithmic is still a lot when you have like 500 textures, and it's being called like every millisecond |
02:44 |
VanessaE |
am I reading that wrong? |
02:44 |
hmmmm |
oh definitely |
02:44 |
hmmmm |
getTextureSource is used constantly in the main game loop |
02:44 |
VanessaE |
eek |
02:45 |
VanessaE |
and it's doing a bunch of str comparisons for each file!? |
02:45 |
VanessaE |
s/file/image/ |
02:46 |
hmmmm |
haha you seem to think minetest is efficient or something |
02:46 |
VanessaE |
that's... |
02:46 |
VanessaE |
um... *head explodes* |
02:52 |
|
dexter0 joined #minetest-dev |
03:11 |
sweetbomber |
definitely..that function is a cancer |
03:12 |
sweetbomber |
in 5 min gameplay, it was called a few billion times |
03:12 |
sweetbomber |
(american billion) |
03:12 |
VanessaE |
is that while running my game? |
03:12 |
sweetbomber |
no, i re-profiled with minimal |
03:12 |
VanessaE |
shit on a shingle |
03:13 |
sweetbomber |
(it is really slow to profile) |
03:15 |
VanessaE |
dare I ask you to profile my game? |
03:18 |
sweetbomber |
no prob |
03:20 |
khonkhortisan |
How can I get in on the profiling bandwagon? |
03:21 |
sweetbomber |
im using valgrind |
03:21 |
khonkhortisan |
I didn't know that profiled |
03:21 |
sweetbomber |
(linux) |
03:25 |
khonkhortisan |
I always used the default memcheck |
03:25 |
sweetbomber |
lol, my pc is starting to melt...the game is taking a lot to start with the profiler on :p |
03:25 |
VanessaE |
lol |
03:26 |
sweetbomber |
i guess ill leave it on overnight |
03:26 |
sweetbomber |
to make this startup time negligible |
03:27 |
sweetbomber |
otherwise it will be biased by loading-time functions |
03:27 |
sweetbomber |
tomorrow ill post the results |
03:28 |
sweetbomber |
omg, still on "media" loading phase |
03:28 |
Exio |
sweetbomber: what cpu do you have? |
03:29 |
sweetbomber |
not sure about the mode, let me check on my laptop's specs |
03:29 |
sweetbomber |
*model |
03:29 |
sweetbomber |
but its a 2.4ghz dualcore 64bit |
03:29 |
VanessaE |
hmmmm: I just did an interesting test, 60 fps (166k verticies) at a view range of 50, with that same map, but *no mods* (not even default) such that everything everywhere is unknown node. |
03:30 |
VanessaE |
256px texture(s; not like it's using more than the one) |
03:31 |
Exio |
sweetbomber: what is the time compiling mt from scratch? :P |
03:32 |
sweetbomber |
not much |
03:32 |
sweetbomber |
cant be very precise |
03:32 |
sweetbomber |
i can stop profiling to measure |
03:32 |
khonkhortisan |
skill -STOP |
03:33 |
khonkhortisan |
skill -CONT |
03:33 |
sweetbomber |
but if you are asking that to know if minecraft is slow in my machine, it isnt |
03:33 |
sweetbomber |
usually loading of vanessa's game takes a few seconds |
03:33 |
sweetbomber |
but the profiler stretches the execution time a lot |
03:33 |
khonkhortisan |
it takes longer the larger your images are |
03:34 |
VanessaE |
khonkhortisan: I expect he's doing this entirely with the default textures. |
03:34 |
khonkhortisan |
I don't think I can make my font small enough to see the complete server list |
03:34 |
hmmmm |
hmmm |
03:34 |
sweetbomber |
i'm using vanessa's game without any change |
03:35 |
Exio |
hmmm saying hmmm is not a good thing |
03:35 |
hmmmm |
i really have to get my butt in gear |
03:35 |
* khonkhortisan |
didn't make the connection |
03:35 |
hmmmm |
so many things need fixing |
03:37 |
VanessaE |
hmmmm: even in this completely stripped-down test, and *default* texture(s), I can't even maintain 60 fps with the full immediate map area loaded. |
03:39 |
VanessaE |
(seems to want to float around 55 fps) |
03:39 |
Exio |
don't tell that to hmmmm or he will rewrite the ClientMap::draw() |
03:39 |
VanessaE |
too late :P |
03:39 |
Exio |
aw |
03:39 |
khonkhortisan |
Invalid read of size 8 |
03:39 |
khonkhortisan |
I'll try a diversion |
03:44 |
sweetbomber |
khonkhortisan: yes, I saw some memory warnings too...maybe those need some inspection too... |
03:44 |
hmmmm |
trying to think of *when* the cut-off items should be placed |
03:48 |
* sweetbomber |
makes some noodles |
03:48 |
hmmmm |
if it goes in a mapgen thread, then it'd slow down map generation and blocks would take a bit longer |
03:48 |
sweetbomber |
instant noodles: solving 1st world hunger since 1970 |
03:48 |
khonkhortisan |
ramen? macaroni? hamburger helper? spaghetti? |
03:48 |
khonkhortisan |
ah. |
03:48 |
VanessaE |
ramen, of course. |
03:48 |
sweetbomber |
yup |
03:48 |
sweetbomber |
chicken |
03:49 |
hmmmm |
if it goes in its own thread, then one might block the other and i'd need to resend blocks |
03:49 |
hmmmm |
but i'd have to resend blocks anyway |
03:49 |
sweetbomber |
love ramen, altough it is more expensive than a beef |
03:49 |
VanessaE |
hmmmm: how heavy do you suppose the routine's gonna be? |
03:49 |
hmmmm |
with your goddamn trees probably really heavy |
03:49 |
sweetbomber |
(it costs less than one euro, but only has a few grams) |
03:49 |
VanessaE |
lol |
03:50 |
khonkhortisan |
alol |
03:50 |
hmmmm |
the logic is different enough to not be part of the emerging process |
03:50 |
hmmmm |
plus it's better from an organizational standpoint to not be in emerge thread |
03:50 |
VanessaE |
sweetbomber: recipe idea: crush noodles, add a 12oz can of chicken with the water/schmaltz. Top up with water as needed. Boil until they cry. drain. Add sour cream and the flavor packet. Prepare toorgasm. |
03:51 |
hmmmm |
can of chicken, good joke |
03:51 |
VanessaE |
hmmmm: well if it's expected to be heavy in practice, definitely in its own thread. |
03:51 |
VanessaE |
canned chicken is cheap and convenient. |
03:51 |
sweetbomber |
VanessaE: lol, ill try that for a meal |
03:51 |
hmmmm |
hmm |
03:51 |
hmmmm |
let's think rationally here |
03:51 |
sweetbomber |
now its just pre-bed eating |
03:52 |
sweetbomber |
(5am here= |
03:52 |
hmmmm |
what if we have a 3-block-tall tree |
03:52 |
VanessaE |
yeah? |
03:52 |
VanessaE |
not uncommon in fact. |
03:52 |
hmmmm |
that gets cut off because it starts to generate at 4 blocks high in the chunk |
03:52 |
hmmmm |
so only 1 additional block would be emerged that hadn't been emerged before |
03:53 |
khonkhortisan |
9 leaves |
03:53 |
hmmmm |
but in this case if i had it in its own thread, that's 2 blocks getting resent |
03:53 |
hmmmm |
that didn't really need to be |
03:53 |
VanessaE |
khonkhortisan: he means mapblocks e.g. something like a giant sequoia. |
03:53 |
VanessaE |
hmmmm: hrm, right. |
03:53 |
hmmmm |
now what if we had a massive, massive structure that's like 25 blocks |
03:54 |
hmmmm |
err more |
03:54 |
VanessaE |
simple, your server would melt. |
03:54 |
hmmmm |
the cutoff happens because it's too vertically high |
03:54 |
VanessaE |
hm. |
03:54 |
hmmmm |
that much is fine, but then all those lower chunks would get sent as well |
03:54 |
hmmmm |
so |
03:54 |
hmmmm |
would you personally rather see the map appear, and then the trees appear a short moment after? |
03:54 |
VanessaE |
absol-fucking-lutely. |
03:55 |
khonkhortisan |
I know I would |
03:55 |
khonkhortisan |
better than the trees appearing first :) |
03:55 |
VanessaE |
we're already used to trees et.al suddenly popping up anyway e.g. when a sapling grows |
03:55 |
khonkhortisan |
I tell my web browser to display as much as it can while loading |
03:55 |
VanessaE |
or the old jungle trees mod |
03:56 |
hmmmm |
here's the problem; when on_generate gets called, you won't see the tree that got added |
03:56 |
VanessaE |
good point. |
03:56 |
hmmmm |
what's worse is that the trees won't get added to the cutoff queue if they fit |
03:56 |
VanessaE |
could there be a flag included that tells the client to expect this block to change soon? |
03:56 |
hmmmm |
so the behavior would be inconsistent, that is, you can't rely on them being there or not being there |
03:56 |
hmmmm |
eh, not really a problem with the client |
03:56 |
VanessaE |
or rather, |
03:56 |
VanessaE |
not the client |
03:56 |
VanessaE |
the mods |
03:57 |
VanessaE |
(brain-o) |
03:57 |
hmmmm |
there could |
03:57 |
khonkhortisan |
could delay on_generated, but send the map as it's created |
03:57 |
hmmmm |
i'd rather not delay on_generated |
03:59 |
hmmmm |
nevermind about the inconsistency part |
03:59 |
kahrl |
imo the generated world should depend solely on the seed |
04:00 |
hmmmm |
it's going to be inconsistent any way you put it |
04:00 |
kahrl |
not in what order the blocks are approached |
04:00 |
sweetbomber |
hmmmm: only now read your toughts |
04:00 |
hmmmm |
kahrl, already too late, the trees get generated randomly each time the map is created, someone used the global rand function |
04:00 |
sweetbomber |
my structure generation approach will generate cutoff structures on main mapgen thread |
04:01 |
kahrl |
hmmmm, that should be fixed in new mapgens then |
04:01 |
sweetbomber |
and my algorithm will generate exactly the same structures whatever the block-generation order |
04:01 |
sweetbomber |
(that was one pre-requesite of myself) |
04:01 |
hmmmm |
kahrl, it's fixed by the design of the new mapgen |
04:01 |
hmmmm |
sweetbomber, you gave up on the perlin noise thing? |
04:02 |
sweetbomber |
nope |
04:02 |
sweetbomber |
ill use it |
04:02 |
hmmmm |
i thought your idea was to not deal with cutoff structures separately |
04:03 |
sweetbomber |
my idea is to make possible to know if a given block contains a structure, without pre-generating other blocks |
04:03 |
hmmmm |
oh |
04:03 |
hmmmm |
we misunderstood eachother when we first talked about this, then |
04:03 |
hmmmm |
i didn't mean pre-generating, i meant pre-calculating |
04:03 |
sweetbomber |
or that |
04:04 |
hmmmm |
(as in, running through all the steps one would have to take first) |
04:04 |
sweetbomber |
as a consequence, it is not needed to take care of cutoff structures separately |
04:04 |
hmmmm |
yeah |
04:04 |
hmmmm |
so when you said "on the main mapgen thread", what did you mean |
04:04 |
sweetbomber |
imagine like those scratch lottery cards |
04:05 |
hmmmm |
do you mean "in the mapgen"? |
04:05 |
hmmmm |
or do you mean done in the EmergeThread |
04:05 |
kahrl |
is there a document that describes the current algorithm and ideas for avoiding cutoff? |
04:05 |
hmmmm |
because what i was suggesting is done in the EmergeThread, separately from the mapgen |
04:05 |
kahrl |
I can't follow this discussion |
04:05 |
hmmmm |
kahrl, there is not, sorry |
04:06 |
hmmmm |
i'll write something up though, maybe i'll come up with an idea |
04:06 |
sweetbomber |
sorry, i meant emerge thread |
04:06 |
sweetbomber |
the code that emerges one block at a time |
04:06 |
hmmmm |
sweetbomber, you're also aware that there can be multiple emergethreads, right? |
04:06 |
sweetbomber |
the good thing about this solution, is that *maybe* it will avoid the use of mutexes/locks |
04:07 |
hmmmm |
so when you say "main mapgen thread", what i imagine you mean is "in EmergeThread #0, outside of mapgen::makeChunk" |
04:07 |
sweetbomber |
i have not thought troughout this very deeply |
04:07 |
sweetbomber |
wait a sec, let-me revisit the code (ive been out for a week) |
04:07 |
hmmmm |
heh, i've been out for a month |
04:08 |
sweetbomber |
im talking about makechunk |
04:09 |
hmmmm |
in makechunk |
04:09 |
hmmmm |
makes more sense now |
04:09 |
sweetbomber |
the elementary unit of generation, for what i understood |
04:09 |
sweetbomber |
and my algorithm allows it to be local |
04:09 |
sweetbomber |
without the need of caching stuff for other chunks, etc... |
04:10 |
sweetbomber |
each chunk knows exactly what to do |
04:10 |
hmmmm |
right |
04:10 |
sweetbomber |
and when it is generated, no more changes will have to be done there |
04:10 |
hmmmm |
okay, just making sure, because you said something that made me think you meant otherwise for some reason |
04:10 |
sweetbomber |
there will be some light pre-calculation |
04:10 |
sweetbomber |
but no caching |
04:11 |
sweetbomber |
or whatsoever |
04:11 |
sweetbomber |
and that will rely on the structure binary-storage format ill think of |
04:13 |
sweetbomber |
plus a method i tested to obtain a seed for each structure, that can be calculated even from different chunks that happen to include parts of the same structure |
04:13 |
sweetbomber |
and i think this is the main point |
04:13 |
hmmmm |
global structure seed |
04:13 |
hmmmm |
how does that even work? |
04:13 |
sweetbomber |
each instance of structure will have the same seed |
04:14 |
hmmmm |
isn't that basically what already happens? |
04:14 |
sweetbomber |
(this is a requirement to guarantee that the structure is generated the same way, no matter the generation order) |
04:14 |
hmmmm |
i do that in Ore::generate(), where i pas along blockseed + i |
04:15 |
sweetbomber |
the thing is, imagine a bridge that goes over 3 chunks |
04:15 |
sweetbomber |
the seed for the bridge in chunk 1 must be the same of the one in chunk 3 |
04:16 |
hmmmm |
clearly, yes, but how does that determine its placement exactly? |
04:16 |
sweetbomber |
if it changes with the block or with the chunk, its is not possible to guarantee that the structure will be coherent |
04:17 |
sweetbomber |
imagine local noise |
04:17 |
sweetbomber |
(by local, i mean that the seed is calculated based on each cell's coordinate) |
04:17 |
hmmmm |
oh that |
04:18 |
sweetbomber |
now, if the cell's random value is above a certain threshold, it means that it will have a structure |
04:19 |
sweetbomber |
to get the structure's seed, calculate the area of adjacent cells with a random value above the threshold (btw, this threshold is structure-dependent) |
04:20 |
sweetbomber |
then, after getting the seed, run a lightweight size-precalculation of the structure, taking as constraint that only those cells whose value is above the threshold may hold the structure |
04:21 |
sweetbomber |
(if the algorithm wants to place a house that would go to a chunk which had a value lower than the threshold, it does not place it at all |
04:21 |
sweetbomber |
so that there will be no structures "incomplete" |
04:21 |
sweetbomber |
) |
04:22 |
sweetbomber |
basically its this |
04:22 |
sweetbomber |
but has some quirks |
04:23 |
sweetbomber |
and other details, namely regarding scale, positioning, and repetition |
04:24 |
sweetbomber |
of structures along the world |
04:24 |
sweetbomber |
i really have to go now |
04:24 |
hmmmm |
for (z, ... for (y, ... for (x, ... ) { if (noise2d(x, z, deco->seed) > deco->thresh_placement && NoisePerlin2D(deco->np, x, z, deco->seed) > deco->tresh_area && (there's no other structures in the way)) { placeWhatever(); |
04:25 |
hmmmm |
and that would need to be run throughout a larger area |
04:25 |
hmmmm |
how large, not sure |
04:25 |
sweetbomber |
ill give news as soon as i have something |
04:25 |
sweetbomber |
that is the scale thing |
04:25 |
sweetbomber |
basically, +- like octaves in perlin noise |
04:25 |
sweetbomber |
imagine using different noise scales |
04:25 |
hmmmm |
i should hold off on what i have perhaps, for this |
04:25 |
sweetbomber |
btw, i dont want perlin noise for this |
04:25 |
hmmmm |
it might work out |
04:26 |
hmmmm |
yes, but we need perlin noise to restrict placement to spots like we currently have with trees and what not |
04:26 |
sweetbomber |
just regular non-interpolated noise |
04:26 |
hmmmm |
the non-interpolated noise is used for determining "is this spot a candidate for placement?" |
04:26 |
sweetbomber |
yes |
04:26 |
sweetbomber |
it makes things simpler |
04:26 |
hmmmm |
and then the perlin noise says "okay, so is this position in the right area?" |
04:27 |
hmmmm |
and vary treshhold based on the perlin noise result |
04:27 |
hmmmm |
ah |
04:27 |
hmmmm |
there's a simple way to make forests more dense in one area and then fade out |
04:27 |
sweetbomber |
well, im planning to use terain height and biome-type to assess if a structure could be placed |
04:27 |
sweetbomber |
so it will use, indirectly, perlin noise |
04:28 |
sweetbomber |
but i think that regular random noise is enough for structure placement |
04:28 |
hmmmm |
have you taken a look at ore placement? |
04:30 |
sweetbomber |
for what i saw it just used local random noise |
04:30 |
sweetbomber |
and uses its height as threshold |
04:30 |
sweetbomber |
but i have not looked deeply into it |
04:31 |
sweetbomber |
ill take a look tomorrow |
04:31 |
sweetbomber |
sorry, i really have to sleep |
04:31 |
sweetbomber |
good night |
04:31 |
sweetbomber |
ill check logs tomorrow |
04:32 |
Exio |
good night sweetbomber! |
04:42 |
|
neko259 joined #minetest-dev |
05:24 |
|
smoke_fumus joined #minetest-dev |
06:54 |
|
neko259 joined #minetest-dev |
06:56 |
|
ssieb joined #minetest-dev |
07:15 |
|
darkrose joined #minetest-dev |
07:15 |
|
darkrose joined #minetest-dev |
07:40 |
|
ecube joined #minetest-dev |
09:22 |
|
darkrose joined #minetest-dev |
09:22 |
|
darkrose joined #minetest-dev |
10:18 |
|
PilzAdam joined #minetest-dev |
10:35 |
|
proller joined #minetest-dev |
11:12 |
|
PilzAdam joined #minetest-dev |
11:32 |
|
iqualfragile joined #minetest-dev |
11:49 |
|
EdB joined #minetest-dev |
12:02 |
Taoki |
Anyone know if there's a Lua function to *loop* a spatial sound on the player (asking here as it's for a patch I plan to make) |
12:03 |
PilzAdam |
only sounds attached to objects can be looped, so you need to attach it to the player |
12:03 |
Taoki |
Sounds great |
12:08 |
PilzAdam |
https://github.com/minetest/minetest/pull/773 |
12:08 |
|
]||[ joined #minetest-dev |
12:10 |
Taoki |
Sure, such a Lua function should exist (modders might want to make ghost objects on purpose) |
12:10 |
Taoki |
And I can confirm it was glitchy on falling nodes. I got stuck nunder them with no way to dig myself out |
12:13 |
Taoki |
I wonder if there's any way to make a Lua function that applies a change to all entities (such as players and dropped items) |
12:32 |
Taoki |
Anyone know how that can be done? I'd like to add a Lua effect / function to all entities, including players / lua entities / dropped items. Is that possible with one function? |
12:40 |
PilzAdam |
yes, just loop through all registered entities and redefine them |
12:40 |
|
EdB joined #minetest-dev |
13:09 |
|
proller_ joined #minetest-dev |
13:10 |
|
drizz joined #minetest-dev |
13:51 |
|
serengeor joined #minetest-dev |
13:54 |
|
proller_ joined #minetest-dev |
13:54 |
|
jojoa1997 joined #minetest-dev |
14:10 |
|
hmmmm joined #minetest-dev |
14:16 |
Taoki |
hmmmm: Couldn't help it and giving a try to v7. The layout seems nice and ok, but it only generates smooth stone with water. Is it because the biome script isn't included, or is it all it can do at this point yet? |
14:18 |
PilzAdam |
Taoki, http://pastebin.com/xwmCD3ae |
14:19 |
Taoki |
Thought it's included, will try now |
14:21 |
jojoa1997 |
so howcome that code isnt added yet |
14:22 |
PilzAdam |
mg v7 shouldnt be used yet |
14:22 |
Taoki |
PilzAdam: 17:19:57: ERROR[main]: BiomeDefManager::resolveNodeNames: node '' not defined |
14:23 |
Taoki |
Get several of these\ |
14:23 |
* Taoki |
thinks that script should be added. If V7 shouldn't be used we can add a warning. |
14:24 |
Taoki |
I'll use it either way if it just works and doesn't crash anything, since I'm ok with my local worlds running experimental parts |
14:27 |
Taoki |
Anyway, is that an error or a problem with the script? |
14:27 |
hmmmm |
taoki, i'd really prefer if you didn't use v7 |
14:28 |
Taoki |
It's like using it before it's ready = looking at porn :P |
14:28 |
Taoki |
Can't say I'm using it, just made a test world for a simple test |
14:29 |
Taoki |
Anyway, that error indicates it might be broken, so hopefully I helped find a bug at least |
14:32 |
Taoki |
Also, it seems to be a bit faster than indev at generating. Though that might be because it doesn't create trees |
14:37 |
Taoki |
BBL |
14:43 |
|
ImQ009 joined #minetest-dev |
14:46 |
hmmmm |
you can't notice any difference in generation speed past a certain point because it's bottlenecked by block sending and mesh making |
14:55 |
|
NakedFury joined #minetest-dev |
14:57 |
|
Jordach joined #minetest-dev |
14:57 |
|
Jordach joined #minetest-dev |
15:01 |
hmmmm |
was going to do something last night but sweetbomber's thing keeps looking more and more appealing (for cut-off cases anyway) |
15:02 |
hmmmm |
it will consume notably more cpu than the traditional way of randomly generating decorations though |
15:04 |
hmmmm |
when there's a situation like this, we always make it an option so nothing needs to suffer.. i guess it'd be a good idea for things that aren't likely to be cut off (regular sized trees, single node decorations, etc) to use the regular method, and only structures and other things large enough will use that other method |
15:04 |
|
Calinou joined #minetest-dev |
15:06 |
hmmmm |
i'm not sure if i want to make it a separate placement type, because then people would have to judge on their own which kind is appropriate for their structure... i'd like to have it auto-switch based on size maybe |
15:07 |
NakedFury |
hi |
15:08 |
hmmmm |
the reason why keeping the old method is possible is because i don't think we have any plans to remove the chunk borders from generation, unless someone finds a way to fix caves (which is much harder) |
15:09 |
hmmmm |
there are advantages to removing the borders too, like having to only retrieve and blit back a 5x5x5 area instead of a 7x7x7 |
15:09 |
hmmmm |
lighting calculations would be completely errorless too |
15:10 |
hmmmm |
(well; errorless apart from having to guess if there's an overtop or not, but i'd rather manually retrieve those blocks when we actually need them) |
15:11 |
hmmmm |
removing chunk borders would implicitly fix the entire class of bugs that includes caved-out trees, walled-in caves, dungeons floating in the air, and so on |
15:19 |
|
proller joined #minetest-dev |
15:20 |
|
Zeg9 joined #minetest-dev |
15:27 |
|
salamanderrake joined #minetest-dev |
15:41 |
|
rubenwardy joined #minetest-dev |
15:44 |
|
Zeg9 joined #minetest-dev |
15:53 |
|
zweipktf1t joined #minetest-dev |
15:53 |
|
drizz_ joined #minetest-dev |
15:57 |
|
Jordach joined #minetest-dev |
16:24 |
|
sapier joined #minetest-dev |
16:42 |
|
sweetbomber joined #minetest-dev |
16:54 |
|
Calinou joined #minetest-dev |
17:02 |
|
RealBadAngel joined #minetest-dev |
17:02 |
|
sweetbomber joined #minetest-dev |
17:03 |
|
neko259 joined #minetest-dev |
17:03 |
RealBadAngel |
hi |
17:03 |
RealBadAngel |
whats up? |
17:09 |
|
proller joined #minetest-dev |
17:10 |
Exio |
hey RealBadAngel! |
17:16 |
RealBadAngel |
i just got new connectiion (LTE) |
17:20 |
RealBadAngel |
im not sure if i gonna keep it (got 1 week for testing). i have a feeling that cable one was faster |
17:26 |
RealBadAngel |
anyway its good to be connected again ;) |
17:26 |
Jordach |
RealBadAngel, if this is a 3G modem |
17:26 |
Jordach |
then a cable is much better |
17:27 |
Jordach |
and i know most ISPs provide broadband |
17:28 |
RealBadAngel |
its not cable nor 3G, its LTE |
17:28 |
PilzAdam |
-> #minetest |
17:28 |
RealBadAngel |
sure ;) hi PilzAdam |
17:29 |
PilzAdam |
hey RealBadAngel |
17:29 |
RealBadAngel |
i have heard your voice and im creating different game |
17:30 |
RealBadAngel |
i had 2 weeks to think it over and i like it |
17:32 |
RealBadAngel |
i made already all the formspecs to follow UI's style |
17:34 |
RealBadAngel |
so i guess i wont be fighting you anymore |
17:34 |
Taoki |
RealBadAngel: Hi, WB :) |
17:35 |
RealBadAngel |
im gonna stick to my own version of minetest_game |
17:35 |
RealBadAngel |
hi Taoki |
17:35 |
Taoki |
How are you? |
17:36 |
RealBadAngel |
happy to be connected again and a bit tired (working hard all the time) |
17:36 |
Taoki |
nice |
17:36 |
Taoki |
I heard you're working on adding hardware lighting. Is that true? I was curious how far you got with the code |
17:37 |
RealBadAngel |
i had a pause last 2 weeks |
17:38 |
Taoki |
oh, ok |
17:38 |
RealBadAngel |
i got sun/moon math ready |
17:38 |
Taoki |
RealBadAngel: http://forum.minetest.net/viewtopic.php?pid=94508#p94508 I posted an idea here which you might find useful and interesting (my planning for the lighting code) |
17:38 |
RealBadAngel |
i implemented fiatlux.py lib |
17:40 |
RealBadAngel |
my shaders work is hanging waitin for lights |
17:41 |
RealBadAngel |
because all the parts needs the light |
17:41 |
Taoki |
Awesome. The lights are indeed the thing |
17:41 |
RealBadAngel |
i managed to get bump mapping working to some point without real lights but thats all |
17:42 |
RealBadAngel |
every shader needs real light sources |
17:42 |
Taoki |
Awesome! Bump mapping is one of the features I'd love to see |
17:43 |
Taoki |
And that's correct. I tried adding some effects too, and all need lighting |
17:43 |
RealBadAngel |
the code for bump mapping is uploaded in my branch for weeks already |
17:44 |
RealBadAngel |
there are at least 3 texture packs that support it |
17:44 |
RealBadAngel |
Haven, HDX and Sphax's |
17:44 |
Taoki |
Nice. I'm afraid to ask if it will be accepted though (cuz I can already tell that might be "no" :P ) |
17:45 |
RealBadAngel |
bump mapping works NICE without lighting |
17:45 |
Taoki |
RealBadAngel: Another one that should work without lighting are envmap reflections. Would be awesome for metal surfaces and especially water |
17:46 |
Taoki |
RealBadAngel: Is it bump mapping however, or bump + parallax mapping |
17:46 |
RealBadAngel |
i know, my code does both effects |
17:46 |
Taoki |
Awesome :D |
17:46 |
RealBadAngel |
but without lights there are set up to one level |
17:47 |
Taoki |
I know. When lighting will be in they'll probably have to be adapted |
17:47 |
Taoki |
For that reason maybe it is best they wait, and the whole magic can go in at once |
17:47 |
RealBadAngel |
only coords of light source |
17:47 |
RealBadAngel |
because now im using fixed one |
17:48 |
Taoki |
ok |
17:49 |
Taoki |
I'd like to know what you think about the post I linked and the method I suggested there |
18:00 |
|
Taoki joined #minetest-dev |
18:58 |
|
Calinou joined #minetest-dev |
19:01 |
hmmmm |
sweetbomber: I just realized something.... your way of handling cutoffs seems almost exactly like my original idea, which i dumped because i didn't want to be responsible for calculating placements for other adjacent blocks |
19:02 |
hmmmm |
what's different with yours, is that you use position-dependent random values only |
19:02 |
hmmmm |
pseudorandom values in minetest, unless they use the global rand, are almost always based on the blockseed |
19:03 |
hmmmm |
so you'd calculate the blockseed for the neighboring blocks and then do a dry "placement" for each of those |
19:03 |
hmmmm |
if any of them have parts that show up in the chunk you're currently handling, then place that |
19:03 |
hmmmm |
this is much better than your idea: |
19:04 |
hmmmm |
1. PseudoRandom::next() is much lighter than noise2d() or noise3d() |
19:04 |
RealBadAngel |
hi hmmmm |
19:04 |
hmmmm |
2. you only make a number of calls equal to the number of decorations that would be present in that chunk |
19:04 |
hmmmm |
hi RBA |
19:06 |
hmmmm |
now, since you intend on polling every point to see if a decoration should be placed, this turns out to be much, much slower since what you do is in fact the worst case time (O(n)), which would happen only if scarcity == 1 for decorations placed the original way |
19:07 |
hmmmm |
so now that we ruled placing items on their own queue to be written to the map separately seems worse than it originally did, this pre-calculating and slicing seems like the natural way to do this |
19:16 |
|
Jordach joined #minetest-dev |
19:20 |
|
Jordach joined #minetest-dev |
19:20 |
|
Jordach joined #minetest-dev |
19:24 |
|
sweetbomber joined #minetest-dev |
19:25 |
sweetbomber |
hmmmm: im not planning to run a full noise2d for each evaluation |
19:25 |
sweetbomber |
and im not planning to check every node to see if it has a structure on it |
19:25 |
sweetbomber |
lets imagine for instance two scales |
19:25 |
sweetbomber |
the first scale is composed of 16x16x16 blocks (lets call it superblock) |
19:25 |
sweetbomber |
the second scale is the block itself |
19:25 |
sweetbomber |
so, when we're evaluating one block we do the following: |
19:25 |
sweetbomber |
does this 16x16x16 block has a structure? calculate one or two iterations of the PRNG over the seed corresponding to the origin of that superblock |
19:26 |
sweetbomber |
(we can add the global seed to that one, as is already done in some places) |
19:26 |
sweetbomber |
if the result of the prng is above a threshold, it has a structure on it |
19:26 |
sweetbomber |
if not, stop there |
19:27 |
sweetbomber |
if it has a structure: |
19:27 |
sweetbomber |
for the current block, calculate again one or two prng iterations over seed composed of the block origin coordinate |
19:28 |
sweetbomber |
is it above a certain threshold? if not, stop there, if yes, proceed |
19:29 |
sweetbomber |
now, that we know the current block has a structure, calculate the common seed, and start the structure generation procedure, which is also scaled |
19:29 |
sweetbomber |
this method does not use noise2d anytime |
19:31 |
sweetbomber |
and not every block is checked for structures, because if the superblock does not have the given threshold, a whole 16x16x16 blocks are not checked at all |
19:32 |
sweetbomber |
and even for each block, the structure generation algorithm could not be run, again depending on the random value |
19:32 |
sweetbomber |
is this similar to what you thought previously? |
19:35 |
sweetbomber |
regarding the structure generation algorithm,im thinkin on a similar approach, based on hierarchy, on which the first steps only concern about space reservation of successively smaller volumes, and only for those volumes overlapping with the current block there will be the precalculation of nodes' positions, IDs, etc... |
19:35 |
sweetbomber |
i cant think of a more efficient algorithm... |
19:45 |
Exio |
someone just told me, minetest (official build) doesn't work under windows8, but mingw ones work perfectly |
19:45 |
Exio |
thexyz: ^ two people reporting that |
19:45 |
Exio |
when running it from the cmd => nothing |
19:52 |
thexyz |
uh oh |
19:54 |
Exio |
just a "minetest.exe stopped working" |
20:50 |
|
proller joined #minetest-dev |
20:52 |
|
mrtux joined #minetest-dev |
21:46 |
|
Jordach joined #minetest-dev |
21:46 |
|
Jordach joined #minetest-dev |
21:52 |
|
salamanderrake joined #minetest-dev |
21:52 |
|
Jordach joined #minetest-dev |
21:52 |
|
Jordach joined #minetest-dev |
21:57 |
|
Jordach joined #minetest-dev |
21:57 |
|
Jordach joined #minetest-dev |
21:57 |
|
Jordach joined #minetest-dev |
21:59 |
|
Jordach joined #minetest-dev |
22:24 |
|
NakedFury joined #minetest-dev |
23:15 |
PilzAdam |
any rules how many core devs set release date and feature freezes? |