Fixed waypoints appearing unlocked even though they were reportedly locked

It would only set in DEBUG mode to unlock all, so I've changed to a config in the [Game-Server] section named "UnlockAllWaypoints".
This commit is contained in:
Lucca Faria Ferri 2023-02-08 05:18:53 -08:00
parent 61005bb1b9
commit 3d123f409f
2 changed files with 12 additions and 6 deletions

View File

@ -4093,12 +4093,7 @@ public class Player : Actor, IMessageConsumer, IUpdateable
}, },
SkillSlotEverAssigned = 0x0F, //0xB4, SkillSlotEverAssigned = 0x0F, //0xB4,
PlaytimeTotal = Toon.TimePlayed, PlaytimeTotal = Toon.TimePlayed,
#if DEBUG WaypointFlags = GameServerConfig.Instance.UnlockAllWaypoints ? 0x0000ffff : this.World.Game.WaypointFlags,
WaypointFlags = 0x0000ffff,
#else
WaypointFlags = this.World.Game.WaypointFlags,
#endif
HirelingData = new HirelingSavedData() HirelingData = new HirelingSavedData()
{ {
HirelingInfos = HirelingInfo, HirelingInfos = HirelingInfo,

View File

@ -187,7 +187,18 @@ namespace DiIiS_NA.GameServer
get => GetFloat(nameof(HealthPotionCooldown), 30f); get => GetFloat(nameof(HealthPotionCooldown), 30f);
set => Set(nameof(HealthPotionCooldown), value); set => Set(nameof(HealthPotionCooldown), value);
} }
/// <summary>
/// Unlocks all waypoints in the campaign.
/// </summary>
public bool UnlockAllWaypoints
{
get => GetBoolean(nameof(UnlockAllWaypoints), false);
set => Set(nameof(UnlockAllWaypoints), value);
}
public static GameServerConfig Instance { get; } = new(); public static GameServerConfig Instance { get; } = new();
private GameServerConfig() : base("Game-Server") private GameServerConfig() : base("Game-Server")
{ {