Implement the rtp function

#2
This commit is contained in:
zontreck 2025-03-06 16:48:41 -07:00
parent aedef3317c
commit 86ff08b9e7
5 changed files with 113 additions and 0 deletions

View file

@ -3,6 +3,7 @@ using System.Collections.Generic;
using System.IO;
using Vintagestory.API.Client;
using Vintagestory.API.Common;
using Vintagestory.API.Common.CommandAbbr;
using Vintagestory.API.Common.Entities;
using Vintagestory.API.Config;
using Vintagestory.API.MathTools;
@ -137,6 +138,14 @@ namespace AriasServerUtils
.WithDescription("Percentage of players required to sleep before sleeping through the night")
.HandleWith(Events.HandleUpdateASUPSP)
.EndSubCommand()
.BeginSubCommand("rtp")
.RequiresPrivilege(Privilege.controlserver)
.WithArgs(
parsers.Int("maxDistance")
)
.WithDescription("Update RTP Max block distance. Plus and/or minus this distance from player current position")
.HandleWith(Events.HandleUpdateASURTPMax)
.EndSubCommand()
.EndSubCommand()
.BeginSubCommand("help")
.RequiresPrivilege(Privilege.chat)