Minetest logo

IRC log for #minetest, 2020-11-14

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

All times shown according to UTC.

Time Nick Message
00:10 swift110-phone joined #minetest
00:21 erlehmann joined #minetest
01:15 NathanS21 joined #minetest
01:24 FeXoR joined #minetest
02:08 illwieckz joined #minetest
02:15 Taoki joined #minetest
03:28 ghoti joined #minetest
03:30 ghoti Hi all. I have some unknown nodes in the ground from rendering before I removed some mods. Without reinstalling all the mods, is there any way I can find out what the unknown nodes are supposed to be, without reinstalling mods I almost certainly don't want? Their previous names no longer show up in debug mode.
03:43 Verticen joined #minetest
04:04 NathanS21 joined #minetest
04:11 sagax joined #minetest
04:41 fluxflux joined #minetest
05:24 Hawk777 joined #minetest
06:11 SoylentCow you should be able to, theoretically, find their names, because if you would reinstal the mod, they would come back. but i suppose if you don't want to reinstall the mod,
06:12 SoylentCow you may have to install an inspector mod of some kind
06:13 SoylentCow perhaps worldedit inspector can do this, i simply don't know, but it seems like something very doable
06:22 Follpvosten[m] ...when you click on them, the chat will tell you like "unknown node mod:node" in red text
06:22 Follpvosten[m] Left click that is
06:42 bobbertson joined #minetest
06:42 bobbertson hey there
06:44 bobbertson So I'm writing a mod to let users queue youtube songs that utilizes a youtube-dl python component to get songs and then sends it via minetest.dynamic_add_media, but I'm really struggling with setting up a socket from the minetest mod to the python component to communicate due to unfamiliarity with lua and the sandbox sort of secure environment where it doesn't want me to be able to acquire luasocket, can anyone help?
06:48 bobbertson If anyone even uses this channel that is
06:52 Hawk777 I’m not super-familiar with Minetest modding, but wouldn’t it make sense to just make your mod non-secure so it must not run in the sandbox? After all, if your users already trust you enough to run your separate Python code, which can do anything it wants, then the Lua sandbox isn’t really accomplishing anything.
06:52 bobbertson i did do that
06:53 bobbertson but i'm quite lost still lol
06:53 bobbertson basically how to run functions AFTER init so for example users can do /queue_song search_term_here and it would have to use the socket to send that out to the python component
06:54 bobbertson past init
06:54 bobbertson it's mostly just me being unfamiliar with lua i guess
06:54 Hawk777 I think you need minetest.register_chatcommand.
06:54 bobbertson ya i got that part down
06:55 bobbertson but idk how i can possibly use the socket i setup in init
06:55 bobbertson later on
06:55 bobbertson like a global or something
06:55 Hawk777 Oh. Ugly, but put it in a global variable?
06:55 bobbertson can functions be global?
06:56 Hawk777 Well, they are by default, but I don’t think that’s quite what you want.
06:56 Hawk777 It’s the socket that you need to hang onto, not some function.
06:57 Hawk777 If your init function and your chatcommand function are in the same .lua file, then pretty sure you should just be able to assign to a variable in the init function and use the value later in the chatcommand function.
06:58 Hawk777 As long as you don’t use “local” inside the init function, you get a global variable.
07:00 calcul0n joined #minetest
07:02 bobbertson how am i even supposed to require say luasocket within a minetest mod
07:02 bobbertson i don't think i'm doing it right
07:03 Hawk777 Oh, I thought you had already managed to create a socket but were having trouble passing it from an init function to a chatcommand function.
07:04 bobbertson idk i keep messing around with stuff
07:04 bobbertson i have no idea what i'm doing tbh
07:04 Hawk777 I don’t think you’re going to be able to use Luasocket from a Minetest mod.
07:04 bobbertson i'm getting a complaint about the socket module not being found but 'lua -l socket' works from cmd
07:05 bobbertson adv_chat and the irc mod do it
07:05 bobbertson with luasocket
07:05 Hawk777 Oh. Then… copy how they do it?
07:05 bobbertson im trying to understand how adv_chat does it
07:05 bobbertson pcall(function() socket = env.require"socket" end)
07:05 bobbertson build_bridge = (socket and build_socket_bridge) or build_file_bridge
07:06 bobbertson how else could i do something with a socket?
07:06 bobbertson would be nice if there was a socket API like there is an HTTP one
07:06 CWz joined #minetest
07:06 Hawk777 Huh, funny you should mention that. Have you considered having your Python code listen on a port for HTTP requests? It’s a bit icky, but it might be easier.
07:07 bobbertson ya thought about it
07:07 bobbertson want to do that as a last resort
07:08 bobbertson because would have to poll it and stuff
07:08 Hawk777 So what is failing with your code right now?
07:08 bobbertson "..\minetest-5.3.0-win64\bin\..\mods\youtube_queue\init.lua:9: module 'socket' not found:"
07:08 Hawk777 Can you pastebin your code?
07:08 bobbertson mhm
07:09 bobbertson beware its a huge mess because im really messing around
07:09 Hawk777 Oh, also, adv_chat has a backup, from looking at its source, it doesn’t appear to *require* luasocket, it can also use files.
07:09 Hawk777 So are you certain that your adv_chat install is really using sockets?
07:10 bobbertson https://pastebin.com/3vE21aXn
07:10 bobbertson possibly not lol i haven't really gotten it to work at all for the bridge part
07:10 bobbertson but didn't need it
07:11 bobbertson im starting to think the IRC mod doesn't use it at all because it says you need luasocket but the code doesn't seem to reference it at all rip
07:13 bobbertson if nobody has any ideas ill just switch over to using the HTTP stuff
07:13 Hawk777 On the IRC mod, everything that uses sockets is in the submodule.
07:14 Hawk777 That may be why you can’t find it, if you didn’t get the submodule.
07:14 bobbertson ah you are correct
07:14 Hawk777 You could also just use files.
07:14 bobbertson didn't notice it had a submodule
07:14 bobbertson ya i was thinking of just reading from the chat log locally
07:14 bobbertson and doing things that way
07:14 bobbertson since the youtube-dl python part is made to run on the same server
07:15 Hawk777 Oh yeah, if the chat is logged, Python code could just watch that log file.
07:15 Hawk777 I was really meaning you could have your mod write commands into a file and then Python watch for that file to be created and execute the commands—use files as a communication mechanism.
07:16 Hawk777 The “good” way would be to use inotify (or whatever the equivalent is in Windows if you care about that, there might be some cross-platform Python library for it); the quick-and-dirty way would just be to sit in a loop doing sleep(1) and then check if the file exists.
07:20 bobbertson do you know how to enable chat logs?
07:20 bobbertson i thought it already did it to a file but i guess not
07:20 bobbertson actually, shoot
07:21 bobbertson id still have to poll the python bit to get the new songs queued and stuff
07:21 bobbertson ill just do HTTP api
07:58 bobbertson seems like i cant use request_http_api() outside init too?
08:00 ShadowNinja joined #minetest
08:17 bobbertson i think i'm getting it figured out
08:18 mizux joined #minetest
08:34 YuGiOhJCJ joined #minetest
08:58 Peppy joined #minetest
09:09 FeXoR joined #minetest
09:20 lisac joined #minetest
09:24 AndDT joined #minetest
09:43 ghoti_ joined #minetest
09:50 bobbertson yesssssss i got a basic thing working finally
09:50 bobbertson thanks for the help Hawk777 :D
09:55 NetherEran joined #minetest
10:02 submariner joined #minetest
10:13 TomTom joined #minetest
10:22 Peppy joined #minetest
10:23 schrodinger72 joined #minetest
10:42 submariner joined #minetest
10:49 NetherEran joined #minetest
10:57 Fixer joined #minetest
11:00 proller joined #minetest
11:04 submariner joined #minetest
11:09 gera joined #minetest
11:17 Talkless joined #minetest
11:20 submariner_ joined #minetest
11:30 submariner joined #minetest
11:30 Andrey_ joined #minetest
11:34 NetherEran joined #minetest
11:34 Andrey01 I just want to clarify, is 'X' axis pitch or roll? The lua_api.txt says pitch, however, when I try to rotate an object around X, it starts rotating around its longitudial axis and this is actually roll vice versa, not pitch
11:35 Andrey01 is this really mistake in the doc?
11:41 ghoti joined #minetest
12:04 proller joined #minetest
12:07 ghoti_ joined #minetest
12:11 Unit193 joined #minetest
12:30 NetherEran joined #minetest
12:33 Flabb joined #minetest
13:34 Krock_ joined #minetest
13:34 simon8162 joined #minetest
13:35 frostsnow joined #minetest
13:35 perrier joined #minetest
13:35 nore joined #minetest
13:36 NetherEran joined #minetest
13:37 Cork joined #minetest
13:37 bebebeko joined #minetest
13:40 Corey[m] joined #minetest
13:40 tuxayo[m] joined #minetest
13:40 IronOxidizer[m] joined #minetest
13:40 bhree[m] joined #minetest
13:40 Vagabond[m] joined #minetest
13:40 MeVegan[m] joined #minetest
13:40 celeron55[m] joined #minetest
13:40 kb1000 joined #minetest
13:40 niwla23[m] joined #minetest
13:42 jluc joined #minetest
14:06 IronOxidizer[m] joined #minetest
14:07 celeron55[m] joined #minetest
14:07 Vagabond[m] joined #minetest
14:07 xose[m] joined #minetest
14:08 jfred[m] joined #minetest
14:09 MeVegan[m] joined #minetest
14:09 bhree[m] joined #minetest
14:09 niwla23[m] joined #minetest
14:09 Corey[m] joined #minetest
14:10 FrostRanger[m] joined #minetest
14:10 silwol joined #minetest
14:10 troller joined #minetest
14:10 antoine62[m] joined #minetest
14:10 Sires joined #minetest
14:11 freshreplicant[m joined #minetest
14:11 Andrey01 joined #minetest
14:11 rschulman joined #minetest
14:13 big_caballito[m] joined #minetest
14:13 zughy[m] joined #minetest
14:13 _Zaizen_[m] joined #minetest
14:13 nathanfranke[m] joined #minetest
14:15 Follpvosten[m] joined #minetest
14:15 Kimapr[m] joined #minetest
14:15 LoneWolfHT joined #minetest
14:15 MadKamel[m] joined #minetest
14:15 anon5[m] joined #minetest
14:16 Benrob0329[m] joined #minetest
14:16 proller__ joined #minetest
14:18 CopenBra[m] joined #minetest
14:18 rubenwardy[m] joined #minetest
14:22 Andythe_great[m] joined #minetest
14:23 GyurisDani[m] joined #minetest
14:23 Quiark joined #minetest
14:23 LPKI_Ramen joined #minetest
14:24 jjohngreensr[m] joined #minetest
14:24 Fingerfood[m] joined #minetest
14:24 eyekay[m] joined #minetest
14:27 tuxayo[m] joined #minetest
14:28 Noclip joined #minetest
14:28 CWz left #minetest
14:33 kb1000 joined #minetest
14:51 submariner_ joined #minetest
14:52 submariner_ joined #minetest
15:00 NetherEran joined #minetest
15:02 Andrey01 joined #minetest
15:03 SmugLeaf joined #minetest
15:22 hisforever joined #minetest
15:24 hisforever Hi is there a way to get rid of dark places on land? I've tried world edit and it dosen't work?
15:25 tango_ what are dark places?
15:26 hisforever dark patches on buildings and land
15:27 hisforever I think there is an app to help correct lighting
15:31 Krock_ !mod fixlight
15:31 MinetestBot Krock_: There are no results for this query :(
15:32 Krock_ worldedit //fixlight perhaps
15:38 hisforever thanks Krock This seemed to work //pos1  set //pos2 then  //set air that took all the dark patches
15:39 Krock_ !next
15:39 MinetestBot Another satisfied customer. Next!
16:15 absurb joined #minetest
16:34 m42uko joined #minetest
16:45 submariner joined #minetest
16:52 Verticen joined #minetest
16:58 Andrey01 joined #minetest
17:00 kamdard joined #minetest
17:02 Andrey01 I want to clarify, does anybody know from which global half-axis does object yaw get counted off?
17:02 Andrey01 perhaps from +Z?
17:15 est31 joined #minetest
17:20 Peppy joined #minetest
17:23 Krock_ Andrey01: see graphics here https://dev.minetest.net/Player
17:23 Krock_ Z towards -X
17:23 Andrey01 Also other question: in which sequence does set_rotation() implement rotations around three axises? ZXY or anyhow else?
17:24 Krock_ X Y Z
17:24 Krock_ "* `rot` is a vector (radians). X is pitch (elevation), Y is yaw (heading) and Z is roll (bank)."
17:37 Andrey01 Krock, I have still question: if the coords of two vectors are known and they starts from some point, I can know angle between them without problems by means of vector.angle, but how do I get rotation vector?
17:38 Krock_ same as vector.angle no?
17:39 Andrey01 no, this no, rotation vector in radians
17:39 Krock_ x = / math.pi * 180.  same for y and z
17:39 Krock_ * x = x / math.pi * 180
17:39 Andrey01 hmm
17:40 Krock_ converts it to degrees
17:40 Krock_ and if you want to rotate a vector, check those: https://github.com/minetest/minetest/blob/master/doc/lua_api.txt#L3156-L3168
17:40 Andrey01 Lua has already embedded math.deg() :p
17:40 Krock_ well then, it's the same
17:40 Andrey01 so it is unncessary to convert it by hand
17:43 Andrey01 'x =/' is equivalent to 'x = x /' as in c++?
17:44 Krock_ C/C++ and C# are 'x /= n'
17:44 Andrey01 what does '* x' mean also?
17:44 Krock example?
17:45 Andrey01 I don`t understand what you wrote in the beginning: "x = / math.pi * 180 ..."
17:45 Krock the asterisk (*)  is a correction mark
17:45 Krock instead of "x = / math.pi * 180" I actually meant "x = x / math.pi * 180"
17:46 Andrey01 'math.pi * 180' is this converting to degrees, yes?
17:48 Krock no,  1 / math.pi * 180  is
17:52 LaCosa joined #minetest
17:52 Hawk777 joined #minetest
17:52 Andrey01 thanks, in any case
17:53 FreeFull joined #minetest
18:44 Sires Hello any good tips on creating textures? I suck at that
18:57 Sires wai
18:57 Sires is this a proper grass texture: https://imgur.com/WzeDZ6E
18:57 Sires one sec wrong pic
18:57 Sires Here: https://imgur.com/undefined
18:57 Sires wait what
18:58 Sires https://imgur.com/a/PCT0oRt
18:58 Sires this one, this last one, does this grass look ok
19:00 sfan5 it's a bit very green
19:00 sfan5 but that depends on what kind of grass it's supposed to look like
19:00 Sires hmm
19:00 Sires I should be able to just apply some filter to make it less green I guess
19:05 Sires https://imgur.com/undefined
19:05 Sires damn
19:05 Sires one sec
19:05 Sires https://imgur.com/a/p3Qbrwc
19:05 Sires tried making a bit less green, idk if it worked
19:06 Sires https://imgur.com/a/hjWzmB9
19:06 Sires yet another attempt
19:10 adfeno joined #minetest
19:12 adfeno Hi, what is the procedure to “unexplore” parts of the world, so that they can regenerate ? Which level database type allows for this cleanup (including disk space cleanup) ?
19:14 Krock there's a script that deletes entries from the sqlite3 database. dunno whether it also supports other backends
19:14 Sires I'm not sure if it frees space but take a look at: https://github.com/minetest/minetest/blob/master/doc/lua_api.txt#L5029
19:18 submariner joined #minetest
19:30 adfeno Truth is that for smail servers, to avoid the file getting bigger, it would be good to have a command that the admin could use (even if that would require manual insertion of coordinates)
19:31 adfeno I know that there is /deleteblocks but last time I checked it didn't make the file smaller.
19:40 sfan5 sqlite files do not automatically get smaller unless you run "VACUUM" on them while the server is off
19:41 Andrey01 joined #minetest
19:44 adfeno Hm, I see… Thank you for this infomration :)
19:53 FreeFull joined #minetest
20:03 submariner joined #minetest
20:08 specing Any tips on how to implement movement in CSMs? I guess setPlayerControl would be overriden fast through input processing, perhaps I should fake key presses? (and trap relevant ones while CSM is doing its thing?)
20:13 cheapie adfeno: sqlite does have an auto-vacuum option, but I can't imagine the performance would be all that great: https://www.sqlite.org/pragma.html#pragma_auto_vacuum
20:20 Scarecrow joined #minetest
20:33 NetherEran joined #minetest
20:45 adfeno cheapie: Ah I see.
20:45 adfeno Thank you all for the information. :)
21:09 submariner joined #minetest
21:44 submariner joined #minetest
22:04 submariner joined #minetest
22:09 awell joined #minetest
22:13 submariner joined #minetest
22:52 milkt joined #minetest
23:49 ghoti joined #minetest
23:50 perrier joined #minetest

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