

取决于
-
高级状态
-
纪念碑守望者
-
树枝衰减
-
活动奖励
Works with
-
抱歉,我们找不到!
-
可突袭基地
-
地牢基地
-
经济学
-
临时权限
-
抱歉,您没有权限!
-
工业粪
-
朋友
-
动态 PVP
-
区域管理器
-
复制粘贴
-
图片库
关于Real PvE
真实 PvE 服务器的插件,具有损害预防、反破坏措施、可定制的 PvP 区域、radtown s 和 raid 区域中的自动战利品队列等等。
附言由于之前使用 DynamicPVP 的实现不正确并且存在一些问题,因此我添加了通用钩子(开发人员 API 部分)用于所有 PvP 插件的常规访问,目前 DynamicPVP 中缺少这些插件。我已经要求作者添加它们(3 行),但现在,您需要使用修改后的版本DynamicPVP.cs
- 能够将 “server.pve” 设置为 “true”,这允许服务器具有 “PvE” 标志;
- 当 server.pve 为 true 时,会启用 NPC 的伤害;
- 使用 “server.pve true” 对自己的结构造成伤害的能力;
- 能够不受任何时间限制地摧毁(包括外墙)或旋转结构;
- 能够强制 Twigs 等级的构建块腐烂,即使工具柜中有木头;
- 能够在其他人的 Building Privileges 中切换收集资源限制;
- 除了所有者或其朋友之外,没有人能够打开他们的战利品容器(箱子、储藏室、尸体等);
- 管理员可以绕过战利品限制;
- 如果玩家在其他人的建筑特权中断开连接,则可以安排杀死玩家;
- 禁用背包和主动物品在死亡时掉落,即使背包已满;
- 修改在海滩上生成时提供的物品的能力;
- 能够创建无限数量的自定义权限;
- 允许玩家绕过队列的能力;
- 能够为每个权限设置睡袋、庇护所和自动炮塔的限制;
- 能够为每个权限设置纪念碑和活动的价格乘数;
- 能够为您的每个自定义权限自定义车辆的价格和数量;
- 能够为每个玩家分配车辆;
- 能够为您的每个自定义权限自定义分配的价格和可用车辆数量;
- 分配的车辆不能被其他玩家损坏、掠夺或推动,但如果它在其他人的建筑特权范围内,则可以被推动;
- 通过排队系统掠夺纪念碑的能力;
- 能够配置纪念碑,设置其掠夺价格和时间,以及调整每个纪念碑的状态栏;
- 能够通过购买获得掠夺事件(直升机、布拉德利和可突袭基地)的特权;
- 能够自定义每种事件类型和战利品尝试(生命)的价格;
- NPC 只攻击正在掠夺纪念碑、事件或可突袭基地的玩家;
- 只有掠夺纪念碑、事件或可突袭基地的玩家才能对 NPC 造成伤害;
- RaidableBase 受到保护,免受恶意破坏(无损坏、无战利品等)。只有所有者可以与 RAID 交互;
- 可以购买中立的 RaidableBases;
- 购买中立突袭的价格可针对每个难度级别进行配置;
- 可配置的 RAID 限制(当前可用)以及每个权限的购买折扣乘数。
文件位置:*SERVER*\oxide\data\RealPVE\PermissionConfig.json
默认值:https://pastebin.com/5VtWZZVr
所有权限都在配置文件的 “List of permissions” 部分下创建和配置。
您可以根据需要创建任意数量的权限并灵活地自定义它们。
建议在权限名称中使用前缀 “realpve”,例如:“realpve.vip”。
注意:第一个权限将用作没有任何权限的用户的默认权限。
{
"List of permissions. NOTE: The first permission will be used by default for those who do not have any permissions.": [
{
"Permission Name": "realpve.default",
"Bypass Queue": false,
"Limit of beds": 15,
"Limit of shelters": 1,
"Limit of auto turrets": 12,
"Seconds that will be skipped when opening HackableLockedCrate": 0.0,
"Monuments price multiplier": 1.0,
"Events price multiplier": 1.0,
"Limit of RaidableBases(at the time)": 1,
"RaidableBases price multiplier": 1.0,
"Vehicles settings": {
"Horse": {
"Limit": 1,
"Price": 10.0
},
"Bike": {
"Limit": 1,
"Price": 5.0
},
"MotorBike": {
"Limit": 1,
"Price": 20.0
},
"Car": {
"Limit": 1,
"Price": 25.0
},
...
}
},
{
"Permission Name": "realpve.vip",
"Bypass Queue": true,
"Limit of beds": 20,
"Limit of shelters": 2,
"Limit of auto turrets": 15,
"Seconds that will be skipped when opening HackableLockedCrate": 450.0,
"Monuments price multiplier": 0.9,
"Events price multiplier": 0.9,
"Limit of RaidableBases(at the time)": 2,
"RaidableBases price multiplier": 0.9,
"Vehicles settings": {
"Horse": {
"Limit": 5,
"Price": 9.0
},
"Bike": {
"Limit": 5,
"Price": 4.5
},
"MotorBike": {
"Limit": 5,
"Price": 18.0
},
"Car": {
"Limit": 5,
"Price": 22.5
},
...
}
}
],
"Version": {
"Major": 0,
"Minor": 1,
"Patch": 1
}
}
使用默认权限的 monument/event/rb 乘数示例。
例如,如果您将 Harbor 的价格设置为 1000 美元,则具有默认权限 (1.0) 的玩家将支付 1000 美元 * 1 = 1000 美元。同时,拥有 VIP 权限 (0.9) 的玩家将支付 1000 美元 * 0.9 = 900 美元。但是,如果玩家拥有值为 1.1 的行为不端权限,则需要支付 1000 美元 * 1.1 = 1100 美元。
{
"Chat command": "realpve",
"Chat admin command": "adminpve",
"Is it worth forcibly implementing PvE for a server?": true,
"Is it worth enabling GameTips for messages?": true,
"Is it worth preventing resource gathering in someone else's building privilege area?": false,
"Is it worth preventing the pickup of plants spawned by the server in someone else's building privilege zone?": false,
"Is it worth forcibly blocking damage from the patrol helicopter to building blocks and deployables?": false,
"Is it worth preventing players from handcuffing others?": true,
"Is it worth assigning portals(Halloween and Christmas) to the first player?": true,
"Is it worth preventing a backpack from dropping upon player death?": true,
"Is it worth preventing damage to the laptop of the Hackable Crate?": true,
"Is it worth removing the penalties for recyclers in safe zones?": true,
"Is it worth allowing all players to pick up items dropped by others? If enabled, personal settings will be ignored": false,
"The format that will be used for prices": "${0}",
"Vehicles - Time in seconds to display the marker when searching for a vehicle. A value of 0 disables the marker": 15.0,
"Anti-Sleeper - Time in seconds after which a player will be killed if they disconnect while inside someone else's Building Privilege. Set to 0 to disable": 1200.0,
"Is it worth enabling support for the 'Npc Random Raids' plugin?": true,
"Is friendly fire enabled by default when creating a new team?": false,
"PvP - Is it worth adding map markers for PvP zones?": true,
"PvP - Name of the map maker": "PvP Zone!",
"PvP - Settings for the status bar": {
"Order": 9,
"Height": 26,
"Main_Color(Hex or RGBA)": "1 0.39 0.28 0.7",
"Main_Transparency": 0.8,
"Main_Material": "",
"Image_Url": "https://i.imgur.com/oi5vIkk.png",
"Image_Local(Leave empty to use Image_Url)": "RealPVE_PvP",
"Image_Sprite(Leave empty to use Image_Local or Image_Url)": "",
"Image_IsRawImage": false,
"Image_Color(Hex or RGBA)": "1 0.39 0.28 1",
"Image_Transparency": 1.0,
"Is it worth enabling an outline for the image?": false,
"Image_Outline_Color(Hex or RGBA)": "0.1 0.3 0.8 0.9",
"Image_Outline_Transparency": 0.0,
"Image_Outline_Distance": "0.75 0.75",
"Text_Size": 12,
"Text_Color(Hex or RGBA)": "1 1 1 1",
"Text_Font(https://umod.org/guides/rust/basic-concepts-of-gui#fonts)": "RobotoCondensed-Bold.ttf",
"Is it worth enabling an outline for the text?": false,
"Text_Outline_Color(Hex or RGBA)": "#000000",
"Text_Outline_Transparency": 1.0,
"Text_Outline_Distance": "0.75 0.75",
"SubText_Size": 12,
"SubText_Color(Hex or RGBA)": "1 1 1 1",
"SubText_Font": "RobotoCondensed-Bold.ttf",
"Is it worth enabling an outline for the sub text?": false,
"SubText_Outline_Color(Hex or RGBA)": "0.5 0.6 0.7 0.5",
"SubText_Outline_Transparency": 0.0,
"SubText_Outline_Distance": "0.75 0.75"
},
"PvP - Settings for the progress status bar": {
"Main_Color(Hex or RGBA)": "1 1 1 0.15",
"Main_Transparency": 0.15,
"Progress_Reverse": true,
"Progress_Color": "#FF6347",
"Progress_Transparency": 0.7,
"Progress_OffsetMin": "0 0",
"Progress_OffsetMax": "0 0"
},
"Wipe ID": null,
"Version": {
"Major": 0,
"Minor": 1,
"Patch": 15
}
}

