[mod] Random spawning with /spawn + invitations [rspawn]

User avatar
taikedz
Member
 
Posts: 662
Joined: Sun May 15, 2016 11:11
Location: Scotland, UK
GitHub: taikedz
IRC: DuCake
In-game: DuCake

[mod] Random spawning with /spawn + invitations [rspawn]

by taikedz » Fri Jan 13, 2017 22:44

Causes players to receive a spawn point anywhere on the map. Players will likely spawn veeery far from eachother into prisitine areas.

This is primarily intended to be a server mod, to encourage the independent creation of communities across the map - let players create their own cities, and trek across the map to find eachother!

Features

    * Player is assigned randomized spawn point on joining
    - * Player will respawn at their spawn point if they die.
    -- * If `beds` spawning is active, then beds can be used to reset the players' spawn point.
    * Players will not spawn in spaces that are protected.
    * Commands
    - * Players can return to their spawn point with the `/spawn` command if they have `spawn` privilege.
    - * Players can request a new spawn point by typing `/newspawn` if they have the `newspawn` privilege.
    - * Players can set their spawn point by typing `/setspawn` if they have the `setspawn` privelege.
    - * Players can assign a new random spawn for another player using `/playerspawn` if they have the `spawnadmin` privilege.

In the interest of keeping the game fun and collaborative, a `/spawn invite` function is also included - this allows a player to invite another player to come share their spawn - both players will spawn in the same place when they type '/spawn' or die.

A customizable levvy can be configured to optionally prevent uncontrolled gathering around a spawn. By default, the cost of inviting a player to your spawn is 10 cobblestones. Cheap-o.

Last edited by taikedz on Wed Jan 09, 2019 14:40, edited 11 times in total.
 

KCoombes
Member
 
Posts: 407
Joined: Thu Jun 11, 2015 23:19
Location: SW Florida, USA
In-game: Knatt
 

User avatar
taikedz
Member
 
Posts: 662
Joined: Sun May 15, 2016 11:11
Location: Scotland, UK
GitHub: taikedz
IRC: DuCake
In-game: DuCake

Re: [mod] Random spawn points with /spawn support [rspawn]

by taikedz » Tue Jan 31, 2017 18:16

New feature - spawn_anywhere

New players will be assigned a spawn point somewhere in the vastness of the world... and may not meet another soul for ages.... ;-)
 

FaceDeer
Member
 
Posts: 284
Joined: Sat Aug 29, 2015 19:01
GitHub: FaceDeer

Re: [mod] Random spawn points with /spawn support [rspawn]

by FaceDeer » Tue Jan 31, 2017 20:25

taikedz wrote:New feature - spawn_anywhere

New players will be assigned a spawn point somewhere in the vastness of the world... and may not meet another soul for ages.... ;-)



Excellent, I was thinking of suggesting something like that. :) How about a way to specify a list of "spawn regions" to be randomly picked from, so that for example you could set up a couple of different towns and have players randomly be citizens of a particular one?
 

KongarTheTerrible
New member
 
Posts: 2
Joined: Thu Feb 02, 2017 18:33

Re: [mod] Randomly assigned spawn with /spawn support [rspaw

by KongarTheTerrible » Thu Feb 02, 2017 22:58

Tons of error on install?
"Runtime error from mod 'rspawn' in callback environment_Step()
builtin/common/helpers.lua:515...
init.lua:41 'newspawn'
177: in function 'func'

etc
 

User avatar
taikedz
Member
 
Posts: 662
Joined: Sun May 15, 2016 11:11
Location: Scotland, UK
GitHub: taikedz
IRC: DuCake
In-game: DuCake

Re: [mod] Randomly assigned spawn with /spawn support [rspaw

by taikedz » Fri Feb 03, 2017 00:08

Hmm bizarre

Check your debug.log pls and paste the actual error text?

What version of minetest?
 

User avatar
taikedz
Member
 
Posts: 662
Joined: Sun May 15, 2016 11:11
Location: Scotland, UK
GitHub: taikedz
IRC: DuCake
In-game: DuCake

Re: [mod] Randomly assigned spawn with /spawn support [rspaw

by taikedz » Fri Feb 03, 2017 12:26

Line 41 is a debug line, I've turned it off in the latest code version, please try that.

If you are still getting issues, you should have a debug.txt log file in your minetest folder. Go to the end of the file to find the corresponding errors, and paste the exact messages here, or open an issue at https://github.com/taikedz/minetest-rspawn/issues
 

User avatar
taikedz
Member
 
Posts: 662
Joined: Sun May 15, 2016 11:11
Location: Scotland, UK
GitHub: taikedz
IRC: DuCake
In-game: DuCake

Re: [mod] Random spawn points with /spawn support [rspawn]

by taikedz » Fri Feb 03, 2017 12:29

FaceDeer wrote:
taikedz wrote:New feature - spawn_anywhere

New players will be assigned a spawn point somewhere in the vastness of the world... and may not meet another soul for ages.... ;-)



Excellent, I was thinking of suggesting something like that. :) How about a way to specify a list of "spawn regions" to be randomly picked from, so that for example you could set up a couple of different towns and have players randomly be citizens of a particular one?


That would be neat. Not sure I want to burden this version with yet another type of spawning though :-P

It would be fairly easily done though - maintain a table of position & radius pairs, pick one, then kick off the randomized spawn with that position as the target....
 

User avatar
taikedz
Member
 
Posts: 662
Joined: Sun May 15, 2016 11:11
Location: Scotland, UK
GitHub: taikedz
IRC: DuCake
In-game: DuCake

Re: [mod] Randomly assigned spawn with /spawn support [rspaw

by taikedz » Sat Dec 29, 2018 16:47

Updated - this is very much geared towards use on a server, so now the randomized spawns are generated in advance so that new players receive their spawn points instantaneously.
 

User avatar
taikedz
Member
 
Posts: 662
Joined: Sun May 15, 2016 11:11
Location: Scotland, UK
GitHub: taikedz
IRC: DuCake
In-game: DuCake

Re: [mod] Randomly assigned spawn with /spawn support [rspaw

by taikedz » Wed Jan 09, 2019 14:31

Further updated to support inviting other players to your own spawn.

This should allow groups of players to start their own towns/cities far away from eachother, and encourage them to find eachother by trekking the distance...!
 

bell07
Member
 
Posts: 542
Joined: Sun Sep 04, 2016 15:15
GitHub: bell07

Re: [mod] Random spawning with /spawn + invitations [rspawn]

by bell07 » Thu Jan 10, 2019 08:32

Great Mod!

For reference: my startanode mod does have some similar logic but for singlenode-worlds.

Can you pls. add a settings "min_pos_x" / "max_pos_x", "min_pos_z" / "max_pos_z" or just "radius" instead of hardcoded "-30000,30000"? So the server owner can decide how far the player should spawn to each other and may leave uninhabited areas to explore.
 

User avatar
taikedz
Member
 
Posts: 662
Joined: Sun May 15, 2016 11:11
Location: Scotland, UK
GitHub: taikedz
IRC: DuCake
In-game: DuCake
 


Return to WIP Mods



Who is online

Users browsing this forum: No registered users and 4 guests