Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BL expedition 2.1 PART ONE #336

Open
wants to merge 131 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 5 commits
Commits
Show all changes
131 commits
Select commit Hold shift + click to select a range
eaefa7a
Обнова эксп часть №1
BL02DL Dec 3, 2024
6c26238
Merge branch 'Lost-Paradise-Project:master' into BL-Expedition
BL02DL Dec 3, 2024
3781914
Обнова эксп часть №2
BL02DL Dec 6, 2024
dda1f6d
Merge branch 'BL-Expedition' of https://github.com/BL02DL/BL-CORP int…
BL02DL Dec 6, 2024
1e0f2a4
Maybe fix?
BL02DL Dec 6, 2024
8a15249
Test
BL02DL Dec 6, 2024
2e7b3fe
Fix 2
BL02DL Dec 7, 2024
ad4bb10
Начнём...
Farrellka-dev Dec 10, 2024
9cd76b6
Чутка переводов
Farrellka-dev Dec 11, 2024
39262bc
Переводы
Farrellka-dev Dec 11, 2024
7a2348c
Доперевёл
Farrellka-dev Dec 13, 2024
a01512d
Фикс
Farrellka-dev Dec 13, 2024
cbdc783
Фиксик
Farrellka-dev Dec 13, 2024
1db38a4
Та ёмаё
Farrellka-dev Dec 13, 2024
20a425c
Пачалося
Farrellka-dev Dec 13, 2024
865373d
Культисты
Farrellka-dev Dec 13, 2024
ed78948
Фикс Культа
Farrellka-dev Dec 13, 2024
9e70bc6
Фикс Культа (ещё)
Farrellka-dev Dec 13, 2024
a9994c5
Фикс Культа (...)
Farrellka-dev Dec 13, 2024
3b7105e
Фикс
Farrellka-dev Dec 13, 2024
4575f48
Текстурка мыла
Farrellka-dev Dec 13, 2024
971b64c
не туда
Farrellka-dev Dec 13, 2024
4b87681
NF нахуй
Farrellka-dev Dec 13, 2024
91b87e7
вырезал контру
Farrellka-dev Dec 13, 2024
58ecb9d
Хрень
Farrellka-dev Dec 13, 2024
bed76c5
да починись уже
Farrellka-dev Dec 13, 2024
865e01f
work will be done
Farrellka-dev Dec 13, 2024
e5d7a98
cold is coming
Farrellka-dev Dec 13, 2024
af2a06c
Наёмыши
Farrellka-dev Dec 13, 2024
0b90b18
упс
Farrellka-dev Dec 13, 2024
e796b38
Панки, еее
Farrellka-dev Dec 13, 2024
0b1c8ec
граффити
Farrellka-dev Dec 13, 2024
1976209
граффити 2
Farrellka-dev Dec 13, 2024
a5d42de
Акцент
Farrellka-dev Dec 13, 2024
a9c3c4c
Обновка
Farrellka-dev Dec 13, 2024
01a7928
Обновка
Farrellka-dev Dec 13, 2024
db3d58d
Гоблетсы
Farrellka-dev Dec 13, 2024
2c5d4c1
Гоблинов не люблю просто
Farrellka-dev Dec 13, 2024
cf20f29
Никакой контры 1984
Farrellka-dev Dec 13, 2024
971a371
Чистки
Farrellka-dev Dec 13, 2024
edfd284
Ой
Farrellka-dev Dec 13, 2024
77e2475
мяу
Farrellka-dev Dec 13, 2024
b58e7b4
мияо
Farrellka-dev Dec 13, 2024
87f7e27
мрь
Farrellka-dev Dec 13, 2024
7c52035
Рудные крабики
Farrellka-dev Dec 14, 2024
6679313
фиксыы.. 5?
BL02DL Dec 14, 2024
71c1d29
Merge branch 'BL-Expedition' of https://github.com/BL02DL/BL-CORP int…
Farrellka-dev Dec 14, 2024
8cb2eaf
мелкий фикс 4
BL02DL Dec 14, 2024
d526150
Merge branch 'BL-Expedition' of https://github.com/BL02DL/BL-CORP int…
BL02DL Dec 14, 2024
c547279
Фикс
Farrellka-dev Dec 14, 2024
1aedcad
мелкий фикс дубликата
BL02DL Dec 15, 2024
1d671c9
мелкий фикс 5
BL02DL Dec 15, 2024
0a4ac46
Merge branch 'BL-Expedition' of https://github.com/BL02DL/BL-CORP int…
Farrellka-dev Dec 15, 2024
2a8d34f
Снаряга наёмышей
Farrellka-dev Dec 15, 2024
5f307a3
Фикс названия Hydroponics
Farrellka-dev Dec 15, 2024
b41057e
Фикс
Farrellka-dev Dec 15, 2024
07fec71
Экипа панков и культистов
Farrellka-dev Dec 15, 2024
ea56941
Фикс
Farrellka-dev Dec 15, 2024
a147c20
Фикс
Farrellka-dev Dec 15, 2024
7df5b6f
Контрабанда - нахуй
Farrellka-dev Dec 15, 2024
3119355
Контрабанда - нахуй 2
Farrellka-dev Dec 15, 2024
b2d36fb
Синдифигня чучуть
Farrellka-dev Dec 15, 2024
8d86188
Контра...
Farrellka-dev Dec 15, 2024
5d38ff1
Да сколько контры?!
Farrellka-dev Dec 15, 2024
8bd2d9e
base_clothing_belt
Farrellka-dev Dec 15, 2024
65a31e2
харэ
Farrellka-dev Dec 15, 2024
332edb0
Mercenary web vest
Farrellka-dev Dec 15, 2024
1f515a3
Текстурки
Farrellka-dev Dec 15, 2024
27a82b2
Удалил CatWearable
Farrellka-dev Dec 15, 2024
d001999
ИИшки, переводики
Farrellka-dev Dec 16, 2024
3888f2f
Тест
Farrellka-dev Dec 16, 2024
c5a705e
Del
Farrellka-dev Dec 16, 2024
583122c
Space Asshole
Farrellka-dev Dec 16, 2024
c677fbf
Что-то должно исправить
Farrellka-dev Dec 16, 2024
2cc2c72
Ещё фиксы
Farrellka-dev Dec 16, 2024
4ad348b
Локализация
Farrellka-dev Dec 16, 2024
850e5ca
Крабики, фиксики
Farrellka-dev Dec 16, 2024
3a8f976
Алё
Farrellka-dev Dec 16, 2024
1692599
фикс 6
BL02DL Dec 16, 2024
83dab69
фикс локализации
BL02DL Dec 16, 2024
8a0334f
литл фикс
BL02DL Dec 16, 2024
4020ba9
фикс 7
BL02DL Dec 16, 2024
f4bdbcc
фикс 8
BL02DL Dec 16, 2024
d18974c
фикс 9
BL02DL Dec 16, 2024
8f7b8f7
Добавил BaseSpeedLoaderHeavyRifle
Farrellka-dev Dec 17, 2024
deb5eeb
Кейсы оружия
Farrellka-dev Dec 17, 2024
e8d60e6
+ спрайт
Farrellka-dev Dec 17, 2024
f5fc1a0
+ спрайт ещё
Farrellka-dev Dec 17, 2024
9f31cfc
+ спрайт ещё один
Farrellka-dev Dec 17, 2024
b1ff571
Да сколько там спрайтов? Можно список, почему Я добавляю их по одному?
Farrellka-dev Dec 17, 2024
9cdeeaf
ueegh
Farrellka-dev Dec 17, 2024
6cfa134
buuegh
Farrellka-dev Dec 17, 2024
72ec2e5
andjnsaj
Farrellka-dev Dec 17, 2024
2c224b7
фикс 10
BL02DL Dec 17, 2024
f2a7ca1
Merge branch 'BL-Expedition' of https://github.com/BL02DL/BL-CORP int…
BL02DL Dec 17, 2024
eb78976
Мяу мяу мяу
Farrellka-dev Dec 17, 2024
9edf0f1
Норм
Farrellka-dev Dec 17, 2024
046b05f
Фикс спрайтов
Farrellka-dev Dec 17, 2024
cc35817
Null не работает?..
Farrellka-dev Dec 17, 2024
c692f12
хавка...
Farrellka-dev Dec 17, 2024
c970255
Нету NPCUseActionOnTarget
Farrellka-dev Dec 17, 2024
d49cca6
Кластерное мыло такое uegh...
Farrellka-dev Dec 17, 2024
ad3b13e
Закомментил голиафа и легион, много особых методов
Farrellka-dev Dec 17, 2024
6058c50
Фикс арбалей
Farrellka-dev Dec 18, 2024
b2312e0
Фикс
Farrellka-dev Dec 18, 2024
ff56de1
Бред
Farrellka-dev Dec 18, 2024
9b6193b
фикс dungeon_items_general
Farrellka-dev Dec 18, 2024
f1483dc
спрайты
Farrellka-dev Dec 18, 2024
312597b
Фиксы
Farrellka-dev Dec 18, 2024
25a22cd
base_structure.yml
Farrellka-dev Dec 18, 2024
f337c0c
контра
Farrellka-dev Dec 18, 2024
dbdcd44
Фикс спрайта
Farrellka-dev Dec 18, 2024
4f327dd
NF...
Farrellka-dev Dec 18, 2024
e716a82
Удалил всё с DisableToolUse
Farrellka-dev Dec 18, 2024
3e4911b
Теперь точно
Farrellka-dev Dec 18, 2024
d3720e3
ТЕПЕРЬ ДА
Farrellka-dev Dec 18, 2024
33d79ec
MarketModifier это что
Farrellka-dev Dec 18, 2024
8d54e1c
блюпринты
Farrellka-dev Dec 18, 2024
1c4aa5b
Салфетка
Farrellka-dev Dec 18, 2024
cf3e667
Что Я наделал...
Farrellka-dev Dec 18, 2024
48efa1d
Вендоматы убрал
Farrellka-dev Dec 18, 2024
abb12a9
Revert "Бред"
Farrellka-dev Dec 18, 2024
8bd6d61
Merge branch 'BL-Expedition' of https://github.com/BL02DL/BL-CORP int…
Farrellka-dev Dec 18, 2024
92c041f
Вернул
Farrellka-dev Dec 18, 2024
eacb77e
фиксы 11, удаление не нужных Ев
BL02DL Dec 18, 2024
8d21a31
спрайты
BL02DL Dec 18, 2024
36371bc
пайп и фаер бомбы
BL02DL Dec 18, 2024
8f8d1e9
фикс 12
BL02DL Dec 20, 2024
699c55a
фикс 12
BL02DL Dec 21, 2024
381feb6
Resolve Conflicts
Farrellka-dev Dec 22, 2024
56fae36
Merge branch 'master' into BL-Expedition
BL02DL Dec 23, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
using Content.Shared._LostParadise.Salvage;

