[Mod] Show bones [showbones]

User avatar
ExeterDad
Member
 
Posts: 1717
Joined: Sun Jun 01, 2014 20:00
Location: New Hampshire U.S.A
In-game: ExeterDad

[Mod] Show bones [showbones]

by ExeterDad » Sat Sep 03, 2016 19:55

Saves bones locations to text file. Then player can choose to locate bones via waypoints

Showbones

This mod saves the locations of player bones in a text file "database" in the world directory. Player can use new chat command "/showbones" to show waypoints that are visible anywhere in world showing the direction and distance to all recorded bones up to the server limit (3 by default). Waypoints are removed and updated as player, or other players dig them. If player is online when another player digs thier bones, a chat message will appear letting him/her know of the crime. :)

If a player has left more than the server limit (default 3) of bones lying around the world, the oldest ones are removed from the world as the new one is created. Waypoints are numbered 1 - server limit. The newest/latest bones would be 1. Bones waypoints may be hidden by using the /showbones chat command again.

This mod was created in hopes of relieving the frusteration of players and admins trying to locate lost bones. There is also the added bonus that server admins will no longer need to clean up messy, discarded bones from all around the server. This mod will only track bones lost from the time of install. It also will not track bones placed from inventory.

License: Source code LGPL 2.1
Credits: PilzAdam - The creator of the bones mod. Some code copied (on_punch function) for a needed override.
And to Rubenwardy. His awesome modding book and this datastorage snippet that I based my storage off of.

Adds chat command: /showbones Adds privilege: None at this time

Dependencies: bones

Code quality: I don't want to talk about it. I'm completely new at lua.

Download zip from Github: https://github.com/ExeterDad/showbones/ ... master.zip
Browse code: https://github.com/ExeterDad/showbones

A quick screenshot recycled from another post. Taken at sunset to see waypoint text easier.
Image

I guess this is my first mod that actually does something. I don't claim to know how to lua, so please be kind when reporting bugs or code improvements. I've much to learn and this was a fun exercise.
Last edited by ExeterDad on Sun Sep 04, 2016 00:12, edited 1 time in total.
 

User avatar
bigfoot
Member
 
Posts: 203
Joined: Fri Sep 02, 2016 23:31
Location: Somewhere between polar bears and penguins.
GitHub: bigfoot547
IRC: bigfoot547 or bigfoot
In-game: bigfoot547 or bigfoot

Re: [Mod] Show bones [showbones]

by bigfoot » Sat Sep 03, 2016 21:22

+100
I tried your mod and I think it is very good!

P.S. Your code looks good!

EDIT: The bone "pruning" works very well!
God's not dead, He's surely alive!
My Stuff | My User Page | Check out my website!
<bigfoot547> I major in existing. | <RedPanda246> Not every day is good, but there is good in every day.
Stay elusive ⓐⓝⓓ ⓣⓐⓛⓚ ⓘⓝ ⓒⓘⓡⓒⓛⓔⓢ!
 

User avatar
ExeterDad
Member
 
Posts: 1717
Joined: Sun Jun 01, 2014 20:00
Location: New Hampshire U.S.A
In-game: ExeterDad

Re: [Mod] Show bones [showbones]

by ExeterDad » Sat Sep 03, 2016 21:30

bigfoot547 wrote:+100
I tried your mod and I think it is very good!

P.S. Your code looks good!

EDIT: The bone "pruning" works very well!

Thanks for the feedback. I'm all smiles :D
 

User avatar
Onyx
Member
 
Posts: 104
Joined: Fri Sep 25, 2015 08:36
Location: Steinheim-NodesNation
In-game: onyx58

Re: [Mod] Show bones [showbones]

by Onyx » Sun Sep 04, 2016 07:17

Hi,

This mod is very well thought out and very useful to players. Keep it up!
"Science sans conscience n'est que ruine de l'âme."
-----------------------------------------------------------------------------------------
Steinheim NodesNation : steinheim-minetest.servegame.com Pt : 28000
 

User avatar
Krock
Developer
 
Posts: 4152
Joined: Thu Oct 03, 2013 07:48
Location: Switzerland
GitHub: SmallJoker

Re: [Mod] Show bones [showbones]

by Krock » Sun Sep 04, 2016 07:35

Worst mod ever. Everybody would find their bones easily and not leave any (maybe) worthful stuff inside.
Without this mod it was much easier to find some interesting items in the bones!!¨111¨!!
-----

Just kidding. Already lost my whole inventory items sometimes because I was not able to find my death position again. This mod will know the position whenever I can't find my bones, nice :)
Mod Search Engine - Mods by Krock - DuckDuckGo mod search bang: !mtmod <keyword here>
 

User avatar
azekill_DIABLO
Member
 
Posts: 7461
Joined: Wed Oct 29, 2014 20:05
Location: OMICRON
GitHub: azekillDIABLO
In-game: azekill_DIABLO

Re: [Mod] Show bones [showbones]

by azekill_DIABLO » Sun Sep 04, 2016 13:36

Just kidding. Already lost my whole inventory items sometimes because I was not able to find my death position again. This mod will know the position whenever I can't find my bones, nice :)


