mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/PCK-Studio.git
synced 2026-07-13 18:48:18 +00:00
Add AbstractGameRule.cs & derived classes
This commit is contained in:
23
PckStudio.Core/GameRule/OnGameStartSpawnPositions.cs
Normal file
23
PckStudio.Core/GameRule/OnGameStartSpawnPositions.cs
Normal file
@@ -0,0 +1,23 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Security.Cryptography;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using OMI.Formats.GameRule;
|
||||
|
||||
namespace PckStudio.Core.GameRule
|
||||
{
|
||||
internal sealed class OnGameStartSpawnPositions : AbstractGameRule
|
||||
{
|
||||
public SpawnPositionSet OnStart { get; } = new SpawnPositionSet(SpawnPositionSet.SpanPositionMethod.OnStart);
|
||||
public SpawnPositionSet OnRespawn { get; } = new SpawnPositionSet(SpawnPositionSet.SpanPositionMethod.OnRespawn);
|
||||
|
||||
protected override GameRuleFile.GameRule GetGameRule()
|
||||
{
|
||||
AddRule(OnStart);
|
||||
AddRule(OnRespawn);
|
||||
return new GameRuleFile.GameRule("OnGameStartSpawnPositions");
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user