mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/PCK-Studio.git
synced 2026-07-07 11:18:11 +00:00
Add DLCMiniGamePackage.cs
This commit is contained in:
@@ -8,21 +8,12 @@ using PckStudio.Core.Interfaces;
|
||||
|
||||
namespace PckStudio.Core
|
||||
{
|
||||
internal sealed class DLCBattlePackage : DLCPackage
|
||||
internal sealed class DLCBattlePackage : DLCMiniGamePackage
|
||||
{
|
||||
|
||||
private List<MapData> _maps = new List<MapData>();
|
||||
|
||||
public DLCBattlePackage(string name, int identifier, IDLCPackageLocationInfo packageInfo = null, IDLCPackage parentPackage = null)
|
||||
: base(name, identifier, packageInfo, parentPackage)
|
||||
public DLCBattlePackage(string name, int identifier)
|
||||
: base(name, identifier, DLCPackageType.MG01, MiniGameId.Battle)
|
||||
{
|
||||
}
|
||||
|
||||
public void AddMap(string name, Image thumbnail, MapSize mapSize, NamedData<byte[]> world)
|
||||
{
|
||||
_maps.Add(new MapData(name, thumbnail, MiniGameId.Battle, mapSize, world));
|
||||
}
|
||||
|
||||
public override DLCPackageType GetDLCPackageType() => DLCPackageType.MG01;
|
||||
}
|
||||
}
|
||||
|
||||
31
PckStudio.Core/DLCMiniGamePackage.cs
Normal file
31
PckStudio.Core/DLCMiniGamePackage.cs
Normal file
@@ -0,0 +1,31 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using PckStudio.Core.Interfaces;
|
||||
|
||||
namespace PckStudio.Core
|
||||
{
|
||||
internal class DLCMiniGamePackage : DLCPackage
|
||||
{
|
||||
private List<MapData> _maps = new List<MapData>();
|
||||
private readonly DLCPackageType _packageType;
|
||||
private readonly MiniGameId _miniGameId;
|
||||
|
||||
public DLCMiniGamePackage(string name, int identifier, DLCPackageType packageType, MiniGameId miniGameId, IDLCPackageLocationInfo packageInfo = null, IDLCPackage parentPackage = null)
|
||||
: base(name, identifier, packageInfo, parentPackage)
|
||||
{
|
||||
_packageType = packageType;
|
||||
_miniGameId = miniGameId;
|
||||
}
|
||||
|
||||
public void AddMap(string name, Image thumbnail, MapSize mapSize, NamedData<byte[]> world)
|
||||
{
|
||||
_maps.Add(new MapData(name, thumbnail, _miniGameId, mapSize, world));
|
||||
}
|
||||
|
||||
public override DLCPackageType GetDLCPackageType() => _packageType;
|
||||
}
|
||||
}
|
||||
@@ -68,6 +68,7 @@
|
||||
<Compile Include="DLCBattlePackage.cs" />
|
||||
<Compile Include="DLCManager.cs" />
|
||||
<Compile Include="DLCMashUpPackage.cs" />
|
||||
<Compile Include="DLCMiniGamePackage.cs" />
|
||||
<Compile Include="DLCPackage.cs" />
|
||||
<Compile Include="DLCSkinPackage.cs" />
|
||||
<Compile Include="DLCTexturePackage.cs" />
|
||||
|
||||
Reference in New Issue
Block a user