yeah, nice mod.
 

User avatar
ExeterDad
Member
 
Posts: 1717
Joined: Sun Jun 01, 2014 20:00
Location: New Hampshire U.S.A
In-game: ExeterDad

Re: [Mod] Show bones [showbones]

by ExeterDad » Sun Sep 04, 2016 14:49

Krock wrote:Worst mod ever. Everybody would find their bones easily and not leave any (maybe) worthful stuff inside.
Without this mod it was much easier to find some interesting items in the bones!!¨111¨!!
-----

Just kidding. Already lost my whole inventory items sometimes because I was not able to find my death position again. This mod will know the position whenever I can't find my bones, nice :)

Ha! That was awesome Krock! I read that on my cellphone while zoomed so I didn't see the kidding part until much later. I was totally going to remove you from my Christmas Card mailing list. lol
 

User avatar
azekill_DIABLO
Member
 
Posts: 7461
Joined: Wed Oct 29, 2014 20:05
Location: OMICRON
GitHub: azekillDIABLO
In-game: azekill_DIABLO
 

User avatar
duane
Member
 
Posts: 1274
Joined: Wed Aug 19, 2015 19:11
Location: Oklahoma City
GitHub: duane-r

Re: [Mod] Show bones [showbones]

by duane » Sun Sep 04, 2016 18:17

Very nice.

I don't understand why we do corpse runs in minetest anyway. The only thing they were ever good for was delaying people reentering pvp battles. Since the Ultima days, pretty much everyone has agreed that it was a bad idea to let player killers loot corpses. Most games now just start you back at a previous save/spawn point, with your equipment.

Personally, I just delete the whole bones mod and don't worry about it.
Believe in people and you don't need to believe anything else.
 

Byakuren
Member
 
Posts: 816
Joined: Tue Apr 14, 2015 01:59
GitHub: raymoo
IRC: Hijiri
In-game: Raymoo + Clownpiece

Re: [Mod] Show bones [showbones]

by Byakuren » Sun Sep 04, 2016 20:07

I think it depends on the overall gameplay direction. Just because looting was bad in some games, it doesn't necessarily mean it's bad for all games, but a game where pvp is meant to be a focus might benefit from giving incentives to killing. Ultima clearly tries to discourage frequent player killing, so it's not a wonder that they would take a design direction that removes some rewards from it. I agree though that it probably does not contribute to servers where there isn't meant to be significant fighting.
Every time a mod API is left undocumented, a koala dies.
 

User avatar
everamzah
Member
 
Posts: 490
Joined: Thu Jan 29, 2015 00:47
GitHub: everamzah
IRC: everamzah
In-game: everamzah

Re: [Mod] Show bones [showbones]

by everamzah » Sun Sep 04, 2016 20:28

To the victor goes the spoils.

Bones mod doesn't need to be deleted in 0.4.14-dev, as there is now a bones_mode setting to disable it.

This mod looks important, perhaps should be directed to minetest_game!
 

User avatar
ExeterDad
Member
 
Posts: 1717
Joined: Sun Jun 01, 2014 20:00
Location: New Hampshire U.S.A
In-game: ExeterDad

Re: [Mod] Show bones [showbones]

by ExeterDad » Mon Sep 05, 2016 22:51

If anyone is using this mod for a server or a world that has multiple players... I discovered a bug that crashes the server if a player digs another players bones that is offline. It was a misnamed variable by me. It's fixed now.

Also I added a feature from my mental roadmap. When online, and someone digs your bones, there are several different random notification chat messages that will be announced.
 

User avatar
ExeterDad
Member
 
Posts: 1717
Joined: Sun Jun 01, 2014 20:00
Location: New Hampshire U.S.A
In-game: ExeterDad

Re: [Mod] Show bones [showbones]

by ExeterDad » Tue Sep 20, 2016 01:52

Fixed a bug where sometimes Bones waypoints weren't removed immediately when bones were dug.
Feature added - The colors of the Bones waypoint texts reflect the age of your bones according to when they can be looted by others. Green, Yellow and Red. Red can be looted.

I set up three bones in this screenshot. And took the pic after a yellow one turned red and I didn't notice. The texts in the waypoints also vary according to age (fresh, aging and old).
Image
 

hajo
Member
 
Posts: 596
Joined: Thu Oct 13, 2016 10:45
Location: DE

Re: [Mod] Show bones [showbones]

by hajo » Fri Oct 21, 2016 10:38

ExeterDad wrote:Saves bones locations to text file. Then player can choose to locate bones via waypoints
..
If a player has left more than the server limit (default 3) of bones lying around the world, the oldest ones are removed

It would be nice if empty bones would be removed first,
or more generally, those where the contents have the least value.
 

User avatar
azekill_DIABLO
Member
 
Posts: 7461
Joined: Wed Oct 29, 2014 20:05
Location: OMICRON
GitHub: azekillDIABLO
In-game: azekill_DIABLO

Re: [Mod] Show bones [showbones]

by azekill_DIABLO » Fri Oct 21, 2016 17:36

i would prefer them to turn white or grey when old. Red should be the indicaion that they will soon become old.
 

