Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# C1 F6 0C - QuestProgressExtended (by server)
# C2 F6 0C - QuestProgressExtended (by server)

## Is sent when

Expand All @@ -12,10 +12,10 @@ The client shows the quest progress accordingly.

| Index | Length | Data Type | Value | Description |
|-------|--------|-----------|-------|-------------|
| 0 | 1 | Byte | 0xC1 | [Packet type](PacketTypes.md) |
| 1 | 1 | Byte | 272 | Packet header - length of the packet |
| 2 | 1 | Byte | 0xF6 | Packet header - packet type identifier |
| 3 | 1 | Byte | 0x0C | Packet header - sub packet type identifier |
| 0 | 1 | Byte | 0xC2 | [Packet type](PacketTypes.md) |
| 1 | 2 | Short | 272 | Packet header - length of the packet |
| 3 | 1 | Byte | 0xF6 | Packet header - packet type identifier |
| 4 | 1 | Byte | 0x0C | Packet header - sub packet type identifier |
| 5 | 1 | Byte | | ConditionCount |
| 6 | 1 | Byte | | RewardCount |
| 7 | 1 | Byte | | RandomRewardCount |
Expand Down
2 changes: 1 addition & 1 deletion docs/Packets/ServerToClient.md
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@
* [C1 F6 0A - AvailableQuests (by server)](C1-F6-0A-AvailableQuests_by-server.md)
* [C1 F6 0B - QuestStepInfo (by server)](C1-F6-0B-QuestStepInfo_by-server.md)
* [C1 F6 0C - QuestProgress (by server)](C1-F6-0C-QuestProgress_by-server.md)
* [C1 F6 0C - QuestProgressExtended (by server)](C1-F6-0C-QuestProgressExtended_by-server.md)
* [C2 F6 0C - QuestProgressExtended (by server)](C2-F6-0C-QuestProgressExtended_by-server.md)
* [C1 F6 0D - QuestCompletionResponse (by server)](C1-F6-0D-QuestCompletionResponse_by-server.md)
* [C1 F6 0F - QuestCancelled (by server)](C1-F6-0F-QuestCancelled_by-server.md)
* [C1 F6 1A - QuestStateList (by server)](C1-F6-1A-QuestStateList_by-server.md)
Expand Down
26 changes: 19 additions & 7 deletions src/Network/IpAddressResolverFactory.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// <copyright file="IpAddressResolverFactory.cs" company="MUnique">
// <copyright file="IpAddressResolverFactory.cs" company="MUnique">
// Licensed under the MIT License. See LICENSE file in the project root for full license information.
// </copyright>

Expand Down Expand Up @@ -28,6 +28,8 @@ public static IIpAddressResolver CreateIpResolver(string[] args, (IpResolverType
var (resolver, source) = DetermineBestFittingResolverWithSource(args, configuration);
var allowRuntimeReconfiguration = source is not ResolverSource.StartParameter and not ResolverSource.EnvironmentVariable;

var logger = loggerFactory.CreateLogger(nameof(IpAddressResolverFactory));
logger.LogDebug("args: {Args} | config: {Config} | resolved: ({ResolverType}, {ResolverParameter}) | source: {Source}", string.Join(" ", args), configuration, resolver.Type, resolver.Parameter, source);
return new ConfigurableIpResolver(resolver.Type, resolver.Parameter, loggerFactory, allowRuntimeReconfiguration);
}

Expand All @@ -51,13 +53,20 @@ private static (IpResolverType Type, string? Parameter)? DetermineIpResolverByPa
return default;
}

return parameter! switch
var parsed = parameter! switch
{
{ } when parameter.Equals(LoopbackIpResolve, StringComparison.InvariantCultureIgnoreCase) => (IpResolverType.Loopback, null),
{ } when parameter.Equals(PublicIpResolve, StringComparison.InvariantCultureIgnoreCase) => (IpResolverType.Public, null),
{ } when parameter.Equals(LocalIpResolve, StringComparison.InvariantCultureIgnoreCase) => ((IpResolverType, string?)?)(IpResolverType.Local, null),
_ => (IpResolverType.Custom, ExtractIpFromParameter(parameter)),
{ } when parameter.Equals(LoopbackIpResolve, StringComparison.InvariantCultureIgnoreCase) => (Type: IpResolverType.Loopback, Parameter: (string?)null),
{ } when parameter.Equals(PublicIpResolve, StringComparison.InvariantCultureIgnoreCase) => (Type: IpResolverType.Public, Parameter: (string?)null),
{ } when parameter.Equals(LocalIpResolve, StringComparison.InvariantCultureIgnoreCase) => (Type: IpResolverType.Local, Parameter: (string?)null),
_ => (Type: IpResolverType.Custom, Parameter: ExtractIpFromParameter(parameter)),
};

