Minetest logo

IRC log for #minetest, 2022-10-11

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

All times shown according to UTC.

Time Nick Message
00:19 sparky4 joined #minetest
00:22 YuGiOhJCJ joined #minetest
00:56 stormchaser3000 joined #minetest
01:05 smk joined #minetest
01:20 Lesha_Vel joined #minetest
01:23 sys4 joined #minetest
01:30 Trifton joined #minetest
01:35 Noisytoot joined #minetest
01:48 Zambyte joined #minetest
02:22 lemonzest joined #minetest
02:38 Zambyte joined #minetest
03:23 Verticen_ joined #minetest
03:43 YuGiOhJCJ joined #minetest
03:56 sparky4 joined #minetest
04:00 MTDiscord joined #minetest
04:52 calcul0n_ joined #minetest
05:33 est31 joined #minetest
06:07 Trifton_ joined #minetest
06:34 TomTom joined #minetest
06:44 Fixer joined #minetest
06:55 appguru joined #minetest
07:00 olliy joined #minetest
07:42 Flabb joined #minetest
08:10 est31 joined #minetest
08:32 Verticen_ joined #minetest
08:37 MiniontobyPI unfortunately I don't think clientmods have access to the list of connected players...:(  -> I have done that
08:38 MiniontobyPI It works fine, but it works if the csm restriction flags are like nearly none, and also when they are higher, but that one is buggier
08:41 lissobone joined #minetest
08:41 lissobone Hello, friends.
08:42 lissobone I am currently making a mod, and there are some questions regarding minetest lua API available.
08:43 lissobone I want to run a certain function periodically, every 2 or 3 seconds. "minetest.register_globalstep()" doesn't seem to cover this as it runs its contents every server tick.
08:43 lissobone What do I do?
08:44 sfan5 you can either use minetest.after to queue a new job every 2 seconds
08:44 ROllerozxa the globalstep dtime argument can be used to make a timer using it. otherwise you can also use minetest.after in a loop, scheduling a function to be run every 2 seconds
08:44 sfan5 or that ^
08:45 lissobone I've tried just using the sine function with the dtime timer as every few seconds it would theoretically reach the number 1, but it isn't reliable due to technical limitations.
08:45 lissobone Thank you, friends, for assistance. I shall fix my code right now.
08:45 sfan5 dtime is the time between the current and last server step
08:46 lissobone I know.
08:46 sfan5 it's approximated constant
08:46 sfan5 so I don't get the idea of using sin() on it
08:47 sfan5 to be clear this is the counter solution -> http://sprunge.us/91F2Wr?lua
08:47 lissobone Because sine is a periodic function, and if you make a timer that adds dtime to a certain timer value (seconds elapsed) every server step, it would presumably work as a timer, but in fact it wouldn't because sine wouldn't always return 1 as dtime is an approximated value, as you have previously stated.
08:48 lissobone Thank you, and there's also another question.
08:48 lissobone A question regarding the mod name.
08:50 ROllerozxa MiniontobyPI: yes, if you read after that message I realised that minetest.get_player_names() does exists and it did in fact work to port the playerlist mod as a CSM
08:51 lissobone So, is anyone here familiar with the american minecraft youtuber "Dream", who is famous for popularizing the manhunt game, consisting of hunters and usually a single speedrunner, with the end goal of the first ones' being to kill the speedrunner, and the latter one's being to finish the game?
08:51 lissobone Well, I accidentally called my mod "minehunt" in the code. I somewhat liked that.
08:51 lissobone Is the name "manhunt" allowed or is it copyrighted?
08:51 lissobone I basically added a compass pointing at the huntee.
08:52 ROllerozxa either names are allowed, there's no other mods that have the same modnames on contentdb
08:53 lissobone Well, thank you. But I'll still think of "minehunt". No, it looks like you're hunting ores in a cave and not players on the surface (or in the same cave).
09:18 lissobone And the final, third question.
09:19 lissobone Should I run minetest.after() once again when my function finishes execution?
09:20 lissobone It would look like this:
09:20 lissobone function foo()
09:20 lissobone ...
09:20 lissobone minetest.after(2, foo)
09:20 lissobone end
09:20 lissobone minetest.after(2, foo)
09:20 lissobone was kicked by ShadowBot: Message flood detected. Use a pastebin like paste.ubuntu.com.
09:20 lissobone joined #minetest
09:20 lissobone Sorry for spamming.
09:24 lissobone Well, minetest.after() definitely works.
09:25 MiniontobyPI Yeah if your code is not too big... (that you put inside the callback)
09:30 sfan5 lissobone: if you want it to happen periodicially then yes you have to
09:40 Meowie_Gamer joined #minetest
09:56 Meowie_Gamer left #minetest
10:57 definitelya joined #minetest
10:58 est31 joined #minetest
10:59 lissobone I've got a different question.
10:59 lissobone How do I check if a player has an item that belongs to a particular item group, if that's possible?
11:02 lissobone For example, I want to check if he has a compass in one of its 16 states (the states of its pointer arrow), and there are 16 respective items.
11:27 sfan5 best to retrieve the entire "main" inventory list and compare the returned items
11:49 definitelya Continuing from #minetest-dev: Why are we trying to adhere the rules on the Play Store? Can't people simply download from F-droid?
11:49 definitelya Also genuine question; would stock Android phones be restricted from running apps which don't appease to those rules?
11:50 definitelya s/adhere/adhere to
11:52 sfan5 to the last: no
11:53 sfan5 to the first: sure people could download from f-droid or even our own APK but google play is where the users are (by default)
11:54 definitelya Alright, thanks sfan
11:55 sfan5 on iOS the situation is: either you play by Apple's rules or you don't get to distribute your app
11:56 cranezhou joined #minetest
11:56 definitelya That's fun, gotta love the duopoly.
12:04 cranez joined #minetest
12:22 Izaya left #minetest
12:23 Izaya joined #minetest
12:26 dabbill_ joined #minetest
12:26 appguru joined #minetest
12:28 proller joined #minetest
12:28 Taoki joined #minetest
12:51 appguru joined #minetest
13:11 lissobone The algebraic modules function normally, as the logs tell, but there's a different problem.
13:12 lissobone I want the compass to change its icon every 3 seconds and point at the speedrunner, but itemstack:set_name("somename") doesn't affect the compass for some reason, even though it returns true, which means that the name has been changed.
13:13 lissobone In my previous mod that very method worked fine when switching the flashlight.
13:16 lissobone What may be wrong?
13:18 specing joined #minetest
13:19 lissobone Would just making a separate hud element with a compass be a better solution?
13:25 lissobone I think so.
13:26 lissobone That simplifies my job.
13:31 rubenwardy lissobone: itemstacks are a copy. If you modify them, you need to set them somewhere
13:31 rubenwardy in some callbacks, you do this be returning the itemstack
13:31 rubenwardy in others, you need to use inventory method
13:32 rubenwardy !book common mistakes
13:32 MinetestBot rubenwardy: Common Mistakes - https://rubenwardy.com/minetest_modding_book//en/quality/common_mistakes.html
13:40 lissobone Thank you, but I am already doing the HUD variant as I think that it would be far better. Just a radar-like compass that would display the direction the speedrunner is in, and if he is too close, it would turn red or something like taht.
13:41 lissobone By the way, your modding book is an amazing source of information for developers.
13:45 jluc joined #minetest
13:47 stormchaser3000 joined #minetest
13:50 kilbith joined #minetest
14:05 est31 joined #minetest
14:13 lissobone I think that using formspecs for configuring the manhunt is an overkill and an overcomplicating move. It would be better to just add the huntee and the hunters through the command line.
14:19 MTDiscord <Warr1024> Probably you'll want to make a Minimum Viable Product as quickly as possible, get some beta testers playing it soon, and get feedback from them about what causes them the most problems.  A beautiful config UI isn't part of an MVP, and might not even be really desired for the final product.
14:20 MTDiscord <Warr1024> For example, it's possible people might want to just configure it once, via minetest.conf, and just run a server with the same settings, and being able to automatically start and stop games might be more useful.  You should base the decision which use-cases to support on actual hard evidence if possible.
15:10 lissobone I have added a specific role that allows a player to control the manhunt, and I think that there will also be 2 commands that would control the game: /startmanhunt and /stopmanhunt (unsurprizingly).
16:06 Alnotz joined #minetest
16:07 sparky4 joined #minetest
16:07 jaca122 joined #minetest
16:12 appguru joined #minetest
16:30 wallabra joined #minetest
16:49 ely-the-kitsune joined #minetest
16:49 fluxionary is there a reason why the object ID of a pointed_thing is signed while object IDs are unsigned everywhere else? https://github.com/minetest/minetest/blob/b3503e7853a52a8c16431f6b983e30c9d25951bc/src/util/pointedthing.h#L60-L64 vs https://github.com/minetest/minetest/blob/b3503e7853a52a8c16431f6b983e30c9d25951bc/src/activeobject.h#L131
16:52 Talkless joined #minetest
17:00 MTDiscord <ROllerozxa> most likely a case of it not being noticed until now :^)
17:00 ___nick___ joined #minetest
17:14 specing joined #minetest
17:15 btdmaster joined #minetest
17:16 sfan5 fluxionary: I bet someone wasn't sure if 0 was valid or not and decided to use -1 for not set
17:19 proller joined #minetest
17:22 fluxionary i saw a negative object ID in a log message and started wondering...
17:31 sparky4 joined #minetest
17:36 proller joined #minetest
17:43 diceLibrarian joined #minetest
17:52 stormchaser3000 joined #minetest
17:58 ely-the-kitsune joined #minetest
17:58 wallabra joined #minetest
18:06 garywhite joined #minetest
18:06 garywhite joined #minetest
19:18 garywhite1 joined #minetest
19:20 Trifton_ joined #minetest
19:46 ely-the-kitsune joined #minetest
19:51 ensayia joined #minetest
19:53 Desour joined #minetest
19:56 Alias joined #minetest
20:28 Verticen_ joined #minetest
20:33 ely-the-kitsune joined #minetest
21:36 Verticen_ joined #minetest
22:06 Desour joined #minetest
22:07 sparky4 joined #minetest
22:08 Lunatrius` joined #minetest
22:20 Trifton joined #minetest
22:38 panwolfram joined #minetest
22:41 sparky4 joined #minetest
23:58 Noisytoot joined #minetest

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