User avatar
ExeterDad
Member
 
Posts: 1717
Joined: Sun Jun 01, 2014 20:00
Location: New Hampshire U.S.A
In-game: ExeterDad

Re: [Mod] Show bones [showbones]

by ExeterDad » Fri Oct 21, 2016 23:11

hajo wrote:
ExeterDad wrote:Saves bones locations to text file. Then player can choose to locate bones via waypoints
..
If a player has left more than the server limit (default 3) of bones lying around the world, the oldest ones are removed

It would be nice if empty bones would be removed first,
or more generally, those where the contents have the least value.

That's a very good suggestion. If a player were to die too many times trying to find the lost bones loaded with important loot, it's very possible the older bones with the loot would be removed leaving the recent ones that could possibly have nothing.
I've haven't had the opportunity to try code related to inventory, but it doesn't seem like it would be too hard for me to figure out. I'm not tempted to try to determine what items in the bones have the most "value", but counting and comparing used slots doesn't seem too hard and shouldn't be too heavy.

Thanks so much for your imput :)
 

User avatar
ExeterDad
Member
 
Posts: 1717
Joined: Sun Jun 01, 2014 20:00
Location: New Hampshire U.S.A
In-game: ExeterDad

Re: [Mod] Show bones [showbones]

by ExeterDad » Fri Oct 21, 2016 23:20

azekill_DIABLO wrote:i would prefer them to turn white or grey when old. Red should be the indicaion that they will soon become old.

I chose these colors as I believe (I could be wrong) these colors have the same meaning with traffic signals, pressure gauges, and many other items worldwide.
However I am very open to considering a different color scheme as long as it is intuitive to a average player.
What would you suggest for the color of bones that are fresh?
 

User avatar
azekill_DIABLO
Member
 
Posts: 7461
Joined: Wed Oct 29, 2014 20:05
Location: OMICRON
GitHub: azekillDIABLO
In-game: azekill_DIABLO

Re: [Mod] Show bones [showbones]

by azekill_DIABLO » Sat Oct 22, 2016 10:06

fresh bones: black, medium aged bones: grey, old bones : greywhite, recoltable: bright white!

may not be a greyt idea. but i think it's the most significant thing for me.
 

User avatar
ExeterDad
Member
 
Posts: 1717
Joined: Sun Jun 01, 2014 20:00
Location: New Hampshire U.S.A
In-game: ExeterDad

Re: [Mod] Show bones [showbones]

by ExeterDad » Sat Oct 22, 2016 16:38

azekill_DIABLO wrote:fresh bones: black, medium aged bones: grey, old bones : greywhite, recoltable: bright white!

may not be a greyt idea. but i think it's the most significant thing for me.

So I gave your color suggestions a try and am not crazy with the results lol
Fresh bones with black text are a bear to find in a cave or in the dark.
 

User avatar
azekill_DIABLO
Member
 
Posts: 7461
Joined: Wed Oct 29, 2014 20:05
Location: OMICRON
GitHub: azekillDIABLO
In-game: azekill_DIABLO

Re: [Mod] Show bones [showbones]

by azekill_DIABLO » Sun Oct 23, 2016 10:04

okay, but i think the frsh bones should be red, then orange, then nearly orange grey, and finally white.
 

User avatar
harmony
Member
 
Posts: 410
Joined: Tue Jun 20, 2017 22:16
Location: 고향 ^-^
IRC: ynomrah
In-game: ynomrah

Re: [Mod] Show bones [showbones]

by harmony » Thu Jun 22, 2017 18:01

Omg you made this mod? Lol I never knew that
저는 방탄소년단 를 사랑해요!!! 아미!! 김남준,김석진,민윤기,정호석,박지민,김태형,전정국,방탄소년단!
저는 블랙핑크 를 사랑해요!!! 블링크!! 김지수,김제니,박채영,리사(ปราณ ปริ ยา มโน บาล)
 

User avatar
azekill_DIABLO
Member
 
Posts: 7461
Joined: Wed Oct 29, 2014 20:05
Location: OMICRON
GitHub: azekillDIABLO
In-game: azekill_DIABLO
 

User avatar
texmex
Member
 
Posts: 1067
Joined: Mon Jul 11, 2016 21:08
GitHub: tacotexmex
In-game: texmex

Re: [Mod] Show bones [showbones]

by texmex » Mon Jun 26, 2017 18:23

Nice mod! A bit too "Terminator-like" waypoints for my taste but good nonetheless.
 

User avatar
ExeterDad
Member
 
Posts: 1717
Joined: Sun Jun 01, 2014 20:00
Location: New Hampshire U.S.A
In-game: ExeterDad

Re: [Mod] Show bones [showbones]

by ExeterDad » Mon Jun 26, 2017 19:12

texmex wrote:"Terminator-like"

Ha ha! That's awesome :D
 

User avatar
ManElevation
Member
 
Posts: 895
Joined: Tue Aug 02, 2016 22:04
Location: Madrid,Spain
GitHub: ManElevation
IRC: ManElevation
In-game: ManElevation
 

Next

Return to WIP Mods



Who is online

Users browsing this forum: No registered users and 5 guests