[Mod] Restart Gift [restart_gift]
- ChimneySwift
- Member
- Posts: 320
- Joined: Fri Sep 22, 2017 06:46
- GitHub: ChimneySwift
- IRC: ChimneySwift
- In-game: ChimneySwift
- Location: 127.0.0.1
[Mod] Restart Gift [restart_gift]
Restart Gift
Server restarts and crashes are a necessary but annoying part of the Minetest game, so this mod tries to make them more bearable by giving players who log back in after a restart/crash a little gift.
GitHub
ZIP Download
Code license: MIT
Dependencies: None
Usage
Modify the variables on lines 1 to 7 of init.lua to change gift timeout (amount of time after a restart players who were kicked have to log in bu to receive a gift) in seconds (default: 300 seconds or 5 minutes), gift name (default: "default:mese"), and gift count (default: 1)
Server restarts and crashes are a necessary but annoying part of the Minetest game, so this mod tries to make them more bearable by giving players who log back in after a restart/crash a little gift.
GitHub
ZIP Download
Code license: MIT
Dependencies: None
Usage
Modify the variables on lines 1 to 7 of init.lua to change gift timeout (amount of time after a restart players who were kicked have to log in bu to receive a gift) in seconds (default: 300 seconds or 5 minutes), gift name (default: "default:mese"), and gift count (default: 1)
A spoon is basically a tiny bowl with a stick on it
- AccidentallyRhine
- Member
- Posts: 252
- Joined: Sun Aug 02, 2015 05:43
Re: [Mod] Restart Gift [restart_gift]
The only problem I foresee is that this could incentivize players to abuse issues known to cause server crashes. Though I guess that would also be motivation to actually address server crashes...
- KatzEyez
- Member
- Posts: 50
- Joined: Tue Aug 08, 2017 18:24
- GitHub: KatzPetz
- IRC: LadyK
- In-game: LadyK
- Location: (IG: Depends) (RL: USA)
Re: [Mod] Restart Gift [restart_gift]
It's a neat idea. Probably best used on PvP servers.
You could make the gift something small. Perhaps the gift could be a fruit that isn't available in the game, but admins have access to it, like strawberry, orange or banana.
I have died because of crashes before. It would have been nice to have a small token gift, even if it was just a food item.
The only servers that might not be able to offer gifts would be creative servers, since there's not too much that you can give a player that they're not able to give themselves, unless the owners add some desirable blocks that are hidden from creative.
You could make the gift something small. Perhaps the gift could be a fruit that isn't available in the game, but admins have access to it, like strawberry, orange or banana.
I have died because of crashes before. It would have been nice to have a small token gift, even if it was just a food item.
The only servers that might not be able to offer gifts would be creative servers, since there's not too much that you can give a player that they're not able to give themselves, unless the owners add some desirable blocks that are hidden from creative.
Why wish upon a star when you can pray to the one who created it.
- ChimneySwift
- Member
- Posts: 320
- Joined: Fri Sep 22, 2017 06:46
- GitHub: ChimneySwift
- IRC: ChimneySwift
- In-game: ChimneySwift
- Location: 127.0.0.1
Re: [Mod] Restart Gift [restart_gift]
The issue of players exploiting this feature is real, just by restarting in singleplayer with it enabled while I was debugging I collected a not insignificant quantity of mese blocks, which is why I recommend servers set the item to something like a Cookie, where it doesn't really matter if players have access to lots of them easily.
I may investigate (if enough community interest is shown toward this mod) making it so a gift can be given randomly from a list of items.
I may investigate (if enough community interest is shown toward this mod) making it so a gift can be given randomly from a list of items.
A spoon is basically a tiny bowl with a stick on it
- ThomasMonroe
- Member
- Posts: 286
- Joined: Tue Apr 04, 2017 16:21
- GitHub: ThomasMonroe314
- IRC: ThomasMonroe TMcSquared
- In-game: ThomasMonroe TMcSquared
- Location: Wherever I am at
Re: [Mod] Restart Gift [restart_gift]
COOOOKKKIIIIEEESSSSS
Everyone like cookies!
Everyone like cookies!
I don't make messes, I just, er...disturb the local entropy!
- AccidentallyRhine
- Member
- Posts: 252
- Joined: Sun Aug 02, 2015 05:43
Re: [Mod] Restart Gift [restart_gift]
If you configure your server to use this mod, it would be nice to set
ask_reconnect_on_crash = true
and
kick_msg_crash = There was an issue but you may reconnect to receive a free cookie.
ask_reconnect_on_crash = true
and
kick_msg_crash = There was an issue but you may reconnect to receive a free cookie.
-
- Member
- Posts: 818
- Joined: Tue Apr 14, 2015 01:59
- GitHub: raymoo
- IRC: Hijiri
- In-game: Raymoo + Clownpiece
Re: [Mod] Restart Gift [restart_gift]
There could be a cooldown time so that players are limited to one restart bonus per X hours or something like that.
Every time a mod API is left undocumented, a koala dies.
- ChimneySwift
- Member
- Posts: 320
- Joined: Fri Sep 22, 2017 06:46
- GitHub: ChimneySwift
- IRC: ChimneySwift
- In-game: ChimneySwift
- Location: 127.0.0.1
Re: [Mod] Restart Gift [restart_gift]
Yeah I'm going to look into doing that, should be doable with a bit of reworking, I'd have to have a separate database to record who has been rewarded or something like that, I'll look into it, LadyK actually mentioned a similar idea to me via PM so I'm glad to hear others agree.Byakuren wrote:There could be a cooldown time so that players are limited to one restart bonus per X hours or something like that.
BTW, your signature is amazing
A spoon is basically a tiny bowl with a stick on it
- ManElevation
- Member
- Posts: 896
- Joined: Tue Aug 02, 2016 22:04
- GitHub: ManElevation
- IRC: ManElevation
- In-game: ManElevation
- Location: Madrid,Spain
Re: [Mod] Restart Gift [restart_gift]
ah nice mod, does it send them a message too?
My Public Mods! Discord: Rottweiler Games#3368
- ChimneySwift
- Member
- Posts: 320
- Joined: Fri Sep 22, 2017 06:46
- GitHub: ChimneySwift
- IRC: ChimneySwift
- In-game: ChimneySwift
- Location: 127.0.0.1
Re: [Mod] Restart Gift [restart_gift]
yep!ManElevation wrote:does it send them a message too?
"We're sorry you were kicked, have <gift quantity> <gift description> as a thank you gift for coming back :)"
You can modify it on line 50 of init.lua if you wish.
A spoon is basically a tiny bowl with a stick on it
Re: [Mod] Restart Gift [restart_gift]
This is the type of mods that I like to see, along with your sendstack and temp_priv mods, as they actually give something unique to the game. Nothing wrong with the other mods here, but there are so many variations of the same type of mod or do basically the same thing. Good job and thank you for your contributions.
- ManElevation
- Member
- Posts: 896
- Joined: Tue Aug 02, 2016 22:04
- GitHub: ManElevation
- IRC: ManElevation
- In-game: ManElevation
- Location: Madrid,Spain
Re: [Mod] Restart Gift [restart_gift]
sounds greatChimneySwift wrote:yep!
"We're sorry you were kicked, have <gift quantity> <gift description> as a thank you gift for coming back :)"
You can modify it on line 50 of init.lua if you wish.
My Public Mods! Discord: Rottweiler Games#3368
Who is online
Users browsing this forum: No registered users and 36 guests