英文: https://pastebin.com/ZMUL6pYL
RUS: https://pastebin.com/Mx8cbMts
Main commands(/realpve) :
- autobuy – Toggle autobuy for monuments, vanilla events and raid bases with a total price greater than 0;
- pickup – Toggle access to pick up your items from the ground for all players;
- share – Manage access to looting your entities by other players(outside of the team):
- status *entityID*(optional) – Display information about the settings of the entity you are looking at or the one you specified;
- add *nameOrID* *entityID*(optional) – Add the specified player to the entity list you are looking at or the one you specified;
- remove *nameOrID* *entityID*(optional) – Remove the specified player from the entity list you are looking at or the one you specified;
- toggle *entityID*(optional) – Toggle the entity list you are looking at or the one you specified;
- delete *entityID*(optional) – Delete the settings for the entity you are looking at or the one you specified;
- clear – Delete the settings for all your entities.
- team – Manage your team:
- ff – Toggle the ability to damage your teammates.
- vehicle – Manage your vehicles:
- list – List of IDs for all your vehicles;
- find *vehicleID*(optional) – Help finding the vehicle you are looking at or the one you specified;
- unlink *vehicleID*(optional) – Unlink the vehicle you are looking at or the one you specified;
- clear – Unlink all your vehicles.
Admin commands(/adminpve). Permission “realpve.admin” required:
- autobuy – Manage autobuy for monuments, vanilla events and raid bases:
- *nameOrId* – Toggle autobuy for the specified player;
- force monument/event/rb – Toggle forced autobuy. If enabled, player settings will be ignored;
- clear – Disable autobuy for everyone.
- config – Manage settings for values in the configuration file:
- forcepve *boolValue*(optional) – Is it worth forcibly implementing PvE for a server?
- forcetutorial *boolValue*(optional) – Is it worth forcing the tutorial mode support?
- gametips *boolValue*(optional) – Is it worth enabling GameTips for messages?
- perm_limits *boolValue*(optional) – Is it worth rechecking the limits when removing permissions?
- safe_death *boolValue*(optional) – Is it worth preventing death on logout in safe zones?
- heli_damage *boolValue*(optional) – Is it worth forcibly blocking damage from the patrol helicopter to building blocks and deployables?
- handcuffs *boolValue*(optional) – Is it worth assigning portals(Halloween and Christmas) to the first player?
- portals *boolValue*(optional) – Is it worth preventing players from handcuffing others?
- backpack_drop *boolValue*(optional) – Is it worth preventing a backpack from dropping upon player death?
- laptop_damage *boolValue*(optional) – Is it worth preventing damage to the laptop of the Hackable Crate?
- recycler_safezone *boolValue*(optional) – Is it worth removing the penalties for recyclers in safe zones?
- item_pickup *boolValue*(optional) – Is it worth allowing all players to pick up items dropped by others? If enabled, personal settings will be ignored;
- safe_sleep *boolValue*(optional) – Is it worth protecting sleeping players from animals?
- loot_privilege *stringValues* – Entities spawned by the server allowed to be looted in someone else’s building privilege zone(None, Wood, Ore, Flesh, Collectible, All) ;
- priceformat *stringValue* – The format that will be used for prices;
- vehicle_marker_time *floatValue* – Vehicles – Time in seconds to display the marker when searching for a vehicle. A value of 0 disables the marker;
- antisleeper *floatValue* – Anti-Sleeper – Time in seconds after which a player will be killed if they disconnect while inside someone else’s Building Privilege. Set to 0 to disable;
- randomraids *boolValue*(optional) – Is it worth enabling support for the ‘Npc Random Raids’ plugin?
- teamff *boolValue*(optional) – Is friendly fire enabled by default when creating a new team?
- pvpmarkers *boolValue*(optional) – PvP – Is it worth adding map markers for PvP zones?
- pvpmarkersname *stringValue* – PvP – Name of the map maker.
- loot – Manage player access to entities without restrictions:
- *nameOrId* – Toggle unrestricted access for the specified player;
- self – Toggle unrestricted access for yourself;
- clear – Revoke unrestricted access for all players.
- monument – Manage monuments:
- list – List of available monuments;
- ignore *nameOrID* *boolValue* – Add or remove a player from the monument entry ignore list;
- *monumentID*/this – Instead of the monumentID, you can use the word “this“, but you must be inside the monument:
- suffix *boolValue*(optional) – Toggle the suffix display in the monument’s name;
- broadcast *boolValue*(optional) – Toggle notifications about monument occupancy/release;
- time *intValue* – Set the looting time limit for the monument in seconds;
- price *floatValue* – Set the cost for looting rights. A value of 0 makes the monument free;
- offer *floatValue* – Set the offer duration for purchasing the monument in seconds;
- map_mode *intValue* – Set the marker display mode on the map. 0 – disabled, 1 – enabled, 2 – enabled during PvP mode;
- map_circle *boolValue*(optional) – Toggle the display of the monument’s circle marker on the map;
- pvp *boolValue*(optional) – Toggle PvP mode for the monument;
- pvp_delay *floatValue* – Set the PvP mode duration in seconds for players after leaving the PvP monument;
- bar_progress *boolValue*(optional) – Toggle between TimeProgressCounter and TimeCounter bars for the monument.
- perm – Manage permissions:
- add *permName* – Adds a new permission to the list by copying values from the first(default) permission in the list. If the permission name starts with ‘realpve’, it will also register a new permission;
- add *permName* *sourcePermName* – Adds a new permission to the list by copying values from an existing permission in the list;
- remove *permName* – Removes an existing permission from the list;
- edit *permName* – Edits a permission:
- queue – Toggle the permission to bypass the server queue;
- unlockRespawn – Toggle the availability of the Outpost respawn point;
- beds *intValue* – Restriction on the number of available beds;
- shelters *intValue* – Restriction on the number of available shelters;
- turrets *intValue* – Restriction on the number of available turrets;
- hackable *floatValue* – Number of seconds(0-900) to skip when opening a hackable crate;
- monuments *floatValue* – Price multiplier for monuments;
- events *floatValue* – Price multiplier for vanilla events;
- rb_limit *intValue* – Restriction on the number of raid bases available simultaneously;
- rb_mult *floatValue* – Price multiplier for raid bases;
- vehicles *vehType* – Vehicles settings:
- limit *intValue* – Limit on the number of available vehicles by type;
- price *floatValue* – Price for registering a vehicle by type.
- clear – Removes all permissions from the list except the first one.
- pickup – Manage access to picking up another player’s items from the ground:
- *nameOrId* – Toggle access to picking up a specific player’s items from the ground;
- clear – Revoke access for all players to pick up items from the ground.
- share – Manage access to looting entities by other players(outside of the team):
- status *entityID*(optional) – Display information about the settings of the entity you are looking at or the one you specified;
- add *nameOrID* *entityID*(optional) – Add the specified player to the entity list you are looking at or the one you specified;
- remove *nameOrID* *entityID*(optional) – Remove the specified player from the entity list you are looking at or the one you specified;
- toggle *entityID*(optional) – Toggle the entity list you are looking at or the one you specified;
- delete *entityID*(optional) – Delete the settings for the entity you are looking at or the one you specified;
- clear *nameOrID*(optional) – Delete the settings for all entities or all entities of the specified player.
- tc – Manage building privilege:
- add self/*entityID* *nameOrID*(optional) – Add yourself or a specified player to the building privilege of the area you or the specified entity are in;
- remove self/*entityID* *nameOrID*(optional) – Remove yourself or a specified player from the building privilege of the area you or the specified entity are in;
- clear self/*entityID* – Clear the list of authorized players in the building privilege of the area you or the specified entity are in;
- info self/*entityID* – Get information about the building privilege of the area you or the specified entity are in.
- vehicle – List of all available vehicle types:
- types – List of available vehicle types.
Example:
- /realpve pickup
- /realpve vehicle find *netID*
- /realpve team ff
- /adminpve config loot_privilege wood, ore
- /adminpve perm add realpve.vip2
- /adminpve perm add realpve.vip2 realpve.vip
- /adminpve perm edit realpve.vip2 queue true
- /adminpve perm edit realpve.vip2 vehicles horse limit 5
- /adminpve monument list
- /adminpve monument *monumentID* pvp
- /adminpve monument *monumentID* price 7.5
- /adminpve loot iiiaka
- /adminpve pickup iiiaka
- /adminpve tc info self
- /adminpve tc info 6959689
- /adminpve vehicle types
该插件提供了领取车辆的能力,从而防止其他玩家的盗窃和恶意破坏。
在权限中,您可以为每种类型的车辆设置价格和数量限制,确保根据您的喜好进行灵活定制。
分配的战车不能被其他玩家损坏、掠夺或推动,但如果它在其他人的建筑特权范围内,则可以被推动。
文件位置: *SERVER*\oxide\data\RealPVE\MonumentConfig.json
默认值: https://pastebin.com/XY1d9YaM
此插件引入了队列系统和纪念碑的战利品购买。
您可以自定义每个纪念碑的掠夺价格和时间。在纪念碑中,只有“掠夺者”和他的朋友们有能力掠夺、捡起物品或伤害实体。
此外,纪念碑中的 NPC 和动物不会攻击其他玩家,也不会受到他们的伤害。
如果玩家在纪念碑内死亡,他们将有一段宽限期可以返回。这使玩家可以安全地掠夺纪念碑,而不必担心破坏。
纪念碑配置示例:
"ferry_terminal_1": {
"Type(This parameter is just a hint. Changes won’t have any effect)": "RadTown",
"Is it worth displaying the suffix(if any) in the monument's name?": true,
"Is it worth notifying all players about the occupation/release of the monument?": true,
"The cost for the right to loot the monument. A value of 0 makes the monument free": 15.0,
"The time in seconds(1-3600) given for looting the monument": 900,
"The time in seconds(1-15) given to make a decision to purchase the monument": 5.0,
"Map marker display mode: 0 - disabled, 1 - enabled, 2 - enabled during PvP mode": 1,
"Is it worth creating a circle in the map marker?": true,
"PvP - Is PvP enabled at this monument? If so, players will be able to kill each other and loot will be publicly accessible": false,
"PvP - The time in seconds(0-60) during which the player retains PvP mode after leaving the PvP monument": 10.0,
"Is it worth using a progress bar for bars with a counter?": true,
"Settings for the status bar": {
"Order": 10,
"Height": 26,
"Main_Color(Hex or RGBA)": "#FFBF99",
"Main_Transparency": 0.8,
"Main_Material": "",
"Image_Url": "https://i.imgur.com/awUrIwA.png",
"Image_Local(Leave empty to use Image_Url)": "RealPVE_ferry_terminal_1",
"Image_Sprite(Leave empty to use Image_Local or Image_Url)": "",
"Image_IsRawImage": false,
"Image_Color(Hex or RGBA)": "#FFDCB6",
"Image_Transparency": 1.0,
"Is it worth enabling an outline for the image?": false,
"Image_Outline_Color(Hex or RGBA)": "0.1 0.3 0.8 0.9",
"Image_Outline_Transparency": 0.0,
"Image_Outline_Distance": "0.75 0.75",
"Text_Size": 12,
"Text_Color(Hex or RGBA)": "1 1 1 1",
"Text_Font(https://umod.org/guides/rust/basic-concepts-of-gui#fonts)": "RobotoCondensed-Bold.ttf",
"Is it worth enabling an outline for the text?": false,
"Text_Outline_Color(Hex or RGBA)": "#000000",
"Text_Outline_Transparency": 1.0,
"Text_Outline_Distance": "0.75 0.75",
"SubText_Size": 12,
"SubText_Color(Hex or RGBA)": "1 1 1 1",
"SubText_Font": "RobotoCondensed-Bold.ttf",
"Is it worth enabling an outline for the sub text?": false,
"SubText_Outline_Color(Hex or RGBA)": "0.5 0.6 0.7 0.5",
"SubText_Outline_Transparency": 0.0,
"SubText_Outline_Distance": "0.75 0.75"
},
"Settings for the progress status bar": {
"Main_Color(Hex or RGBA)": "1 1 1 0.15",
"Main_Transparency": 0.15,
"Progress_Reverse": true,
"Progress_Color": "#FFBF99",
"Progress_Transparency": 0.7,
"Progress_OffsetMin": "0 0",
"Progress_OffsetMax": "0 0"
}
}
- 类型 – 此字段仅用作您的指示器。这些更改不会产生任何影响;
- ShowSuffix — 后缀显示。某些纪念碑(例如 Warehouses)的名称中包含后缀,例如 “Warehouse #12”;
- 广播 – 在纪念碑被占用或腾空时启用或禁用广播;
- LootingTime – 为掠夺纪念碑分配的时间;
- 价格 – 您可以开始掠夺纪念碑的价格。0 表示 looting 是免费的;
- BarSettings – 高级状态栏的设置。
您还可以通过在 “List of tracked types of monuments” 部分下指定来选择纪念碑的类型。
所有可用类型的列表可以在 MonumentsWatcher 页面的 “Developer API” 部分查看。
"List of tracked types of monuments": [
"RadTown",
"RadTownWater",
"RadTownSmall",
"TunnelStation",
"Custom"
]
事件与纪念碑类似,提供了认领事件的机会。
所有事件都在配置文件的 “Settings for the events” 部分下进行配置。
您可以自定义抢劫和抢劫尝试的价格(死亡,包括朋友)。就像在纪念碑中一样,只有 “Looter” 和他的朋友们有能力掠夺和损坏实体。
此外,在事件中,NPC 不会攻击其他玩家。
如果玩家(包括好友)超过死亡限制,则活动将变为免费,从而为其他玩家提供领取活动的机会。
事件配置示例:
{
"Is it worth enabling forced auto-buy for vanilla events where the final price is greater than 0?": false,
"Settings for the PatrolHelicopter events": {
"IsEnabled": true,
"Time in seconds (1-15) given to respond for purchasing this event. Note: This is shown to everyone who deals damage, and the first person to buy it will claim it": 5.0,
"Is it worth removing fire from crates?": true,
"The price to claim the event. A value of 0 means it's free": 50.0,
"The number of deaths after which the event becomes public. A value of 0 disables the limit": 5,
"The time in seconds for which the event is locked to the player. A value of 0 disables the time limit": 1800.0
},
"Settings for the BradleyAPC events": {
"IsEnabled": true,
"Time in seconds (1-15) given to respond for purchasing this event. Note: This is shown to everyone who deals damage, and the first person to buy it will claim it": 5.0,
"Is it worth removing fire from crates?": true,
"The price to claim the event. A value of 0 means it's free": 50.0,
"The number of deaths after which the event becomes public. A value of 0 disables the limit": 5,
"The time in seconds for which the event is locked to the player. A value of 0 disables the time limit": 1800.0
},
"Version": {
"Major": 0,
"Minor": 1,
"Patch": 0
}
}
- Price (价格) – 申领活动的价格。0 表示 looting 是免费的;
- DeathLimit – 死亡限制,超过此限制后,事件将变为免费。
文件位置: *SERVER*\oxide\data\RealPVE\NewbieConfig.json
默认值: https://pastebin.com/QHZCqpji
为主库存给出的物品列表示例:
"List of items for the main inventory": [
{
"ShortName": "note",
"Slot": 0,
"Amount": 1,
"SkinID": 0,
"Text": "MsgNoteText"
}
]
附言在 Text 字段中,您需要指定语言键。或者,你可以只写任何文本,但不会有文本的翻译。
文件位置:*SERVER*\oxide\data\RealPVE\RaidableBasesConfig.json
默认值:https://pastebin.com/rpDng7Fd
与 RaidableBases 插件集成不会以任何方式限制其功能。相反,它增加了一个反悲伤系统,可以保护基地免受恶意玩家的侵害。
- 在突袭基地中,NPC 和其他实体只能受到突袭所有者或其朋友的伤害;
- 炮塔和陷阱不会攻击外人;
- 您可以自定义每个难度的申领价格,并为每个权限设置单独的折扣。
您仍然可以使用 /buyraid 命令购买突袭基地。没有所有者(可购买、维护、手动和计划)的突袭基地可以以配置文件中设置的价格购买,或者如果最终价格(价格 * 折扣)小于或等于 0,则可以分配给第一个进入其半径的玩家。
此外,作为奖励,购买此插件后,您将获得 5 个难度级别的 3 个免费基地,以及为它们配置的战利品。
[PluginReference] private Plugin RealPVE;
该插件订阅了 6 个通用钩子,使用它们允许与各种 PVE 插件中的 PVP 交互:
- OnPlayerEnterPVP
- OnPlayerExitPVP (玩家退出PVP)
- OnEntityEnterPVP
- OnEntityExitPVP (实体退出PVP)
- 创建 PVPMapMarker
- 删除 PVPMapMarker
OnPlayerEnterPVP:
用于将玩家添加到 PVP 模式/区域。
要调用 OnPlayerEnterPVP 钩子,您需要传递 2 个参数:
- <BasePlayer>player – 要添加到 PVP 的玩家;
- <string>zoneID – 您的 PVP 区域的唯一标识符。
此参数非常重要,因为玩家可以同时处于多个 PVP 区域中,在这种情况下传递 zoneID 可以正确处理玩家在其中的位置。
Interface.CallHook("OnPlayerEnterPVP", player, "*Your unique zone identifier*");//Calling the OnPlayerEnterPVP hook to tell PVE plugins that the player needs to be added to the specified PVP zone.
OnPlayerExitPVP:
用于将玩家从 PVP 模式/区域中删除。
调用此钩子可以保证玩家从指定的 PVP 区域中删除,但不能保证从 PVP 模式中删除,因为除了您的区域之外,可能还有其他区域。
此外,当玩家死亡时,他们会自动从所有 PVP 区域中删除。
要调用 OnPlayerExitPVP 钩子,您需要传递 3 个参数,其中 1 个是可选的:
- <BasePlayer>player – 要从 PvP 中删除的玩家;
- <string>zoneID – 您的 PVP 区域的唯一标识符;
- <float>pvpDelay – 可选。当玩家退出您的 PVP 区域时,您还可以传递 PVP 延迟时间。
但是,如果玩家还有其他活跃的 PVP 区域,您的 PVP 延迟将不会生效。
Interface.CallHook("OnPlayerExitPVP", player, "*Your unique zone identifier*", 10f);//Calling the OnPlayerExitPVP hook to tell PVE plugins that the player needs to be removed from the specified PVP zone, with the pvpDelay(10 seconds) specified if the player no longer has any active PVP zones.
OnEntityEnterPVP:
用于将实体添加到 PVP 模式/区域。
在 RealPVE 的情况下,此钩子仅在将具有所有者 (player) 的实体添加到 PVP 中时才需要,从而允许其他玩家与他们互动,例如玩家死后的尸体 (PlayerCorpse) 或尸体消失后的背包 (DroppedItemContainer)。
要调用 OnEntityEnterPVP 钩子,您需要传递 2 个参数:
- <BaseEntity>entity – 要添加到 PVP 的实体;
- <string>zoneID – 您的 PVP 区域的唯一标识符。
Interface.CallHook("OnEntityEnterPVP", entity, "*Your unique zone identifier*");//Calling the OnEntityEnterPVP hook to tell PVE plugins that the entity needs to be added to the specified PVP zone.
OnEntityExitPVP:
用于从 PVP 模式/区域中删除实体。
当一个实体死亡时,它会自动从所有 PVP 区域中移除。
要调用 OnEntityExitPVP 钩子,您需要传递 3 个参数,其中 1 个是可选的:
- <BaseEntity>entity – 要从 PVP 中删除的实体;
- <string>zoneID – 您的 PVP 区域的唯一标识符;
- <float>pvpDelay – 可选。当实体退出您的 PVP 区域时,您还可以传递 PVP 延迟时间。
但是,如果实体仍有其他活动的 PVP 区域,则您的 PVP 延迟将不会生效。
Interface.CallHook("OnEntityExitPVP", entity, "*Your unique zone identifier*", 10f);//Calling the OnEntityExitPVP hook to tell PVE plugins that the entity needs to be removed from the specified PVP zone, with the pvpDelay(10 seconds) specified if the entity no longer has any active PVP zones.
CreatePVPMapMarker:
用于为 PVP 区域创建地图标记。
要调用 CreatePVPMapMarker 钩子,您需要传递 5 个参数,其中 2 个是可选的:
- <string>zoneID – 您的 PVP 区域的唯一标识符;
- <Vector3>pos – 您的 PVP 区域的位置;
- <float>radius – 您的 PVP 区域的圆圈半径;
- <string>displayName – 可选。地图标记的显示名称;
- <BaseEntity>entity – 可选。映射标记应附加到的实体。
Interface.CallHook("CreatePVPMapMarker", "*Your unique zone identifier*", pos, 25f, "ATTENTION! This is a PVP zone!");//Calling the CreatePVPMapMarker hook to tell PVE plugins to create a map marker for the specified zone, at the specified position with the given radius, but without specifying a parent entity.
DeletePVPMapMarker:
用于删除 PVP 区域的地图标记。
要调用 DeletePVPMapMarker 钩子,你只需要传递 1 个参数:
- <string>zoneID – 您的 PVP 区域的唯一标识符。
Interface.CallHook("DeletePVPMapMarker", "*Your unique zone identifier*");//Calling the DeletePVPMapMarker hook to tell PVE plugins to delete a map marker for the specified zone.
插件调用了 5 个 hooks:
- OnPlayerPVPDelay
- OnPlayerPVP已发布
- OnPlayerPVPDelayRemoved
- OnZoneStatusText
- CanRedeemKit 兑换套件
OnPlayerPVPDelay:
当玩家退出最后一个活动的 PVP 区域时调用,允许其他插件覆盖 pvpDelay 的值。
返回 float 值允许更改播放器的 pvpDelay。
小于零的值将禁用 pvpDelay。
调用 OnPlayerPVPDelay 钩子时,会传递 3 个参数:
- <BasePlayer>player – 应用了 pvpDelay 的玩家;
- <float>pvpDelay – pvpDelay 的初始值;
- <string>zoneID – PVP 区域的唯一标识符。
object OnPlayerPVPDelay(BasePlayer player, float pvpDelay, string zoneID) { Puts($"Attempting to set a PvP delay of {pvpDelay} seconds for player {player.displayName} in zone {zoneID}!"); if (zoneID == "*Your unique zone identifier*") { return 15f;//Overriding the values for pvpDelay } return null;//Leave unchanged }
OnPlayerPVPDelayed:
在为播放器设置 PVP 延迟后调用。
调用 OnPlayerPVPDelayed 钩子时,会传递 3 个参数:
- <BasePlayer>player – 应用了 pvpDelay 的玩家;
- <float>pvpDelay – The value of pvpDelay;
- <string>zoneID – A unique identifier of PVP zone.
void OnPlayerPVPDelayed(BasePlayer player, float pvpDelay, string zoneID) { Puts($"A PvP delay of {pvpDelay} seconds has been set for player {player.displayName} in zone {zoneID}!"); }
OnPlayerPVPDelayRemoved:
当玩家进入具有活动 PVP 延迟的 PVP 区域后,从玩家中移除 PVP 延迟时调用。
调用 OnPlayerPVPDelayRemoved 钩子时,只传递 1 个参数:
- <BasePlayer>player – 已移除 PVP 延迟的玩家。
void OnPlayerPVPDelayRemoved(BasePlayer player) { Puts($"PVP delay has been removed for player {player.displayName} as they entered a PVP zone!"); }
OnZoneStatusText:
当需要具有指定区域的漂亮名称的文本时调用,以在状态栏中显示。
调用 OnZoneStatusText 钩子时,会传递 2 个参数:
- <BasePlayer>player – 为其请求区域好名字的玩家;
- <string>zoneID – PVP 区域的唯一标识符。
object OnZoneStatusText(BasePlayer player, string zoneID) { Puts($"Text for the status bar is required for zone {zoneID}"); if (zoneID == "*Your unique zone identifier*") { return lang.GetMessage("*langKey*", this, player.UserIDString);//<string>Overriding the value for the status bar text } return null;//Leave unchanged }
CanRedeemKit:
在提供初学者工具包之前在 OnDefaultItemsReceive 钩子中调用。
非零值将取消此作。
调用 CanRedeemKit 钩子时,仅传递 1 个参数:
- <BasePlayer>player – 尝试向其提供套件的玩家。
object CanRedeemKit(BasePlayer player) { Puts($"Attempting to give the kit to player {player.displayName}!"); if (player.IsAdmin) { return false;//Cancel the action } return null;//Leave unchanged }









