Time Nick Message 00:39 paramat merging #7935 00:39 ShadowBot https://github.com/minetest/minetest/issues/7935 -- Mirror 'sunrisebg' texture to fix chopped right edge by paramat 00:39 paramat done 01:32 Unarelith any opinions on a possible singleton refactor post 5.0.0? https://gist.github.com/Quent42340/14854c80ed463540c70de48e177cdd29#singletons 04:10 sofar did texture file names become case sensitive recently? 04:12 sofar ok this is weird... if I use the in-game mod download, mesecons complains about not being able to find jeija_microcontroller_LED_A.png 04:12 sofar notice capital name, which, corresponds with the lua source 04:13 sofar but the downloaded mod has lowercase _led_a 04:15 sofar filed a bug with mesecons, but, it's weird. 13:16 jas_ #7938 13:16 ShadowBot https://github.com/minetest/minetest/issues/7938 -- Player models do not rotate and consistently face one direction 13:16 jas_ rubenwardy they are in sync and up to datr. 13:17 jas_ it's easy to test and i did so and do confirm 13:19 jas_ but... i will try again. my build was current last night but i see theres been two more commits this morning. 13:21 nerzhul hi , sorry my messages were not sent 13:21 nerzhul i pushed 2 trivial commits around 12h GMT to fix GCC reported warnings 13:21 jas_ oh so its likely not to change rotation issue 13:21 jas_ buillding now anyway for fresh test......... 13:23 nerzhul my commits are surely not related with your problem 13:23 nerzhul can you bisect ? 13:25 jas_ ok look here i just tested current head same version client server and it is a real... blocker 13:26 jas_ i reverted the commit i mentioned in my comment and it fixed the issue. idk wat is bisect 13:27 nerzhul which commit, sorry ? 13:28 nerzhul can you give me commit id ? 13:29 jas_ yes sec 13:29 jas_ faa358e 13:29 nerzhul ty 13:30 nerzhul i approved it but it seems there is calculation error 13:30 jas_ thx right back atcha 14:17 p_gimeno I've marked a suspicious snippet 14:18 p_gimeno jas_: do they head north always? 14:30 p_gimeno here's a possible fix: https://paste.scratchbook.ch/view/2cc6d9a0 14:42 nerzhul p_gimero we don't keep the rotation in that step and you seems to fix it 14:43 nerzhul i think we miss some unittests on some parts 14:55 nerzhul i will push another GCC warning fix 14:55 nerzhul this: 14:55 nerzhul cc1plus: note: -Wabi warns about differences from the most up-to-date ABI, which is also used by default 14:55 nerzhul cc1plus: note: use e.g. -Wabi=11 to warn about changes from GCC 7 14:56 nerzhul i just test with clang to be sure 14:58 nerzhul we need to have a proper build and it doesn't seems to be well maintained :p 15:16 nerzhul i push another commit to add unittests on the new testWrapDegrees_0_360_v3f 15:45 nerzhul hmm CI shows with older compiler -Wabi=11 is not good i revert the commit 16:08 VanessaE I've been thinking.. since that hotbar change went in, would mtg benefit from inclusion of my hotbar size mod also? 18:05 Krock sofar: thanks for your re-review. Will merge #5268 in 15 minutes 18:06 ShadowBot https://github.com/minetest/minetest/issues/5268 -- Send only changed node metadata to clients instead of whole mapblock by SmallJoker 18:07 sofar kewl 18:07 sofar yeah I really didn't want that one to slide 18:07 sofar even if it's minor, it may just make further optimization easier 18:07 nerzhul if i remember there was an issue in the code, but can't remember 18:08 Krock nerzhul: huh? could you please rephrase that? 18:08 nerzhul :p 18:08 nerzhul if i remember in this PR i found an issue when it was wrote but now i can't remember which 18:08 nerzhul not a problem 18:08 nerzhul we need tests 18:09 nerzhul i pushed some tiny commits today on the build system and i'm writing activeobject storage in a specific object to make client/server environment less crappy, this object has too responsibility and is very hard to track 18:12 nerzhul now i push a missed commit to stable-0.4 and cherry pick on master, if you remember you ask me to rebuild MT and publish it on GH and i did it but forgot to commit 18:13 Krock yes, that was for the non-Debug build 18:13 nerzhul yep 18:13 Krock which apparently didn't solve the issue 18:13 nerzhul resync the version is better if we publish on the store or any phone 18:25 nerzhul Krock: what do you think about #7939 i only do the client part currently, but if the design is okay i will do the server part + unittests 18:25 ShadowBot https://github.com/minetest/minetest/issues/7939 -- Add an activeobject manager to hold active objects by nerzhul 18:26 nerzhul the idea is to remove ownership from environment to another object to reduce the "environment" management area to reduce it 18:27 nerzhul PR is basically a code move + use some C++11 features to keep the current behaviour properly without performance penalty 18:28 nerzhul this will also permit to enhance code quality by adding more unittests due to more testable object, clientenvironment is like game, untestable in its current state 18:28 Krock your last name is CAPS LOCK ON 18:28 nerzhul yeah i like to say who i am xD *joke* 18:29 nerzhul it's like that in all copyright not only new :p 18:29 Krock sounds good, but can it also be used for server-activeobjects? 18:29 nerzhul yep 18:29 nerzhul i just didn't coded it yet 18:29 nerzhul i added a generic interface (we don't have it currently) + a client implementation, i can easily do a server implementation 18:29 nerzhul this will also reduce the client/server code duplication in env, that part is globally dup 18:30 nerzhul if you have no more comments i code the server part :) 18:33 Krock thinking about whether it's the best solution.. mhm$ 18:34 nerzhul it's a registrar for active objects :p protected from base use from environment, if at a point we want to change it 18:34 nerzhul keeping sufficient inheritance to make it work properly 18:35 nerzhul for the lambda it's the best way i found to do a generic callback on that code part 18:38 Unarelith nerzhul, maybe the code but already like this but: https://github.com/minetest/minetest/pull/7939/files#r238786138 18:39 Unarelith s/but/was 18:40 nerzhul Unarelith reviewing your idea, it seems good let me a minute. Note: i don't modified the functional algorithm except in the interface between clientenv & ao manager 18:40 nerzhul yes your idea is nice, ty 18:40 Unarelith np :) 18:41 nerzhul Unarelith do you like the new design proposal on that part ? 18:42 Unarelith nerzhul, I do like it, though your usage of lambdas/std::function is weird 18:42 nerzhul yes but it's the only wait i found to do a generic callback, because server doesn't have the same signature 18:42 nerzhul way* 18:45 Unarelith nerzhul, I added two new comments 18:47 nerzhul nice i commented one, will verify if compiler accept the second 18:49 Unarelith maybe it's possible to pass lambda only with `const&` because it's a rvalue 18:49 Unarelith though `&` is a ref on lvalue (so an lvalue) 18:49 Unarelith so both may be related 18:50 Unarelith try to pass directly the lambda with `const &`, it should work 18:51 Unarelith I used lambda, capture, std::function and auto in every last projects I worked on, never had to use `std::ref`, but I always used `const &` for std::function 18:51 nerzhul i will see if it works with a const ref 19:03 Unarelith nerzhul, I added some comments 19:04 rubenwardy loooll https://github.com/minetest/minetest/issues/7525#issuecomment-444214975 19:04 nerzhul it seems big brother is watching me 19:07 Unarelith nerzhul, the `mt` namespace is new? 19:08 nerzhul yep we don't have a namespace but i wanted to see namespace in our code, to do more real C++ :) is this in conflict with something ? 19:09 rubenwardy I don't like it 19:09 nerzhul you prefer rubenwardy::client ? 19:09 rubenwardy would be better to use namespaces for sections instead of the whole thing 19:09 rubenwardy Minetest isn't a library 19:09 nerzhul i can remove the root part 19:10 nerzhul client::ActiveObjectMgr then 19:11 Unarelith +1 rubenwardy 19:11 Unarelith client::ActiveObjectMgr looks good 19:11 Unarelith but there's not need for a global namespace, would just add useless characters everywhere 19:12 Unarelith and since your line length is limited, small names are better 19:12 Unarelith but +1 nerzhul for adding namespaces 19:14 nerzhul i pushed a commit solving all mentioned issues 19:15 nerzhul nice to see the const keyword permitting to remove the std::ref usage :) 19:15 nerzhul permits* 19:15 nerzhul i removed the global namespace 19:16 Unarelith nerzhul, explain why it's resolved please? https://github.com/minetest/minetest/pull/7939/files#r238795879 19:17 nerzhul ty github to not showing anchor when solved 19:17 nerzhul can you tell me which ? 19:17 Unarelith the last one, about `inline` 19:18 nerzhul we use inline in many part of our code to be explicit 19:18 Unarelith if a function is defined in class definition, it's always implicitly `inline`, thus adding `inline` is useless 19:19 nerzhul clion doesn't notify me about that 19:19 nerzhul whereas clang-tidy is enabled with many many warnings 19:19 Unarelith don't rely only on clion and clang-tidy 19:20 nerzhul can you link me the C++ spec updated for C++11 about that ? 19:20 Unarelith https://en.cppreference.com/w/cpp/language/class 19:21 Unarelith Function definitions, which both declare and define member functions or friend functions. A semicolon after a member function definition is optional. All functions that are defined inside a class body are automaticaly inline. 19:21 nerzhul okay ty 19:22 Unarelith nerzhul, I made this btw, can I get your opinion? https://gist.github.com/Quent42340/14854c80ed463540c70de48e177cdd29 19:22 nerzhul GenericCAO should be kept 19:22 nerzhul CAO is not a word :p 19:22 nerzhul it's ClientActiveObject 19:22 rubenwardy +1 19:23 Unarelith that's the point actually 19:23 nerzhul Each file must be in a folder: they are all in a folder ^^ 19:23 rubenwardy Also, "Replace #pragma once by #ifndef #define #endif" -> the change to #pragma once was recent 19:23 nerzhul Replace #pragma once by #ifndef #define #endif => sorry but it was changed in 5.0.0 due to the whole world compiler agreement, yes it's not a in a norm but implemented in all used compiler, we will keep them 19:24 nerzhul we already talked about this when C++11 occurs when the dev cycle began 19:24 nerzhul fix code style must be a long term issue 19:24 rubenwardy #6264 19:24 ShadowBot https://github.com/minetest/minetest/issues/6264 -- C++ modernize: Pragma once by nerzhul 19:24 nerzhul else we will have crapy git blame 19:24 Unarelith nerzhul, ok then why you have files with the same name? it's the only downside of `#pragma once` 19:24 nerzhul we got some example: my pr 19:24 rubenwardy ah, the actual discussion is here: #6259 19:24 ShadowBot https://github.com/minetest/minetest/issues/6259 -- C++11 header guards: switch to #pragma once 19:24 nerzhul generic interface in src and namespace interface in client :p 19:26 nerzhul -Wall is not a good idea in the main way, but -Wextra can be nice, i should see if there is not useless noise 19:26 nerzhul for nullptr i did many PR on it and talked with contributors to do it but i'm not sure we can use it when we are talking to irrlicht :( 19:26 nerzhul Use using a = b instead of typedef b a => i agree with that it's just C++11 19:27 nerzhul same for override 19:27 Unarelith nerzhul, with -Wall -Wextra + -Wno* for the specific warnings we don't want (so two or three of them) it's ok 19:27 nerzhul as you see in the 5.0.0 commits we have mostly used override, whereas there is no dev rule on the wiki currently 19:27 Unarelith for nullptr I think I did mass NULL replacement in my fork, and things were ok 19:28 nerzhul for shared_ptr and unique_ptr only for new code it's okay, when the variable lifetime is well known 19:28 nerzhul for old code i prefer to be sure 19:28 Unarelith "when the variable lifetime is well known", well, it's the main requirement 19:28 Unarelith for old code you can easily check variable lifetime 19:28 nerzhul member init in class def is done everywhere 19:28 Unarelith nope 19:28 nerzhul i did mass refactor on that on the C++11 move 19:28 nerzhul maybe i miss some 19:29 nerzhul "Apply the rule of five when possible": what is this rule ? 19:29 Unarelith was the rule of three in C++03, and there's also the rule of zero and the rule of one 19:30 nerzhul sorry but i don't understand :p 19:30 Unarelith let me explain 19:30 nerzhul the name looks like LOTR :p 19:30 Unarelith the rule of five says that if you need to define a destructor, you'll need to define copy + move constructor/operator (so 5 functions) 19:31 nerzhul oh i see, clang-tidy reports them 19:32 nerzhul we should define them to default or forbid copy. We have a macro to forbid copy, but not for generic copy 19:32 Unarelith btw I checked and there's only the rule of zero, not the rule of one (made no sense anyway) which is to not define constructor if it's not needed (even with MyClass() = default;) 19:33 Unarelith nerzhul, you SHOULDNT use macros to do that btw!! 19:33 nerzhul it was done like that in the original C++03 code 19:33 nerzhul :p 19:33 nerzhul C(const &C) = delete; 19:33 Unarelith since C++11 you should make a `NonCopyable` class with copy constructor/operator = delete and inherit from that 19:33 Unarelith or do this directly in the class 19:34 nerzhul yep the generic non copy is sexy 19:34 nerzhul i really like C++, i started to do some PR on gnome builder to enhance the golang support... C is ... shit :D too long to write 19:35 Unarelith agreed 19:35 Unarelith I stick with C++ since 8 years now :p 19:35 nerzhul heh 19:36 Unarelith but well, I only do "real" C++ since 4 years (when I learned C++11 and the actual standard) 19:36 Krock merging #5268 after 30 minutes (and an hour) 19:36 ShadowBot https://github.com/minetest/minetest/issues/5268 -- Send only changed node metadata to clients instead of whole mapblock by SmallJoker 19:37 Unarelith because until then, I only did C+, not C++, and unfortunately some of the minetest code still looks C+ :( 19:39 nerzhul Krock(master)# at 21:00 19:40 nerzhul git am -3 5268.patch && git push 19:40 nerzhul :D 19:40 rubenwardy the rule of five says that if you need to define a destructor, you'll need to define copy + move constructor/operator (so 5 functions) 19:40 rubenwardy * destructor 19:40 rubenwardy the logic is that if you need a non-default one, then you'll also need a non-default one for the others 19:41 rubenwardy wait 19:41 Unarelith rubenwardy, it's not really clear what default does for this rule and it's an interesting question 19:41 rubenwardy you already wrote destructor 19:41 Unarelith because default is still user-defined 19:42 Unarelith and yes I already wrote destructor :p 19:42 * rubenwardy has bad eyes 19:44 Unarelith btw rubenwardy, I'm having an issue with a mod I'm making and I think it could need discussion about API (or there's an easy way to do this I don't know about) 19:44 Unarelith I'm adding a new tool, a "Crook", which should be able to get silk worms from all the leaves, but I can't do this in a generic way 19:45 Unarelith the only solution I found was to edit each leaves drop table, and that's not really good to only add a single drop to a defined group of nodes :/ 22:12 p_gimeno does anyone know what "interleaved unsupported" means here? https://github.com/minetest/minetest/blob/master/builtin/mainmenu/pkgmgr.lua#L342 22:12 rubenwardy I actually have no idea 22:12 rubenwardy I just left that comment 22:12 sfan5 guess: you can't partially enable a modpack? 22:13 rubenwardy why would it mention that though? 22:13 sfan5 ¯\_(ツ)_/¯ 22:13 T4im can the formspec lists make multiple selections with shift? 22:13 p_gimeno thanks sfan5, that might be it, weird wording though 22:13 rubenwardy HybridDog added it 22:13 rubenwardy https://github.com/minetest/minetest/commit/7f7678e4e30fdae3722c3f75d4dc6488364d853e 22:14 rubenwardy hey sfan approved that one :) 22:14 p_gimeno "partial unsupported" would make more sense if that was the meaning 22:15 p_gimeno or "partial enabling unsupported" 22:15 rubenwardy added a comment 22:17 p_gimeno thanks, I've started working on rebasing #6898 (it seems I have to plain rewrite it) and found that 22:17 ShadowBot https://github.com/minetest/minetest/issues/6898 -- Allow distinguishing mods by modpack by pgimeno 22:17 rubenwardy yeah, I did some changes recently 22:19 p_gimeno it disobeys the Lua style guide at some points too, like comments should normally start by uppercase 22:20 p_gimeno and the "--This is wrong." example in the style guide 22:21 p_gimeno (the latter is not in that commit, it's in pkgmgr.lua in some scattered places) 22:23 p_gimeno I feel weird adding upper case comments in the middle of lower case ones 22:23 p_gimeno should I change the case around the code I modify? 22:27 * p_gimeno shrugs and leaves them alone