if (parsed.Type == IpResolverType.Custom && string.IsNullOrWhiteSpace(parsed.Parameter))
{
return default;
}

return parsed;
}

private static (IpResolverType Type, string? Parameter)? DetermineResolverByEnvironmentVariable(string variableName = "RESOLVE_IP")
Expand Down Expand Up @@ -108,7 +117,10 @@ private static ((IpResolverType Type, string? Parameter) Resolver, ResolverSourc

if (configuration is { } byConfiguration)
{
return (byConfiguration, ResolverSource.Configuration);
if (byConfiguration.Type != IpResolverType.Custom || !string.IsNullOrWhiteSpace(byConfiguration.Parameter))
{
return (byConfiguration, ResolverSource.Configuration);
}
}

return (DetermineResolverByEnvironment(), ResolverSource.Environment);
Expand Down
26 changes: 9 additions & 17 deletions src/Web/Shared/wwwroot/css/shared.css
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@charset "UTF-8";
@charset "UTF-8";
/*!
* Bootstrap v4.6.1 (https://getbootstrap.com/)
* Copyright 2011-2021 The Bootstrap Authors
Expand Down Expand Up @@ -3842,15 +3842,13 @@ form > div > div > div:first-child:first-of-type > span:not(:first-child) {
border: 0;
border-radius: 1rem;
transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
appearance: none;
}
@media (prefers-reduced-motion: reduce) {
.custom-range::-webkit-slider-thumb {
transition: none;
}
}
.custom-range::-webkit-slider-thumb {
appearance: none;
}
.custom-range::-webkit-slider-thumb:active {
background-color: rgb(178.5, 215.4, 255);
}
Expand All @@ -3870,15 +3868,13 @@ form > div > div > div:first-child:first-of-type > span:not(:first-child) {
border: 0;
border-radius: 1rem;
transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
appearance: none;
}
@media (prefers-reduced-motion: reduce) {
.custom-range::-moz-range-thumb {
transition: none;
}
}
.custom-range::-moz-range-thumb {
appearance: none;
}
.custom-range::-moz-range-thumb:active {
background-color: rgb(178.5, 215.4, 255);
}
Expand All @@ -3901,15 +3897,13 @@ form > div > div > div:first-child:first-of-type > span:not(:first-child) {
border: 0;
border-radius: 1rem;
transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
appearance: none;
}
@media (prefers-reduced-motion: reduce) {
.custom-range::-ms-thumb {
transition: none;
}
}
.custom-range::-ms-thumb {
appearance: none;
}
.custom-range::-ms-thumb:active {
background-color: rgb(178.5, 215.4, 255);
}
Expand Down Expand Up @@ -4316,6 +4310,10 @@ form > div > div > div:first-child:first-of-type > span:not(:first-child) {
display: none;
}
}
.navbar-expand {
flex-flow: row nowrap;
justify-content: flex-start;
}
.navbar-expand > .container,
.navbar-expand > .container-fluid,
.navbar-expand > .container-sm,
Expand All @@ -4325,10 +4323,6 @@ form > div > div > div:first-child:first-of-type > span:not(:first-child) {
padding-right: 0;
padding-left: 0;
}
.navbar-expand {
flex-flow: row nowrap;
justify-content: flex-start;
}
.navbar-expand .navbar-nav {
flex-direction: row;
}
Expand Down Expand Up @@ -5508,15 +5502,13 @@ a.close.disabled {
}
.modal.fade .modal-dialog {
transition: transform 0.3s ease-out;
transform: translate(0, -50px);
}
@media (prefers-reduced-motion: reduce) {
.modal.fade .modal-dialog {
transition: none;
}
}
.modal.fade .modal-dialog {
transform: translate(0, -50px);
}
.modal.show .modal-dialog {
transform: none;
}
Expand Down
2 changes: 1 addition & 1 deletion src/Web/Shared/wwwroot/css/shared.min.css

Large diffs are not rendered by default.