namespace Content.Client._LostParadise.Salvage;

public sealed class LPRestrictedRangeSystem : SharedLPRestrictedRangeSystem
{
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
using Content.Shared._LostParadise.Salvage.Expeditions;

namespace Content.Client._LostParadise.Salvage;

[RegisterComponent]
public sealed partial class LPSalvageExpeditionComponent : SharedLPSalvageExpeditionComponent
{

}
50 changes: 50 additions & 0 deletions Content.Client/_LostParadise/Salvage/LPSalvageSystem.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
using Content.Client.Audio;
using Content.Shared._LostParadise.Salvage;
using Content.Shared._LostParadise.Salvage.Expeditions;
using Robust.Client.Player;
using Robust.Shared.GameStates;

namespace Content.Client._LostParadise.Salvage;

public sealed class LPSalvageSystem : SharedLPSalvageSystem
{
[Dependency] private readonly IPlayerManager _playerManager = default!;
[Dependency] private readonly ContentAudioSystem _audio = default!;

public override void Initialize()
{
base.Initialize();
SubscribeLocalEvent<PlayAmbientMusicEvent>(OnPlayAmbientMusic);
SubscribeLocalEvent<LPSalvageExpeditionComponent, ComponentHandleState>(OnExpeditionHandleState);
}

private void OnExpeditionHandleState(EntityUid uid, LPSalvageExpeditionComponent component, ref ComponentHandleState args)
{
if (args.Current is not LPSalvageExpeditionComponentState state)
return;

component.Stage = state.Stage;

if (component.Stage >= LPExpeditionStage.MusicCountdown)
{
_audio.DisableAmbientMusic();
}
}

private void OnPlayAmbientMusic(ref PlayAmbientMusicEvent ev)
{
if (ev.Cancelled)
return;

var player = _playerManager.LocalEntity;

if (!TryComp(player, out TransformComponent? xform) ||
!TryComp<LPSalvageExpeditionComponent>(xform.MapUid, out var expedition) ||
expedition.Stage < LPExpeditionStage.MusicCountdown)
{
return;
}

ev.Cancelled = true;
}
}
36 changes: 36 additions & 0 deletions Content.Client/_LostParadise/Salvage/UI/LPOfferingWindow.xaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
<controls:FancyWindow xmlns="https://spacestation14.io"
xmlns:controls="clr-namespace:Content.Client.UserInterface.Controls"
MinSize="800 360">
<BoxContainer Orientation="Vertical">
<BoxContainer Orientation="Horizontal" Name="ProgressionBox" Visible="False">
<Label Name="ProgressionLabel"
Text="{Loc 'salvage-expedition-window-progression'}"
SetWidth="96"
Margin="5"/>
<ProgressBar Name="ProgressionBar"
HorizontalExpand="True"
MinValue="0"
MaxValue="1"
SetHeight="25"/>
<Label Name="ProgressionText" Text="00:00"
Margin="5"/>
</BoxContainer>
<BoxContainer Orientation="Horizontal">
<Label Name="NextOfferLabel"
Text="{Loc 'salvage-expedition-window-next'}"
SetWidth="96"
Margin="5"/>
<ProgressBar Name="NextOfferBar"
HorizontalExpand="True"
MinValue="0"
MaxValue="1"
SetHeight="25"/>
<Label Name="NextOfferText" Text="0.00"
Margin="5"/>
</BoxContainer>
<controls:HLine Color="#404040" Thickness="2" Margin="0 5 0 5"/>
<BoxContainer Name="Container"
Orientation="Horizontal"
Margin="5 0 5 0"/>
</BoxContainer>
</controls:FancyWindow>
117 changes: 117 additions & 0 deletions Content.Client/_LostParadise/Salvage/UI/LPOfferingWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,117 @@
using Content.Client.Computer;
using Content.Client.UserInterface.Controls;
using Content.Shared.Shuttles.BUIStates;
using Robust.Client.AutoGenerated;
using Robust.Client.Graphics;
using Robust.Client.UserInterface.XAML;
using Robust.Shared.Timing;

namespace Content.Client._LostParadise.Salvage.UI;

/// <summary>
/// Generic window for offering multiple selections with a timer.
/// </summary>
[GenerateTypedNameReferences]
public sealed partial class LPOfferingWindow : FancyWindow,
IComputerWindow<EmergencyConsoleBoundUserInterfaceState>
{
[Dependency] private readonly IGameTiming _timing = default!;

public bool Claimed;
public TimeSpan NextOffer;
private TimeSpan? _progression;

/// <summary>
/// Time between NextOffers
/// </summary>
public TimeSpan Cooldown;

/// <summary>
/// Time between Progressions
/// </summary>
public TimeSpan ProgressionCooldown;

/// <summary>
/// Secondary timer used for tracking active progress.
/// </summary>
public TimeSpan? Progression
{
get => _progression;
set
{
if (_progression == value)
return;

_progression = value;

if (value == null)
{
ProgressionBox.Visible = false;
}
else
{
ProgressionBox.Visible = true;
}
}
}

public LPOfferingWindow()
{
RobustXamlLoader.Load(this);
IoCManager.InjectDependencies(this);

ProgressionBar.ForegroundStyleBoxOverride = new StyleBoxFlat(Color.FromHex("#C74EBD"));
}

public void AddOption(LPOfferingWindowOption option)
{
Container.AddChild(option);
}

public void ClearOptions()
{
Container.DisposeAllChildren();
}

protected override void FrameUpdate(FrameEventArgs args)
{
base.FrameUpdate(args);

if (_progression != null)
{
var remaining = _progression.Value - _timing.CurTime;

if (remaining < TimeSpan.Zero)
{
ProgressionBar.Value = 1f;
ProgressionText.Text = "00:00";
}
else
{
ProgressionBar.Value = 1f - (float) (remaining / ProgressionCooldown);
ProgressionText.Text = $"{remaining.Minutes:00}:{remaining.Seconds:00}";
}
}

if (Claimed)
{
NextOfferBar.Value = 1f;
NextOfferText.Text = "00:00";
}
else
{
var remaining = NextOffer - _timing.CurTime;

if (remaining < TimeSpan.Zero)
{
NextOfferBar.Value = 1f;
NextOfferText.Text = "00:00";
}
else
{
NextOfferBar.Value = 1f - (float) (remaining / Cooldown);
NextOfferText.Text = $"{remaining.Minutes:00}:{remaining.Seconds:00}";
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<PanelContainer xmlns="https://spacestation14.io"
xmlns:controls="clr-namespace:Content.Client.UserInterface.Controls"
HorizontalExpand="True"
Name="BigPanel"
Margin="5 0">
<BoxContainer Orientation="Vertical"
Margin="5 5">
<!-- Title box -->
<controls:StripeBack>
<Label Name="TitleStripe"
HorizontalAlignment="Center"
Margin="0 5 0 5"/>
</controls:StripeBack>
<BoxContainer Orientation="Vertical" Name="ContentBox"/>
<!-- Buffer so all claim buttons are in the same position -->
<Control VerticalExpand="True"/>
<Button Name="ClaimButton"
HorizontalExpand="True"
VerticalAlignment="Bottom"
ToggleMode="True"
Disabled="True"
Text="{Loc 'offering-window-claim'}"/>
</BoxContainer>
</PanelContainer>
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
using System.Linq;
using Content.Client.Computer;
using Content.Client.Stylesheets;
using Content.Client.UserInterface.Controls;
using Content.Shared.CCVar;
using Content.Shared.Parallax.Biomes;
using Content.Shared.Procedural;
using Content.Shared._LostParadise.Salvage;
using Content.Shared._LostParadise.Salvage.Expeditions;
using Content.Shared._LostParadise.Salvage.Expeditions.Modifiers;
using Content.Shared.Shuttles.BUIStates;
using Robust.Client.AutoGenerated;
using Robust.Client.Graphics;
using Robust.Client.UserInterface;
using Robust.Client.UserInterface.Controls;
using Robust.Client.UserInterface.XAML;
using Robust.Shared.Configuration;
using Robust.Shared.Prototypes;
using Robust.Shared.Timing;
using Robust.Shared.Utility;

namespace Content.Client._LostParadise.Salvage.UI;

/// <summary>
/// Generic window for offering multiple selections with a timer.
/// </summary>
[GenerateTypedNameReferences]
public sealed partial class LPOfferingWindowOption : PanelContainer
{
private bool _claimed;

public string? Title
{
get => TitleStripe.Text;
set => TitleStripe.Text = value;
}

public event Action<BaseButton.ButtonEventArgs>? ClaimPressed;

public LPOfferingWindowOption()
{
RobustXamlLoader.Load(this);
IoCManager.InjectDependencies(this);

LayoutContainer.SetAnchorPreset(this, LayoutContainer.LayoutPreset.Wide);
BigPanel.PanelOverride = new StyleBoxFlat(new Color(30, 30, 34));

ClaimButton.OnPressed += args =>
{
ClaimPressed?.Invoke(args);
};
}

public void AddContent(Control control)
{
ContentBox.AddChild(control);
}

public bool Disabled
{
get => ClaimButton.Disabled;
set => ClaimButton.Disabled = value;
}

public bool Claimed
{
get => _claimed;
set
{
if (_claimed == value)
return;

_claimed = value;

if (_claimed)
{
ClaimButton.AddStyleClass(StyleBase.ButtonCaution);
ClaimButton.Text = Loc.GetString("offering-window-claimed");
}
else
{
ClaimButton.RemoveStyleClass(StyleBase.ButtonCaution);
ClaimButton.Text = Loc.GetString("offering-window-claim");
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
using Content.Shared._LostParadise.Salvage.Expeditions;
using JetBrains.Annotations;

namespace Content.Client._LostParadise.Salvage.UI;

[UsedImplicitly]
public sealed class LPSalvageExpeditionConsoleBoundUserInterface : BoundUserInterface
{
[ViewVariables]
private LPSalvageExpeditionWindow? _window;

public LPSalvageExpeditionConsoleBoundUserInterface(EntityUid owner, Enum uiKey) : base(owner, uiKey)
{
}

protected override void Open()
{
base.Open();
_window = new LPSalvageExpeditionWindow();
_window.ClaimMission += index =>
{
SendMessage(new ClaimLPSalvageMessage()
{
Index = index,
});
};
_window.FinishMission += () => SendMessage(new FinishLPSalvageMessage()); // Frontier
_window.OnClose += Close;
_window?.OpenCenteredLeft();
}

protected override void Dispose(bool disposing)
{
base.Dispose(disposing);
_window?.Dispose();
_window = null;
}

protected override void UpdateState(BoundUserInterfaceState state)
{
base.UpdateState(state);

if (state is not LPSalvageExpeditionConsoleState current)
return;

_window?.UpdateState(current);
}
}
Loading
Loading