-
Notifications
You must be signed in to change notification settings - Fork 64
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from Skyedra/furryServers
Whitelist window
- Loading branch information
Showing
12 changed files
with
259 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<ui:FurryServersWindow xmlns="https://spacestation14.io" | ||
xmlns:ui="clr-namespace:Content.Client.FurryServers" | ||
xmlns:controls="clr-namespace:Content.Client.UserInterface.Controls" | ||
Title="Other Furry Servers..." | ||
MinSize="500 300" | ||
SetSize="500 450"> | ||
<ScrollContainer HScrollEnabled="False" Margin="4" VerticalExpand="True" ReturnMeasure="True"> | ||
<BoxContainer Orientation="Vertical"> | ||
<Label Margin="8 0 0 0" StyleClasses="FurryServersSectionHeader" Align="Center" | ||
Text="BlepStation (LRP)" Name="BlepstationHeader" /> | ||
<RichTextLabel Margin="8 8 8 8" Name="BlepstationDescription" /> | ||
|
||
<Button Name="BlepstationWebsite" Text="Launch Website: BlepStation.com" /> | ||
</BoxContainer> | ||
</ScrollContainer> | ||
</ui:FurryServersWindow> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
using System.Linq; | ||
using Content.Client.Administration.Managers; | ||
using Content.Client.Stylesheets; | ||
using Content.Client.UserInterface.Controls; | ||
using Content.Client.UserInterface.Systems.EscapeMenu; | ||
using Content.Shared.Administration; | ||
using JetBrains.Annotations; | ||
using Robust.Client.AutoGenerated; | ||
using Robust.Client.UserInterface; | ||
using Robust.Client.UserInterface.XAML; | ||
using Robust.Shared.Console; | ||
using Robust.Client.ResourceManagement; | ||
using Robust.Shared.Utility; | ||
|
||
namespace Content.Client.FurryServers | ||
{ | ||
[GenerateTypedNameReferences] | ||
public sealed partial class FurryServersWindow : FancyWindow | ||
{ | ||
[Dependency] private readonly IResourceCache _resourceManager = default!; | ||
[Dependency] private readonly IUriOpener _uri = default!; | ||
|
||
public FurryServersWindow() | ||
{ | ||
RobustXamlLoader.Load(this); | ||
IoCManager.InjectDependencies(this); | ||
Stylesheet = IoCManager.Resolve<IStylesheetManager>().SheetSpace; | ||
|
||
BlepstationHeader.AddStyleClass(StyleBase.StyleClassLabelHeading); | ||
BlepstationHeader.FontColorOverride = Color.FromHex("#7687f2"); | ||
|
||
var description = FormattedMessage.FromMarkup(_resourceManager.ContentFileReadAllText($"/FurryServers/Blepstation.txt")); | ||
BlepstationDescription.SetMessage(description); | ||
|
||
BlepstationWebsite.OnPressed += _ => | ||
{ | ||
_uri.OpenUri("https://blepstation.com"); | ||
}; | ||
} | ||
|
||
protected override void Opened() | ||
{ | ||
base.Opened(); | ||
} | ||
} | ||
|
||
[UsedImplicitly, AnyCommand] | ||
public sealed class FurryServersCommand : IConsoleCommand | ||
{ | ||
public string Command => "furry"; | ||
public string Description => "Shows list of furry space station 14 servers"; | ||
public string Help => "Usage: furry"; | ||
|
||
public void Execute(IConsoleShell shell, string argStr, string[] args) | ||
{ | ||
IoCManager.Resolve<IUserInterfaceManager>().GetUIController<FurryServersUIController>().OpenWindow(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
Content.Client/UserInterface/Systems/EscapeMenu/FurryServersUIController.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
using Content.Client.FurryServers; | ||
using JetBrains.Annotations; | ||
using Robust.Client.State; | ||
using Robust.Client.UserInterface.Controllers; | ||
using Robust.Client.ResourceManagement; | ||
|
||
namespace Content.Client.UserInterface.Systems.EscapeMenu; | ||
|
||
[UsedImplicitly] | ||
public sealed class FurryServersUIController : UIController | ||
{ | ||
private FurryServersWindow _furryServersWindow = default!; | ||
|
||
public void OpenWindow() | ||
{ | ||
EnsureWindow(); | ||
|
||
_furryServersWindow.OpenCentered(); | ||
_furryServersWindow.MoveToFront(); | ||
} | ||
|
||
private void EnsureWindow() | ||
{ | ||
if (_furryServersWindow is { Disposed: false }) | ||
return; | ||
|
||
_furryServersWindow = UIManager.CreateWindow<FurryServersWindow>(); | ||
} | ||
|
||
public void ToggleWindow() | ||
{ | ||
EnsureWindow(); | ||
|
||
if (_furryServersWindow.IsOpen) | ||
{ | ||
_furryServersWindow.Close(); | ||
} | ||
else | ||
{ | ||
OpenWindow(); | ||
} | ||
} | ||
} |
15 changes: 15 additions & 0 deletions
15
Content.Client/UserInterface/Systems/WhitelistWindow/Controls/WhitelistDenialWindow.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<ui:WhitelistDenialWindow xmlns="https://spacestation14.io" | ||
xmlns:ui="clr-namespace:Content.Client.UserInterface.Systems.WhitelistWindow.Controls" | ||
xmlns:controls="clr-namespace:Content.Client.UserInterface.Controls" | ||
Title="Whitelist Required" | ||
MinSize="400 170" | ||
SetSize="400 230"> | ||
<ScrollContainer HScrollEnabled="False" Margin="4" VerticalExpand="True" ReturnMeasure="True"> | ||
<BoxContainer Orientation="Vertical"> | ||
<RichTextLabel Margin="8 0 0 0" Name="DenialReason" /> | ||
<Button Margin="8 10 0 0" Name="WhitelistApplyButton" Text="Apply for whitelist" /> | ||
<PanelContainer Margin="8 10 0 0" StyleClasses="LowDivider" /> | ||
<Button Margin="8 20 0 0" Name="FurryServersButton" Text="Or check out other Furry SS14 Servers" /> | ||
</BoxContainer> | ||
</ScrollContainer> | ||
</ui:WhitelistDenialWindow> |
52 changes: 52 additions & 0 deletions
52
Content.Client/UserInterface/Systems/WhitelistWindow/Controls/WhitelistDenialWindow.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
using System.Linq; | ||
using Content.Client.Administration.Managers; | ||
using Content.Client.Stylesheets; | ||
using Content.Client.UserInterface.Controls; | ||
using Content.Client.UserInterface.Systems.EscapeMenu; | ||
using Content.Shared.Administration; | ||
using JetBrains.Annotations; | ||
using Robust.Client.AutoGenerated; | ||
using Robust.Client.UserInterface; | ||
using Robust.Client.UserInterface.XAML; | ||
using Robust.Shared.Console; | ||
using Robust.Client.ResourceManagement; | ||
using Robust.Shared.Utility; | ||
using Content.Client.UserInterface.Systems.EscapeMenu; | ||
|
||
namespace Content.Client.UserInterface.Systems.WhitelistWindow.Controls | ||
{ | ||
[GenerateTypedNameReferences] | ||
public sealed partial class WhitelistDenialWindow : FancyWindow | ||
{ | ||
[Dependency] private readonly IResourceCache _resourceManager = default!; | ||
[Dependency] private readonly IUriOpener _uri = default!; | ||
|
||
public WhitelistDenialWindow() | ||
{ | ||
RobustXamlLoader.Load(this); | ||
IoCManager.InjectDependencies(this); | ||
Stylesheet = IoCManager.Resolve<IStylesheetManager>().SheetSpace; | ||
|
||
WhitelistApplyButton.OnPressed += _ => | ||
{ | ||
_uri.OpenUri("https://discord.gg/ZZYNpq5KBJ"); // Floof discord link | ||
}; | ||
|
||
FurryServersButton.OnPressed += _ => | ||
{ | ||
UserInterfaceManager.GetUIController<FurryServersUIController>().ToggleWindow(); | ||
}; | ||
} | ||
|
||
|
||
protected override void Opened() | ||
{ | ||
base.Opened(); | ||
} | ||
|
||
public void SetDenialMessage(string denial) | ||
{ | ||
DenialReason.SetMessage(denial); | ||
} | ||
} | ||
} |
34 changes: 34 additions & 0 deletions
34
Content.Client/UserInterface/Systems/WhitelistWindow/WhitelistDenialUIController.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
using Content.Client.Options.UI; | ||
using JetBrains.Annotations; | ||
using Robust.Client.UserInterface.Controllers; | ||
using Robust.Shared.Console; | ||
using Content.Client.UserInterface.Systems.WhitelistWindow.Controls; | ||
|
||
namespace Content.Client.UserInterface.Systems.WhitelistWindow; | ||
|
||
[UsedImplicitly] | ||
public sealed class WhitelistDenialUIController : UIController | ||
{ | ||
public override void Initialize() | ||
{ | ||
} | ||
private WhitelistDenialWindow _whitelistDenialWindow = default!; | ||
|
||
private void EnsureWindow() | ||
{ | ||
if (_whitelistDenialWindow is { Disposed: false }) | ||
return; | ||
|
||
_whitelistDenialWindow = UIManager.CreateWindow<WhitelistDenialWindow>(); | ||
} | ||
|
||
public void OpenWindow(string denialMessage) | ||
{ | ||
EnsureWindow(); | ||
|
||
_whitelistDenialWindow.SetDenialMessage(denialMessage); | ||
|
||
_whitelistDenialWindow.OpenCentered(); | ||
_whitelistDenialWindow.MoveToFront(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
Looking for faster paced rounds that are more focused on gameplay? Check out our friends at [italic]BlepStation[/italic], a furry server with unique content and features. (Adults/18+ Only) | ||
|
||
• Furry kinks & species. | ||
• Shorter, [bold]gameplay-focused[/bold] rounds. | ||
• Low role timer requirements. | ||
• [bold]LRP[/bold] -- Simple rules, less serious vibe. | ||
• Based on vanilla upstream (but also brings back popular removed mechanics like cloning, vehicles, list inventory, etc). | ||
• No whitelist requirement. | ||
|
||
Check out the website for more information! We hope to play with you soon :) |