Minetest logo

IRC log for #minetest-dev, 2012-12-23

| Channels | #minetest-dev index | Today | | Google Search | Plaintext

All times shown according to UTC.

Time Nick Message
00:21 iqualfragile1 joined #minetest-dev
00:27 SpeedProg1 joined #minetest-dev
00:57 VanessaE thexyz: what was the bug you tried to point me to earlier?  github's down.
02:06 Exio joined #minetest-dev
03:19 mrtux joined #minetest-dev
04:40 mrtux joined #minetest-dev
06:24 VanessaE celeron55: well the verdict seems to be, with that change, that the map loader/emerge performs better, and the server's no longer getting jammed at 100%, but at least one person is reporting that the world is failing to load for them despite chatting in realtime.
06:25 VanessaE or at least, not loading in a timely manner. I can see him moving around, so it's an improvement
07:14 hmmmm indeed; if the emerge queue is full and there are other blocks that don't need to be emerged, instead of sending those blocks as well it'll be dropped
07:15 VanessaE on a probably unrelated note, I noticed the server spinning at around 60% CPU while no one was on it (not even me).  As soon as I signed on, the usage dropped to <10%
09:13 rsiska joined #minetest-dev
10:09 thexyz VanessaE: >Crash on unexpected focus change
10:54 sfan5 joined #minetest-dev
10:54 thexyz joined #minetest-dev
11:10 serengeor joined #minetest-dev
12:30 celeron55 http://minetest.net/forum/viewtopic.php?pid=58672#p58672
12:34 celeron55 [celeron55@nk src]$ cppcheck content_sao.cpp --enable=all 2>&1| grep warning
12:34 celeron55 [content_sao.cpp:342]: (warning) Member variable 'LuaEntitySAO::m_animation_speed' is not initialized in the constructor.
12:35 celeron55 [content_sao.cpp:342]: (warning) Member variable 'LuaEntitySAO::m_animation_blend' is not initialized in the constructor.
12:35 celeron55 [content_sao.cpp:342]: (warning) Member variable 'LuaEntitySAO::m_attachment_parent_id' is not initialized in the constructor.
12:35 celeron55 Taoki... 8)
12:38 Exio i have problems with the mapgen, the alias mapgen_tree/leaves/apple changed to air in the default/mapgen.lua, in a new world, i still see trees, same with changing water source to lava source, still water
12:38 Exio any ideas?
13:19 jin_xi testing cheesecakes patch, looking good so far
14:26 doserj joined #minetest-dev
15:30 doserj joined #minetest-dev
16:06 SpeedProg joined #minetest-dev
16:16 hmmmm joined #minetest-dev
16:22 Calinou joined #minetest-dev
16:58 thexyz jin_xi: the same thing was just committed by c55
17:08 celeron55 here's a full cppcheck run if somebody has a boring holiday: http://misc.minetest.net/cppcheck_2012-12-23.txt
17:09 celeron55 probably not all is worth fixing (they might even be intentional), but might be worth a look
17:41 RayBM joined #minetest-dev
17:57 doserj joined #minetest-dev
18:08 Taoki[laptop] joined #minetest-dev
18:09 SpeedProg joined #minetest-dev
18:16 rsiska joined #minetest-dev
18:53 jin_xi joined #minetest-dev
18:53 hmmmm just read the first pageful of that output
18:53 hmmmm not much is really wrong there
18:55 RealBadAngel hi
18:55 hmmmm actually aside from 3 things that would've shown up in -Wall, all that is a bunch of crap
18:56 RealBadAngel ive noticed strange behaviour of mapgen. sometimes it happens like the mapgen reruns on already generated block, carves caves in my trees and placing some gravel on them
18:57 RealBadAngel http://realbadangel.pl/damage.png
18:58 thexyz huh, cppcheck still isn't capable of finding bugs like this one https://github.com/celeron55/minetest/issues/168
18:59 thexyz hmmmm: you may be interested in this one ^
18:59 celeron55 he has already seen it 8)
19:00 thexyz ok
19:00 hmmmm yes... and i've decided that it should NOT be fixed in v6
19:00 hmmmm doing so would screw up already existing maps
19:00 thexyz then how about removing this line? >* (blockpos_max.Z - blockpos_max.Z + 1);
19:01 hmmmm if you'd like
19:01 celeron55 how about calculating the correct value and then dividing the result with a value that balances it out for the size that we generate
19:01 hmmmm there's also the other issue of the cave perlin noise using X and Y coordinates instead of X and Z; but that will remain unchanged as well
19:03 hmmmm sure, divide by (blockpos_max.Z - blockpos_min.Z + 1) in both places where volume_nodes is used in the cave generation 8)
19:03 RealBadAngel hmmm, how the change could screw something already generated? it shall affect only newly generated stuff?
19:04 hmmmm if a cave generated is in between a chunk boundary
19:04 celeron55 it doesn't continue caves like that
19:04 celeron55 it's as dumb as it can be
19:04 hmmmm it doesn't?
19:05 hmmmm you sure??
19:05 hmmmm if that's the case then it can be fixed
19:05 celeron55 it only does that by chance
19:05 RealBadAngel well, if the caves are already wrong calculated
19:05 RealBadAngel maybe thats why i do have them on top of my trees
19:05 hmmmm I really don't understand the cave code too much... i mean look at it
19:06 RealBadAngel somethin is carving them in my leaves
19:06 hmmmm my time was more productive somewhere else, I figured, since the caves already look nice
19:06 RealBadAngel see the picture
19:06 hmmmm yea
19:06 celeron55 it's a mess tuned by me by experimentation :P
19:06 celeron55 found that to be the best way to get something reasonable
19:07 celeron55 also, it is old as hell
19:08 RealBadAngel going to check now how the change will affect the world
19:09 celeron55 eh
19:09 celeron55 the usages of the value need to be tuned accordingly
19:09 celeron55 they're designed to work with the wrong value
19:09 hmmmm RealBadAngel, can you tell me the coordinates of that cave damage?
19:10 RealBadAngel no, only picture left
19:10 hmmmm :/
19:10 hmmmm way to go
19:10 RealBadAngel but i can find another
19:10 hmmmm yea
19:10 hmmmm that'd be good
19:10 RealBadAngel that happens quite often
19:10 RealBadAngel i was suspectin bugs in my code, but then noticed gravel on them
19:11 RealBadAngel and some tunnels inside trees
19:11 RealBadAngel tried to move treegen at the very end of mapgen
19:12 RealBadAngel but now its clear. with wrong calculated cave it actually makes it somewhere else, not on the generated block
19:13 celeron55 0.3 doesn't use this cave generation, and the old version that uses versions of it don't have tags in the git repo (they had tags in mercurial back then...) but 47e4eda4bb87cd9dc20dddf81ca473b523eeb150 contains it in map.cpp:2423
19:14 celeron55 apparently that is 22 months old now!
19:17 RealBadAngel ok, ive put that fix to Z coords
19:17 RealBadAngel caves still look cavish, and still theyre in trees ;)
19:18 hmmmm well yeah, you were expecting that to fix something?
19:18 RealBadAngel was worth a try ;)
19:19 RealBadAngel i have some holes in trees, what info do you need?
19:20 RealBadAngel you can join my game, 77.91.18.205
19:25 RealBadAngel http://realbadangel.pl/damage2.png
19:25 hmmmm yeah i figured as much
19:28 RealBadAngel pretty close to it is another tree with gravel
19:28 hmmmm http://i.imgur.com/uQw3o.png
19:28 hmmmm mese clouds?!
19:29 hmmmm more like mese caves
19:29 hmmmm I changed airnode to MapNode(c_mese) in the cave code, and that's the result
19:29 hmmmm clearly the code that restricts it from only generating caves below height 0 isn't working right
19:30 RealBadAngel looks like alien infected zones ;)
19:33 RealBadAngel maybe because of it?
19:33 RealBadAngel // Horribly wrong heuristic, but better than nothing
19:33 RealBadAngel bool block_is_underground = (WATER_LEVEL > node_max.Y);
19:46 hmmmm no, that's not why
19:49 RealBadAngel just a guess, im reading the caves code now
20:00 RealBadAngel ha, now we do know from where comes dirt floatin in the air
20:01 RealBadAngel i also put there mese and checkin results
20:03 hmmmm weird, it seems like airnode is also being used for tree leaves
20:03 hmmmm i can clearly see mese formations being in the exact shape of trees
20:04 RealBadAngel no
20:04 celeron55 there are two kinds of carvings the cave generation code does
20:04 RealBadAngel i saw that already, it just replaces nodes
20:04 celeron55 one it does only for solid ground; that can replace trees with "cave air"
20:04 RealBadAngel i already saw l-systems trees infected with mese
20:04 celeron55 they are smaller caves
20:04 hmmmm ahhhh
20:05 celeron55 then it does large stuff near the surface
20:05 celeron55 to make some interesting terrain features
20:05 hmmmm it actually replaces trees with cave air?
20:05 RealBadAngel http://realbadangel.pl/damage3.png
20:05 RealBadAngel not only trees
20:06 celeron55 v6 uses a combination of 2d noise and carving to make the surface
20:06 hmmmm ohhh
20:06 RealBadAngel so it shall check also for group of nodes to be replaced
20:06 hmmmm the tree growing is inside of the aging loop
20:06 celeron55 if you make it not touch trees, then you have floating trees
20:07 hmmmm er no it's not
20:08 RealBadAngel tree is outside that loop, and is being carved too
20:08 hmmmm yeah anyway i don't see how it's getting replaced with cave air, because they're clearly placed after the cave generation
20:08 celeron55 maybe it's in the border area of the map generator
20:09 celeron55 afaik caves get generated a bit into already generated stuff too
20:09 hmmmm ahh there's the problem
20:09 celeron55 to make long interconnects possible, and to allow generating them up to the border without making flat endings
20:09 hmmmm except that part of the VoxelArea isn't blitted back, right?
20:09 hmmmm i did not know that
20:10 celeron55 of course it is
20:10 celeron55 i mean, it's not some necessity of map generation, but it's what it does
20:10 RealBadAngel anyway it shall not touch plants
20:10 hmmmm how on earth do we fix that
20:11 celeron55 i prefer glitchy but interesting generation over non-glitchy boring generation
20:11 RealBadAngel make a group of nodes that can be touched
20:12 RealBadAngel without it any generated stuff, like dungeons, trees will be destroyed with it
20:12 celeron55 i'd say just don't care for now
20:13 RealBadAngel propapbly youre right, but its relatively easy to fix
20:15 RealBadAngel just make it able to replace stone/sand/dirt
20:15 RealBadAngel and nothin more
20:17 celeron55 well, the map generator certainly knows what it uses for generation of ground, so... well, kind of just make a set of them for seeing which are ground
20:18 hmmmm I'm still not sure how to fix the "trees geting partially replaced with cave air" problem, but this will stop caves from carving out pieces of your trees  http://paste.dy.fi/TpZ
20:18 celeron55 doesn't need any kinds of groups or anything
20:18 hmmmm I know it's stupid, but it works
20:18 celeron55 why not make a diff so one can see what you've done to it
20:19 celeron55 oh, you're on windows with no programming tools, that's why
20:19 hmmmm well i just added 5 lines of code
20:19 RealBadAngel but where :)
20:19 hmmmm I surrounded it with a bit of context
20:20 hmmmm a diff would be useless since it wouldn't match up with any of your code
20:20 hmmmm i mean try it out:  Ctrl+F "for(u32 jj=0; jj<caves_count..."
20:21 celeron55 what does that even do... i don't think it's something we'd want
20:21 hmmmm it stops caves from generating in areas too high
20:21 hmmmm e.g. on tree tops
20:21 celeron55 but you sure want to get them to generate so that they come up to the ground from underground
20:22 hmmmm they still do
20:22 hmmmm I tried it out
20:22 RealBadAngel i will check it too
20:22 celeron55 i say it's nonsense
20:22 celeron55 you compare the average height of the chunk to the average-ish height of the ground at that horizontal position
20:23 celeron55 s/height/y/
20:24 celeron55 by using any of this "thinking"-kind of thing, i can conclude it's useless and practically only causes unwanted results
20:24 hmmmm okay :)
20:25 RealBadAngel i can see caves below the trees and above them
20:25 hmmmm above them?
20:25 hmmmm what's your seed
20:25 celeron55 if you want to try to do it, then you have to do it on a node-by-node basis in the cave generator by comparing them to the main ground 2d noise
20:27 RealBadAngel hmmmm, http://realbadangel.pl/damage5.png
20:28 hmmmm are you sure you applied it correctly?
20:28 hmmmm right now i am not seeing anything of that sort
20:30 RealBadAngel http://pastebin.com/Q4zzEtn0
20:30 RealBadAngel a part of code with your change
20:31 hmmmm hum
20:31 RealBadAngel aahh
20:31 RealBadAngel messed it :)
20:31 hmmmm personally, this is what I see with it
20:31 hmmmm http://i.imgur.com/tlj0N.jpg
20:31 hmmmm what'd you mess?
20:31 hmmmm Oh
20:31 hmmmm I looked at the wrong pastebin
20:31 RealBadAngel fixin it now
20:31 hmmmm yeah wtf
20:31 hmmmm you're not supposed to do that
20:31 hmmmm that does nothing
20:32 hmmmm again, sorry I didn't just make a diff but my version of the mapgen source file is incredibly different
20:32 hmmmm so it'd be useless
20:33 hmmmm anyway I'm not really sure why it works but it does....
20:33 hmmmm should we roll with it...?
20:34 hmmmm I just wrote that to try _something_
20:35 RealBadAngel cant see mese clouds anymore
20:35 RealBadAngel but the second part is still active
20:35 hmmmm yeah again, we can't fix that as easily
20:35 hmmmm has to do with the boundary thing
20:36 RealBadAngel http://realbadangel.pl/damage6.png
20:37 hmmmm ouch :)
20:38 RealBadAngel imho boundaries fix wont help
20:39 RealBadAngel it will always try to replace generated stuff no matter whats that
20:41 RealBadAngel and c55 is right, that fix isnt good
20:41 RealBadAngel that whats left is just that second aspect of cave generation
20:42 RealBadAngel i can barely find any caves below the ground
20:53 RealBadAngel well, cant we just when starting to make a cave, find a ground level at one spot, move a bit below and then start carving?
20:54 RealBadAngel at worst case only parts of the cave will be drawn above the ground (in case of hills or whatever)
20:55 RealBadAngel this could apply to the caves only above water level
20:55 hmmmm i don't see how that modification would prevent caves from forming below gorund
20:55 hmmmm ground*
20:56 hmmmm hold on
20:56 RealBadAngel if below water level just carve it, if above find ground level
20:57 RealBadAngel and move A BIT below
20:57 hmmmm ?_?
20:58 hmmmm what are you talking about, there are plenty of caves below ground
20:58 hmmmm perhaps you just left the air as mese and that's why you can't see the caves underneath
20:58 RealBadAngel shit, propably yes :)
20:59 hmmmm anyway it seems like that 'fix' sort of helped that one aspect of the problem
20:59 hmmmm I guess using the averages really is enough
21:00 RealBadAngel celeron55, what do you think about my idea?
21:01 hmmmm so you want to start from the bottom down
21:01 hmmmm we start from the bottom currently and work our way up
21:01 RealBadAngel i would like to spilt it into two cases
21:02 RealBadAngel if cave is under water level we dont need to find ground level
21:03 RealBadAngel if its gonna be above water level we need to find ground level and fit the cave below it
21:04 RealBadAngel it will prevent wasting cpu time to generate holes in air
21:04 RealBadAngel and when the cave will be generated in a cliff it will make nice entrance to it
21:08 RealBadAngel v3s16 startp(orp.X, orp.Y, orp.Z);
21:08 RealBadAngel just make sure this pos is not above ground
21:10 RealBadAngel from what i can see thats the central point where cave starts to be carved
21:12 RealBadAngel so if startp.Y < water level just go on
21:13 RealBadAngel if startp.Y > water level check whats here , if air move down until nonair node is found
21:14 RealBadAngel then sub some constans or random value to make it a bit below the ground
21:54 RealBadAngel i guess checkin below for contens in not generated block will screw it
22:00 jin_xi RealBadAngel: so you now generate trees in c++? Can I find this somewhere?
22:01 RealBadAngel theyre workin, ive replaced default tree gen with them for testing
22:02 jin_xi cool
22:02 RealBadAngel i will upload it later today to git
22:02 jin_xi ok
22:21 sfan5[iPod] joined #minetest-dev
23:16 SpeedProg1 joined #minetest-dev
23:17 SpeedProg joined #minetest-dev
23:43 RealBadAngel hmmmm, youre there?
23:43 RealBadAngel i think i know why caves appears in the air
23:46 RealBadAngel well, nvm i dont

| Channels | #minetest-dev index | Today | | Google Search | Plaintext