Твики (#491)
* Economy additions * Tweak implant cooldowns * Cult stuff * Random appearance aspect nuke ops fix * Auto shuttle enable on round end * Holy water threshold
This commit is contained in:
@@ -12,7 +12,7 @@
|
|||||||
<Label Name="StatusLabel"/>
|
<Label Name="StatusLabel"/>
|
||||||
<SliderIntInput Name="WithdrawSlider"/>
|
<SliderIntInput Name="WithdrawSlider"/>
|
||||||
<BoxContainer HorizontalExpand="True" VerticalExpand="True" VerticalAlignment="Bottom" Orientation="Horizontal">
|
<BoxContainer HorizontalExpand="True" VerticalExpand="True" VerticalAlignment="Bottom" Orientation="Horizontal">
|
||||||
<LineEdit Name="PinLineEdit" HorizontalExpand="True" Text="Enter PIN"/>
|
<LineEdit Name="PinLineEdit" HorizontalExpand="True" Text="{Loc 'atm-ui-enter-pin'}"/>
|
||||||
<Button Name="WithdrawButton" Text="{Loc 'store-ui-default-withdraw-text'}"/>
|
<Button Name="WithdrawButton" Text="{Loc 'store-ui-default-withdraw-text'}"/>
|
||||||
</BoxContainer>
|
</BoxContainer>
|
||||||
</BoxContainer>
|
</BoxContainer>
|
||||||
|
|||||||
@@ -40,6 +40,7 @@ public sealed partial class AtmWindow : DefaultWindow
|
|||||||
StatusLabel.Text = cast.InfoMessage;
|
StatusLabel.Text = cast.InfoMessage;
|
||||||
BalanceLabel.Visible = false;
|
BalanceLabel.Visible = false;
|
||||||
Divider.Visible = false;
|
Divider.Visible = false;
|
||||||
|
StatusLabel.Visible = true;
|
||||||
WithdrawSlider.Visible = false;
|
WithdrawSlider.Visible = false;
|
||||||
PinLineEdit.Visible = false;
|
PinLineEdit.Visible = false;
|
||||||
WithdrawButton.Visible = false;
|
WithdrawButton.Visible = false;
|
||||||
@@ -50,13 +51,25 @@ public sealed partial class AtmWindow : DefaultWindow
|
|||||||
|
|
||||||
BalanceLabel.Text = Loc.GetString("atm-ui-balance", ("balance", cast.AccountBalance));
|
BalanceLabel.Text = Loc.GetString("atm-ui-balance", ("balance", cast.AccountBalance));
|
||||||
BalanceLabel.Visible = true;
|
BalanceLabel.Visible = true;
|
||||||
Divider.Visible = true;
|
|
||||||
WithdrawSlider.Visible = true;
|
|
||||||
PinLineEdit.Visible = true;
|
|
||||||
WithdrawButton.Visible = true;
|
|
||||||
|
|
||||||
WithdrawSlider.MaxValue = cast.AccountBalance;
|
if (cast.AccountBalance > 0)
|
||||||
WithdrawSlider.Value = Math.Min(WithdrawSlider.Value, cast.AccountBalance);
|
{
|
||||||
|
Divider.Visible = true;
|
||||||
|
StatusLabel.Visible = true;
|
||||||
|
WithdrawSlider.Visible = true;
|
||||||
|
PinLineEdit.Visible = true;
|
||||||
|
WithdrawButton.Visible = true;
|
||||||
|
|
||||||
|
WithdrawSlider.MaxValue = cast.AccountBalance;
|
||||||
|
WithdrawSlider.Value = Math.Min(WithdrawSlider.Value, cast.AccountBalance);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
Divider.Visible = false;
|
||||||
|
StatusLabel.Visible = false;
|
||||||
|
WithdrawSlider.Visible = false;
|
||||||
|
PinLineEdit.Visible = false;
|
||||||
|
WithdrawButton.Visible = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void FrameUpdate(FrameEventArgs args)
|
protected override void FrameUpdate(FrameEventArgs args)
|
||||||
|
|||||||
@@ -459,6 +459,7 @@ namespace Content.Server.GameTicking
|
|||||||
ResettingCleanup();
|
ResettingCleanup();
|
||||||
IncrementRoundNumber();
|
IncrementRoundNumber();
|
||||||
SendRoundStartingDiscordMessage();
|
SendRoundStartingDiscordMessage();
|
||||||
|
EnableShuttleCall(); // WD
|
||||||
|
|
||||||
if (!LobbyEnabled)
|
if (!LobbyEnabled)
|
||||||
{
|
{
|
||||||
@@ -572,6 +573,15 @@ namespace Content.Server.GameTicking
|
|||||||
_utkaSocketWrapper.SendMessageToAll(utkaRoundStatusEvent);
|
_utkaSocketWrapper.SendMessageToAll(utkaRoundStatusEvent);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void EnableShuttleCall()
|
||||||
|
{
|
||||||
|
if (_configurationManager.GetCVar(WhiteCVars.EmergencyShuttleCallEnabled))
|
||||||
|
return;
|
||||||
|
|
||||||
|
_configurationManager.SetCVar(WhiteCVars.EmergencyShuttleCallEnabled, true);
|
||||||
|
_chatManager.SendAdminAnnouncement("Вызов шаттла включен.");
|
||||||
|
}
|
||||||
//WD-EDIT
|
//WD-EDIT
|
||||||
|
|
||||||
private void UpdateRoundFlow(float frameTime)
|
private void UpdateRoundFlow(float frameTime)
|
||||||
|
|||||||
@@ -164,7 +164,10 @@ namespace Content.Server.VendingMachines
|
|||||||
private void OnEmagged(EntityUid uid, VendingMachineComponent component, ref GotEmaggedEvent args)
|
private void OnEmagged(EntityUid uid, VendingMachineComponent component, ref GotEmaggedEvent args)
|
||||||
{
|
{
|
||||||
// only emag if there are emag-only items
|
// only emag if there are emag-only items
|
||||||
args.Handled = component.EmaggedInventory.Count > 0;
|
args.Handled = component.EmaggedInventory.Count > 0 || component.PriceMultiplier > 0; // WD EDIT START
|
||||||
|
component.PriceMultiplier = 0;
|
||||||
|
UpdateVendingMachineInterfaceState(uid, component);
|
||||||
|
// WD EDIT END
|
||||||
}
|
}
|
||||||
|
|
||||||
private void OnDamage(EntityUid uid, VendingMachineComponent component, DamageChangedEvent args)
|
private void OnDamage(EntityUid uid, VendingMachineComponent component, DamageChangedEvent args)
|
||||||
|
|||||||
@@ -1,6 +1,9 @@
|
|||||||
using System.Linq;
|
using System.Linq;
|
||||||
using Content.Server.Stack;
|
using Content.Server.Stack;
|
||||||
using Content.Server.Store.Components;
|
using Content.Server.Store.Components;
|
||||||
|
using Content.Shared.Destructible;
|
||||||
|
using Content.Shared.Emag.Components;
|
||||||
|
using Content.Shared.Emag.Systems;
|
||||||
using Content.Shared.Interaction;
|
using Content.Shared.Interaction;
|
||||||
using Content.Shared.Popups;
|
using Content.Shared.Popups;
|
||||||
using Content.Shared.Stacks;
|
using Content.Shared.Stacks;
|
||||||
@@ -32,6 +35,12 @@ public sealed class ATMSystem : SharedATMSystem
|
|||||||
SubscribeLocalEvent<ATMComponent, ATMRequestWithdrawMessage>(OnWithdrawRequest);
|
SubscribeLocalEvent<ATMComponent, ATMRequestWithdrawMessage>(OnWithdrawRequest);
|
||||||
SubscribeLocalEvent<ATMComponent, InteractUsingEvent>(OnInteractUsing);
|
SubscribeLocalEvent<ATMComponent, InteractUsingEvent>(OnInteractUsing);
|
||||||
SubscribeLocalEvent<ATMComponent, ComponentStartup>(OnComponentStartup);
|
SubscribeLocalEvent<ATMComponent, ComponentStartup>(OnComponentStartup);
|
||||||
|
SubscribeLocalEvent<ATMComponent, GotEmaggedEvent>(OnEmag);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnEmag(EntityUid uid, ATMComponent component, ref GotEmaggedEvent args)
|
||||||
|
{
|
||||||
|
args.Handled = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void OnComponentStartup(EntityUid uid, ATMComponent component, ComponentStartup args)
|
private void OnComponentStartup(EntityUid uid, ATMComponent component, ComponentStartup args)
|
||||||
@@ -89,7 +98,8 @@ public sealed class ATMSystem : SharedATMSystem
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!_bankCardSystem.TryGetAccount(bankCard.BankAccountId.Value, out var account) || account.AccountPin != args.Pin)
|
if (!_bankCardSystem.TryGetAccount(bankCard.BankAccountId.Value, out var account) ||
|
||||||
|
account.AccountPin != args.Pin && !HasComp<EmaggedComponent>(uid))
|
||||||
{
|
{
|
||||||
_popupSystem.PopupEntity(Loc.GetString("atm-wrong-pin"), uid);
|
_popupSystem.PopupEntity(Loc.GetString("atm-wrong-pin"), uid);
|
||||||
_audioSystem.PlayPvs(component.SoundDeny, uid);
|
_audioSystem.PlayPvs(component.SoundDeny, uid);
|
||||||
|
|||||||
@@ -26,7 +26,7 @@ public sealed class EftposSystem : EntitySystem
|
|||||||
private void OnInteractUsing(EntityUid uid, EftposComponent component, InteractUsingEvent args)
|
private void OnInteractUsing(EntityUid uid, EftposComponent component, InteractUsingEvent args)
|
||||||
{
|
{
|
||||||
if (component.BankAccountId == null || !TryComp(args.Used, out BankCardComponent? bankCard) ||
|
if (component.BankAccountId == null || !TryComp(args.Used, out BankCardComponent? bankCard) ||
|
||||||
bankCard.BankAccountId == component.BankAccountId || component.Amount <= 0)
|
bankCard.BankAccountId == component.BankAccountId || component.Amount <= 0 || bankCard.CommandBudgetCard)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (_bankCardSystem.TryChangeBalance(bankCard.BankAccountId!.Value, -component.Amount) &&
|
if (_bankCardSystem.TryChangeBalance(bankCard.BankAccountId!.Value, -component.Amount) &&
|
||||||
|
|||||||
@@ -1,7 +1,10 @@
|
|||||||
|
using System.Linq;
|
||||||
using Content.Server.Access.Systems;
|
using Content.Server.Access.Systems;
|
||||||
using Content.Server.Humanoid;
|
using Content.Server.Humanoid;
|
||||||
using Content.Server.IdentityManagement;
|
using Content.Server.IdentityManagement;
|
||||||
|
using Content.Server.Mind.Components;
|
||||||
using Content.Server.PDA;
|
using Content.Server.PDA;
|
||||||
|
using Content.Server.Roles;
|
||||||
using Content.Shared.Access.Components;
|
using Content.Shared.Access.Components;
|
||||||
using Content.Shared.Inventory;
|
using Content.Shared.Inventory;
|
||||||
using Content.Shared.PDA;
|
using Content.Shared.PDA;
|
||||||
@@ -31,6 +34,10 @@ public sealed class RandomHumanSystem : EntitySystem
|
|||||||
|
|
||||||
_humanoid.LoadProfile(uid, newProfile);
|
_humanoid.LoadProfile(uid, newProfile);
|
||||||
|
|
||||||
|
if (TryComp(uid, out MindContainerComponent? mindContainer) && mindContainer.HasMind &&
|
||||||
|
mindContainer.Mind.Roles.OfType<NukeopsRole>().Any())
|
||||||
|
return;
|
||||||
|
|
||||||
_metaData.SetEntityName(uid, newProfile.Name);
|
_metaData.SetEntityName(uid, newProfile.Name);
|
||||||
|
|
||||||
if (!_inventorySystem.TryGetSlotEntity(uid, "id", out var idUid))
|
if (!_inventorySystem.TryGetSlotEntity(uid, "id", out var idUid))
|
||||||
|
|||||||
1
Resources/Locale/ru-RU/cult/effects.ftl
Normal file
1
Resources/Locale/ru-RU/cult/effects.ftl
Normal file
@@ -0,0 +1 @@
|
|||||||
|
reagent-effect-guidebook-deconvert-cultist = Деконвертирует культиста
|
||||||
@@ -3,6 +3,7 @@ atm-wrong-pin = Неверный PIN-код.
|
|||||||
atm-not-enough-cash = Недостаточно средств.
|
atm-not-enough-cash = Недостаточно средств.
|
||||||
|
|
||||||
|
|
||||||
|
atm-ui-enter-pin = Введите PIN
|
||||||
atm-ui-select-withdraw-amount = Выберите сумму вывода.
|
atm-ui-select-withdraw-amount = Выберите сумму вывода.
|
||||||
atm-ui-insert-card = Вставьте карту.
|
atm-ui-insert-card = Вставьте карту.
|
||||||
atm-ui-balance = Баланс: { $balance } ¢
|
atm-ui-balance = Баланс: { $balance } ¢
|
||||||
|
|||||||
@@ -114,8 +114,7 @@
|
|||||||
noSpawn: true
|
noSpawn: true
|
||||||
components:
|
components:
|
||||||
- type: InstantAction
|
- type: InstantAction
|
||||||
charges: 3
|
useDelay: 40
|
||||||
useDelay: 5
|
|
||||||
itemIconStyle: BigAction
|
itemIconStyle: BigAction
|
||||||
priority: -20
|
priority: -20
|
||||||
icon:
|
icon:
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
noSpawn: true
|
noSpawn: true
|
||||||
components:
|
components:
|
||||||
- type: InstantAction
|
- type: InstantAction
|
||||||
useDelay: 20
|
useDelay: 40
|
||||||
itemIconStyle: BigAction
|
itemIconStyle: BigAction
|
||||||
priority: -20
|
priority: -20
|
||||||
icon:
|
icon:
|
||||||
|
|||||||
@@ -44,15 +44,17 @@
|
|||||||
enabled: false
|
enabled: false
|
||||||
sound:
|
sound:
|
||||||
path: /Audio/Ambience/Objects/vending_machine_hum.ogg
|
path: /Audio/Ambience/Objects/vending_machine_hum.ogg
|
||||||
# - type: Destructible
|
- type: Damageable
|
||||||
# thresholds:
|
damageContainer: Inorganic
|
||||||
# - trigger:
|
damageModifierSet: Metallic
|
||||||
# !type:DamageTrigger
|
- type: Destructible
|
||||||
# damage: 100
|
thresholds:
|
||||||
# behaviors:
|
- trigger:
|
||||||
# - !type:DoActsBehavior
|
!type:DamageTrigger
|
||||||
# acts: ["Breakage"]
|
damage: 100
|
||||||
# - !type:EjectVendorItems
|
behaviors:
|
||||||
|
- !type:DoActsBehavior
|
||||||
|
acts: ["Destruction"]
|
||||||
- type: ActivatableUI
|
- type: ActivatableUI
|
||||||
key: enum.ATMUiKey.Key
|
key: enum.ATMUiKey.Key
|
||||||
singleUser: true
|
singleUser: true
|
||||||
|
|||||||
Reference in New Issue
Block a user