[Mod] Online Players [online_players]

User avatar
bosapara
Member
 
Posts: 531
Joined: Fri Apr 07, 2017 08:49
GitHub: bosapara

[Mod] Online Players [online_players]

by bosapara » Tue Sep 03, 2019 14:49

Online Players
___________________________________________________________________________________________________

Image Download | Github


"Online Players" show player list with skin head and ping info with "/online".

Optional dependency on 'simple_skins' mod. Can show not more 44 players.

Image

P.S. Inspired by MC player list mods
Last edited by bosapara on Wed Sep 25, 2019 16:56, edited 1 time in total.
 

User avatar
runs
Member
 
Posts: 933
Joined: Sat Oct 27, 2018 08:32
GitHub: runsy
 

User avatar
Yvanhoe
Member
 
Posts: 131
Joined: Fri Jul 05, 2019 03:18
Location: Japan

Re: [Mod] Online Players [online_players]

by Yvanhoe » Wed Sep 04, 2019 09:29

Really nice! I can't use skins because of another dependency on my server. Could the dependency be optional?
 

User avatar
bosapara
Member
 
Posts: 531
Joined: Fri Apr 07, 2017 08:49
GitHub: bosapara

Re: [Mod] Online Players [online_players]

by bosapara » Wed Sep 04, 2019 11:08

Yvanhoe wrote:Really nice! I can't use skins because of another dependency on my server. Could the dependency be optional?


Currently works only with simple_skins. What skin mod do you use?
 

User avatar
Yvanhoe
Member
 
Posts: 131
Joined: Fri Jul 05, 2019 03:18
Location: Japan

Re: [Mod] Online Players [online_players]

by Yvanhoe » Wed Sep 04, 2019 12:05

A modified version of appearance, that makes it works kinda ok with clothing. I need to revisit all that, but I know there are several incompatible ways to change skins right now. An optional dependency would make it useful to more people! I bookmarked it anyway. When I get to it I may make a PR or better yet, solve my skins problems in a more satisfying way...
 

User avatar
Miniontoby
Member
 
Posts: 268
Joined: Fri Mar 01, 2019 19:25
Location: The Netherlands
In-game: Miniontoby

Re: [Mod] Online Players [online_players]

by Miniontoby » Wed Sep 04, 2019 15:10

Please put it on content.minetest.net
My English isn't very good because I'm Dutch ---- Check my mod "Doorbell"
 

User avatar
bosapara
Member
 
Posts: 531
Joined: Fri Apr 07, 2017 08:49
GitHub: bosapara

Re: [Mod] Online Players [online_players]

by bosapara » Wed Sep 04, 2019 16:43

Yvanhoe wrote:An optional dependency would make it useful to more people!


Agree. Again, what is skin mod you use? I will try to add 1 more optional dependency.
 

ShadMOrdre
Member
 
Posts: 545
Joined: Mon Dec 29, 2014 08:07
Location: USA
GitHub: ShadMOrdre
In-game: shadmordre

Re: [Mod] Online Players [online_players]

by ShadMOrdre » Wed Sep 04, 2019 17:34

bosapara,

I also use the appearance mod for skins. This mod does not use texture based skins in the traditional way. Appearance, instead, uses skin 'parts' to construct the player skin. I've hacked the mod to work with 3d_armor, but it took some hacking to 3d_armor to make it all work.

Perhaps a different way of creating the 'head' of a player, is to not depend on any skin mod at all.

Use player_api to get the player skin. Then use texture modifiers to extract the players head from the supplied skin and construct a 16x16 texture. You can do all this regardless of the mod supplying the skin.


Shad
MY MODS: lib_ecology lib_materials lib_clouds lib_node_shapes ---- Inspired By: Open Source Virtual World Simulator Opensimulator.
 

User avatar
bosapara
Member
 
Posts: 531
Joined: Fri Apr 07, 2017 08:49
GitHub: bosapara

Re: [Mod] Online Players [online_players]

by bosapara » Wed Sep 04, 2019 17:52

Image Update
______________________________

Added optional dependency, currently for 'simple_skins' mod only


ShadMOrdre wrote:Use player_api to get the player skin.


Thanks you for advices, but i don't use player_api

Miniontoby wrote:Please put it on content.minetest.net


You can download this mod from github.
 

ShadMOrdre
Member
 
Posts: 545
Joined: Mon Dec 29, 2014 08:07
Location: USA
GitHub: ShadMOrdre
In-game: shadmordre

Re: [Mod] Online Players [online_players]

by ShadMOrdre » Wed Sep 04, 2019 18:15

Just wondering, do you play a custom game or MTG? Player_api is part of MTG, and is simply a central access point to player attributes. So, even if you don't think you use it, you might be using it already, if you play MTG.

Alternatively, simply go straight to the source. The idea in my previous post is still usable, regardless of whether you use player_api.

Instead of getting the skin from the skin mod, get the skin from the player object. There are some functions available that enable this. This will, again, allow you to run without the dependencies on the various skin mods.

Your mod, bosapara, I'm just trying to help you make it work for more than just a very outdated skin mod.


Shad
MY MODS: lib_ecology lib_materials lib_clouds lib_node_shapes ---- Inspired By: Open Source Virtual World Simulator Opensimulator.
 

User avatar
bosapara
Member
 
Posts: 531
Joined: Fri Apr 07, 2017 08:49
GitHub: bosapara

Re: [Mod] Online Players [online_players]

by bosapara » Wed Sep 04, 2019 18:47

ShadMOrdre wrote:Just wondering, do you play a custom game or MTG?


Custom, 4.17. Not all using 5.1 of minetest.
 

ShadMOrdre
Member
 
Posts: 545
Joined: Mon Dec 29, 2014 08:07
Location: USA
GitHub: ShadMOrdre
In-game: shadmordre

Re: [Mod] Online Players [online_players]

by ShadMOrdre » Wed Sep 04, 2019 19:07

All the player_api does, is move that stuff out of default mod.

You can make it work for v4.17, simply by having your mods point to it instead of default. In the v5.0 version of MTG, the default mod includes a legacy.lua file, that actually provides the override statements, so you may not necessarily need to update mods, just have default, or optionally the other mods, depend on player_api.

However, player_api is not necessary to do what I am suggesting. Since player_api includes functionality previously in default, you should still be able to access the player object, the one provided by the lua api. This should get you the player skin, without having to know which mod provides the skin. You are asking MT what skin the player is using, not a mod...


Shad
MY MODS: lib_ecology lib_materials lib_clouds lib_node_shapes ---- Inspired By: Open Source Virtual World Simulator Opensimulator.
 

User avatar
Miniontoby
Member
 
Posts: 268
Joined: Fri Mar 01, 2019 19:25
Location: The Netherlands
In-game: Miniontoby

Re: [Mod] Online Players [online_players]

by Miniontoby » Thu Sep 05, 2019 13:28

But when you put it on content.minetest.net we can download the mod easyer than downloading from github
My English isn't very good because I'm Dutch ---- Check my mod "Doorbell"
 

User avatar
bosapara
Member
 
Posts: 531
Joined: Fri Apr 07, 2017 08:49
GitHub: bosapara

Re: [Mod] Online Players [online_players]

by bosapara » Sun Sep 22, 2019 15:53

Mod works now with <= 44 players. Form can be resized x4, depends on player's quantity

Image
 


Return to WIP Mods



Who is online

Users browsing this forum: MyordasMineTest and 8 guests