feat(hs): add HeykelSavasi MiniGameDefinition initializer
This commit is contained in:
@@ -0,0 +1,51 @@
|
|||||||
|
// <copyright file="HeykelSavasiInitializer.cs" company="MUnique">
|
||||||
|
// Licensed under the MIT License. See LICENSE file in the project root for full license information.
|
||||||
|
// </copyright>
|
||||||
|
|
||||||
|
namespace MUnique.OpenMU.Persistence.Initialization.VersionSeasonSix.Events;
|
||||||
|
|
||||||
|
using MUnique.OpenMU.DataModel.Configuration;
|
||||||
|
using MUnique.OpenMU.Persistence.Initialization.VersionSeasonSix.Maps;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The initializer for the Heykel Savasi event.
|
||||||
|
/// </summary>
|
||||||
|
internal class HeykelSavasiInitializer : InitializerBase
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// The Zen reward given to each member of the winning team (applied directly by the event context, not via <see cref="MiniGameReward"/>).
|
||||||
|
/// </summary>
|
||||||
|
public const int WinnerZenReward = 10_000_000;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Initializes a new instance of the <see cref="HeykelSavasiInitializer" /> class.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="context">The context.</param>
|
||||||
|
/// <param name="gameConfiguration">The game configuration.</param>
|
||||||
|
public HeykelSavasiInitializer(IContext context, GameConfiguration gameConfiguration)
|
||||||
|
: base(context, gameConfiguration)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <inheritdoc />
|
||||||
|
public override void Initialize()
|
||||||
|
{
|
||||||
|
var heykelSavasi = this.Context.CreateNew<MiniGameDefinition>();
|
||||||
|
heykelSavasi.SetGuid((short)MiniGameType.HeykelSavasi, 0);
|
||||||
|
this.GameConfiguration.MiniGameDefinitions.Add(heykelSavasi);
|
||||||
|
heykelSavasi.Name = "Heykel Savasi";
|
||||||
|
heykelSavasi.Description = "Takim vs takim heykel kirma savasi.";
|
||||||
|
heykelSavasi.Type = MiniGameType.HeykelSavasi;
|
||||||
|
heykelSavasi.GameLevel = 0;
|
||||||
|
heykelSavasi.MapCreationPolicy = MiniGameMapCreationPolicy.Shared;
|
||||||
|
heykelSavasi.EnterDuration = TimeSpan.FromMinutes(5);
|
||||||
|
heykelSavasi.GameDuration = TimeSpan.FromMinutes(5);
|
||||||
|
heykelSavasi.ExitDuration = TimeSpan.FromSeconds(15);
|
||||||
|
heykelSavasi.MaximumPlayerCount = 20;
|
||||||
|
heykelSavasi.AllowParty = false;
|
||||||
|
heykelSavasi.SaveRankingStatistics = false;
|
||||||
|
heykelSavasi.Entrance = this.GameConfiguration.Maps
|
||||||
|
.First(m => m.Number == HeykelSavasiMap.Number)
|
||||||
|
.ExitGates.First(g => g.IsSpawnGate); // Fallback entrance; the real per-team base gate is chosen by the join action.
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -88,6 +88,7 @@ public class GameConfigurationInitializer : GameConfigurationInitializerBase
|
|||||||
new DevilSquareInitializer(this.Context, this.GameConfiguration).Initialize();
|
new DevilSquareInitializer(this.Context, this.GameConfiguration).Initialize();
|
||||||
new BloodCastleInitializer(this.Context, this.GameConfiguration).Initialize();
|
new BloodCastleInitializer(this.Context, this.GameConfiguration).Initialize();
|
||||||
new ChaosCastleInitializer(this.Context, this.GameConfiguration).Initialize();
|
new ChaosCastleInitializer(this.Context, this.GameConfiguration).Initialize();
|
||||||
|
new HeykelSavasiInitializer(this.Context, this.GameConfiguration).Initialize();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void CreateJewelMixes()
|
private void CreateJewelMixes()
|
||||||
|
|||||||
Reference in New Issue
Block a user