PVP active in one or more areas
-
- Member
- Posts: 20
- Joined: Thu Mar 19, 2015 18:11
- IRC: luizrpgluiz
- In-game: luizinho
PVP active in one or more areas
would be very good in some future update has just pvp activated in just in one or more areas in minetest.
cdb_HTWLEyTsySH8
- programmingchicken
- Member
- Posts: 540
- Joined: Sat Apr 18, 2015 02:20
- GitHub: pchicken
- IRC: chicken pchicken
- Location: not here
- Contact:
Re: PVP active in one or more areas
there is minetest.register_on_punch() to disable damage, you can easily check the position of the puncher and punchee to see if they are in an area.
<gamerdude> I apologize for the above content
- orwell
- Member
- Posts: 958
- Joined: Wed Jun 24, 2015 18:45
- GitHub: orwell96
- IRC: orwell96_mt
- In-game: orwell
- Location: Raxacoricofallapatorius
Re: PVP active in one or more areas
I implemented PvP active/inactive in areas in my mod:
viewtopic.php?f=9&t=12754
Either use my mod or write your own mod.
Remember that the register_on_punchplayer() does not exist yet in stable 0.4.12, it is available in 0.4.12-dev only.
viewtopic.php?f=9&t=12754
Either use my mod or write your own mod.
Remember that the register_on_punchplayer() does not exist yet in stable 0.4.12, it is available in 0.4.12-dev only.
- programmingchicken
- Member
- Posts: 540
- Joined: Sat Apr 18, 2015 02:20
- GitHub: pchicken
- IRC: chicken pchicken
- Location: not here
- Contact:
Re: PVP active in one or more areas
Oh. I guess since I use dev it works for me. :3
<gamerdude> I apologize for the above content
- everamzah
- Member
- Posts: 490
- Joined: Thu Jan 29, 2015 00:47
- GitHub: everamzah
- IRC: everamzah
- In-game: everamzah
Re: PVP active in one or more areas
I use an AreaStore to mark an area and check if a player is in it on punch: https://github.com/everamzah/dcb/blob/m ... /nopvp.lua -- I imagine this is the entirely wrong way to use AreaStore but it seems to work. I invert the damage instead of disabling it. The red tint shows on the punch, and I wonder if there's a real good way to disable PVP such that no damage is even registered, so that the screen doesn't tint red.
- programmingchicken
- Member
- Posts: 540
- Joined: Sat Apr 18, 2015 02:20
- GitHub: pchicken
- IRC: chicken pchicken
- Location: not here
- Contact:
Re: PVP active in one or more areas
in 0.4.12-dev register_on_punchplayer you can return true to bypass damage.
<gamerdude> I apologize for the above content
- Gael de Sailly
- Member
- Posts: 845
- Joined: Sun Jan 26, 2014 17:01
- GitHub: gaelysam
- IRC: Gael-de-Sailly
- In-game: Gael-de-Sailly gaelysam
- Location: Voiron, France
Re: PVP active in one or more areas
May be used by servers to disable PvP in the spawn. I'll bring this idea to MinetestForFun's server.
Just realize how bored we would be if the world was perfect.
Re: PVP active in one or more areas
The latest Protector Redo allows for PVP to be disabled inside protected areas and a separate setting to protect an area around spawn so noobs don't end up killing one another :)
viewtopic.php?f=9&t=9376#p143164
viewtopic.php?f=9&t=9376#p143164
-
- Member
- Posts: 20
- Joined: Thu Mar 19, 2015 18:11
- IRC: luizrpgluiz
- In-game: luizinho
Re: PVP active in one or more areas
TenPlus1 wrote:The latest Protector Redo allows for PVP to be disabled inside protected areas and a separate setting to protect an area around spawn so noobs don't end up killing one another :)
viewtopic.php?f=9&t=9376#p143164
TenPlus1, I auditioned placing the line of protective pvp = true in minetest.conf and is not working to pvp protection on protected land and I'm using the latest version of minetest which is the 0.4.13
cdb_HTWLEyTsySH8
Re: PVP active in one or more areas
luizrpgluiz: make sure the lines reads as follows (10 is radius protected around spawn):
protector_pvp = true
protector_pvp_spawn = 10
protector_pvp = true
protector_pvp_spawn = 10
-
- Member
- Posts: 1482
- Joined: Fri Apr 19, 2013 16:19
- GitHub: twoelk
- IRC: twoelk
- In-game: twoelk
- Location: northern Germany
Re: PVP active in one or more areas
I might be missing something but could you document these functions in the first post of the mod thread please?TenPlus1 wrote:The latest Protector Redo allows for PVP to be disabled inside protected areas and a separate setting to protect an area around spawn so noobs don't end up killing one another :)
viewtopic.php?f=9&t=9376#p143164
...
make sure the lines reads as follows (10 is radius protected around spawn):
protector_pvp = true
protector_pvp_spawn = 10
some other thoughts that came to me was wether this mod would allow multiple spawns such as some servers use or even allow a list of coordinates as safe-place input.
Re: PVP active in one or more areas
For multiple spawns simple place protection blocks around that area which has the same effect of disabling PVP in that area apart from the owner of the protectors.
Who is online
Users browsing this forum: No registered users and 6 guests