-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
## Описание PR <!-- Что вы изменили в этом пулл реквесте? --> добавила 4 разновидностей кинетиков - рельсотрон, пистолет, повторитель, дробовик. Подробнее в их описании ## Почему / Баланс <!-- Почему оно было изменено? Ссылайтесь на любые обсуждения или вопросы здесь. Пожалуйста, обсудите, как это повлияет на игровой баланс. --> **Ссылка на публикацию в Discord** <!-- Укажите ссылки на соответствующие обсуждения, проблемы, баги, заказы в разработку или предложения - [Технические проблемы](ссылка) - [Баги](ссылка) - [Заказы-разработка](ссылка) - [Предложения](ссылка) - [Перенос контента](ссылка)--> баланс ## Техническая информация <!-- Если речь идет об изменении кода, кратко изложите на высоком уровне принцип работы нового кода. Это облегчает рецензирование.- --> ## Медиа <!-- Пулл реквесты, которые вносят внутриигровые изменения (добавление одежды, предметов, новых возможностей и т.д.), должны содержать медиа, демонстрирующие изменения. Небольшие исправления/рефакторы не требуют медиа. Если Вы не уверены в том, что Ваш пулл реквест требует медиа, спросите мейнтейнера. --> ## Требования <!-- В связи с наплывом ПР'ов нам необходимо убедиться, что ПР'ы следуют правильным рекомендациям. Пожалуйста, уделите время прочтению, если делаете пулл реквест (ПР) впервые. Отметьте поля ниже, чтобы подтвердить, что Вы действительно видели их (поставьте X в скобках, например [X]): --> - [ ] Я прочитал(а) и следую [Руководство по созданию пулл реквестов](https://docs.spacestation14.com/en/general-development/codebase-info/pull-request-guidelines.html). Я понимаю, что в противном случае мой ПР может быть закрыт по усмотрению мейнтейнера. - [ ] Я добавил скриншоты/видео к этому пулл реквесту, демонстрирующие его изменения в игре, **или** этот пулл реквест не требует демонстрации в игре ## Критические изменения <!-- Перечислите все критические изменения, включая изменения пространства имён, публичных классов/методов/полей, переименования прототипов, и предоставьте инструкции по их исправлению. --> **Чейнджлог** 🆑 Ratyyy - add: НТ одобрила 4 новых чертежа протокинетических ускорителей - рельсотрон, дробовик, пистолет и повторитель - remove: NT разорвали соглашение о ненападении с каргонией! Утилизаторы теперь могут стать раундстартовыми антагонистами.
- Loading branch information
Showing
43 changed files
with
538 additions
and
6 deletions.
There are no files selected for viewing
25 changes: 25 additions & 0 deletions
25
Content.Server/ADT/PressureDamageModify/PressureDamageModifyComponent.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,25 @@ | ||
using Content.Shared.Damage; | ||
|
||
namespace Content.Server.ADT.PressureDamageModify; | ||
|
||
[RegisterComponent] | ||
public sealed partial class PressureDamageModifyComponent : Component | ||
{ | ||
/// <summary> | ||
/// only for projectiles, doesn`t work for melee damage | ||
/// </summary> | ||
[ViewVariables(VVAccess.ReadWrite), DataField("projDamage")] | ||
public float ProjDamage = 0.2f; | ||
|
||
/// <summary> | ||
/// KPd, below which damage will diminishes. 0 kPa = 1 kPa | ||
/// </summary> | ||
[ViewVariables(VVAccess.ReadWrite), DataField("needsPressure")] | ||
public float Pressure = 40f; | ||
|
||
/// <summary> | ||
/// only for melee, doesn`t work for projectiles | ||
/// </summary> | ||
[DataField("additionalDamage")] | ||
public DamageSpecifier? AdditionalDamage = null; | ||
} |
71 changes: 71 additions & 0 deletions
71
Content.Server/ADT/PressureDamageModify/PressureDamageModifySystem.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,71 @@ | ||
using Content.Server.Popups; | ||
using Content.Shared.Projectiles; | ||
using Content.Shared.StatusEffect; | ||
using Content.Shared.Weapons.Ranged.Systems; | ||
using Robust.Server.GameObjects; | ||
using Robust.Shared.Map; | ||
using Robust.Shared.Random; | ||
using Content.Shared.Throwing; | ||
using Content.Shared.Weapons.Melee.Events; | ||
using System.Linq; | ||
using Content.Server.Atmos.EntitySystems; | ||
using Content.Shared.Damage; | ||
|
||
namespace Content.Server.ADT.PressureDamageModify; | ||
|
||
public sealed partial class PressureDamageModifySystem : EntitySystem | ||
{ | ||
[Dependency] private readonly DamageableSystem _damage = default!; // ADT-Changeling-Tweak | ||
[Dependency] private readonly EntityLookupSystem _lookup = default!; | ||
[Dependency] private readonly SharedTransformSystem _transform = default!; | ||
[Dependency] private readonly PopupSystem _popup = default!; | ||
[Dependency] private readonly IRobustRandom _random = default!; | ||
[Dependency] private readonly PhysicsSystem _physics = default!; | ||
[Dependency] private readonly IMapManager _mapMan = default!; | ||
[Dependency] private readonly AtmosphereSystem _atmosphereSystem = default!; | ||
public override void Initialize() | ||
{ | ||
base.Initialize(); | ||
|
||
SubscribeLocalEvent<PressureDamageModifyComponent, ProjectileHitEvent>(OnProjectileHit); | ||
|
||
SubscribeLocalEvent<PressureDamageModifyComponent, MeleeHitEvent>(OnMeleeHit); | ||
} | ||
private void OnProjectileHit(EntityUid uid, PressureDamageModifyComponent component, ref ProjectileHitEvent args) | ||
{ | ||
var pressure = 1f; | ||
|
||
if (_atmosphereSystem.GetContainingMixture(uid) is {} mixture) | ||
{ | ||
pressure = MathF.Max(mixture.Pressure, 1f); | ||
} | ||
if (pressure >= component.Pressure) | ||
{ | ||
args.Damage *= component.ProjDamage; | ||
} | ||
} | ||
|
||
private void OnMeleeHit(EntityUid uid, PressureDamageModifyComponent component, MeleeHitEvent args) | ||
{ | ||
if (!args.IsHit || | ||
!args.HitEntities.Any() || | ||
component.AdditionalDamage == null) | ||
{ | ||
return; | ||
} | ||
|
||
foreach (var ent in args.HitEntities) | ||
{ | ||
var pressure = 1f; | ||
|
||
if (_atmosphereSystem.GetContainingMixture(uid) is {} mixture) | ||
{ | ||
pressure = MathF.Max(mixture.Pressure, 1f); | ||
} | ||
if (pressure <= component.Pressure) | ||
{ | ||
_damage.TryChangeDamage(ent, component.AdditionalDamage); | ||
} | ||
} | ||
} | ||
} |
Binary file not shown.
11 changes: 11 additions & 0 deletions
11
Resources/Locale/ru-RU/ADT/prototypes/Entities/Objects/Weapons/Guns/PKAs.ftl
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,11 @@ | ||
ent-ADTWeaponProtoKineticPistol = протокинетический пистолет | ||
.desc = Имеет большую вместимость модификаций вместо высокого базового урона, что делает его по-настоящему модулируемым ПКА. | ||
ent-ADTWeaponProtoKineticRepeater = протокинетический повторитель | ||
.desc = Обменивает часть слотов для модификации и немного урона на возможность стрелять исключительно серией из 3-х быстрых выстрелов. Суммарно 3 выстрела нанесут больше урона, чем один выстрел ПКА. | ||
ent-ADTWeaponProtoKineticRailgun = протокинетический рельсотрон | ||
.desc = За место почти всех слотов для модификаций и скорости стрельбы имеет невероятно большой урон и пробивную силу, что может резать горы как плазменный резак. | ||
ent-ADTWeaponProtoKineticShotgun = протокинетический дробовик | ||
.desc = Стреляет на короткую дальность залпом из 4-х снарядов, что суммарно наносят больший урон, чем базовый ПКА. Имеет меньшую вместимость под модули. |
163 changes: 163 additions & 0 deletions
163
Resources/Prototypes/ADT/Entities/Objects/Weapons/Guns/PKAs/PKAs.yml
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,163 @@ | ||
- type: entity | ||
name: proto-kinetic pistol | ||
id: ADTWeaponProtoKineticPistol | ||
parent: [WeaponProtoKineticAcceleratorBase, BaseCargoContraband] | ||
description: The Pistol trades base damage, and range, for double mod capacity, making it a truely customizable PKA. | ||
components: | ||
- type: Sprite | ||
sprite: ADT/Objects/Weapons/Guns/PKAs/kinetic_pistol.rsi | ||
layers: | ||
- state: icon | ||
- state: animation-icon | ||
visible: false | ||
map: [ "empty-icon" ] | ||
- type: UpgradeableGun | ||
maxUpgradeCount: 7 | ||
whitelist: | ||
tags: | ||
- PKAUpgrade | ||
- type: ContainerContainer | ||
containers: | ||
upgrades: !type:Container | ||
- type: Item | ||
sprite: ADT/Objects/Weapons/Guns/PKAs/kinetic_pistol.rsi | ||
size: Small | ||
- type: BasicEntityAmmoProvider | ||
proto: ADTBulletKineticPistol | ||
capacity: 1 | ||
count: 1 | ||
- type: Clothing | ||
sprite: ADT/Objects/Weapons/Guns/PKAs/kinetic_pistol.rsi | ||
quickEquip: false | ||
slots: | ||
- suitStorage | ||
- Belt | ||
|
||
- type: entity | ||
name: proto-kinetic repeater | ||
id: ADTWeaponProtoKineticRepeater | ||
parent: [WeaponProtoKineticAcceleratorBase, BaseCargoContraband] | ||
description: The Repeater trades mod space and a bit of damage for the ability to fire three shots in rapid succession before needing to recharge, while also doing more damage than base PKA if all three shots are landed. | ||
components: | ||
- type: Sprite | ||
sprite: ADT/Objects/Weapons/Guns/PKAs/kinetic_repeater.rsi | ||
layers: | ||
- state: icon | ||
- state: animation-icon | ||
visible: false | ||
map: [ "empty-icon" ] | ||
- type: UpgradeableGun | ||
maxUpgradeCount: 2 | ||
whitelist: | ||
tags: | ||
- PKAUpgrade | ||
- type: ContainerContainer | ||
containers: | ||
upgrades: !type:Container | ||
- type: Item | ||
sprite: ADT/Objects/Weapons/Guns/PKAs/kinetic_repeater.rsi | ||
- type: BasicEntityAmmoProvider | ||
proto: ADTBulletKineticRepeater | ||
capacity: 3 | ||
count: 3 | ||
- type: Gun | ||
resetOnHandSelected: false | ||
burstCooldown: 2 | ||
fireRate: 0.5 | ||
selectedMode: Burst | ||
angleDecay: 45 | ||
minAngle: 2 | ||
maxAngle: 3 | ||
availableModes: | ||
- Burst | ||
soundGunshot: | ||
path: /Audio/Weapons/Guns/Gunshots/kinetic_accel.ogg | ||
- type: RechargeBasicEntityAmmo | ||
rechargeCooldown: 0.25 | ||
rechargeSound: | ||
path: /Audio/Weapons/Guns/MagIn/kinetic_reload.ogg | ||
- type: Clothing | ||
sprite: ADT/Objects/Weapons/Guns/PKAs/kinetic_repeater.rsi | ||
quickEquip: false | ||
slots: | ||
- suitStorage | ||
- Belt | ||
|
||
- type: entity | ||
name: proto-kinetic raingun | ||
id: ADTWeaponProtoKineticRailgun | ||
parent: [WeaponProtoKineticAcceleratorBase, BaseCargoContraband] | ||
description: The Railgun trades customization, fire rate, and storage capabilities for the ability to fire a high damage shot that penetrates creatures! | ||
components: | ||
- type: Sprite | ||
sprite: ADT/Objects/Weapons/Guns/PKAs/kinetic_railgun.rsi | ||
layers: | ||
- state: icon | ||
- state: animation-icon | ||
visible: false | ||
map: [ "empty-icon" ] | ||
- type: UpgradeableGun | ||
maxUpgradeCount: 1 | ||
whitelist: | ||
tags: | ||
- PKAUpgrade | ||
- type: ContainerContainer | ||
containers: | ||
upgrades: !type:Container | ||
- type: Item | ||
sprite: ADT/Objects/Weapons/Guns/PKAs/kinetic_railgun.rsi | ||
size: Normal | ||
- type: BasicEntityAmmoProvider | ||
proto: ADTBulletKineticRailgun | ||
capacity: 1 | ||
count: 1 | ||
- type: Gun | ||
resetOnHandSelected: false | ||
fireRate: 0.3 | ||
angleDecay: 45 | ||
minAngle: 2 | ||
maxAngle: 3 | ||
cameraRecoilScalar: 6 | ||
soundGunshot: | ||
path: /Audio/ADT/Weapons/Guns/Gunshots/beam_sniper.ogg | ||
- type: Clothing | ||
sprite: ADT/Objects/Weapons/Guns/PKAs/kinetic_railgun.rsi | ||
quickEquip: false | ||
slots: | ||
- suitStorage | ||
- Belt | ||
|
||
- type: entity | ||
name: proto-kinetic shotgun | ||
id: ADTWeaponProtoKineticShotgun | ||
parent: [WeaponProtoKineticAcceleratorBase, BaseCargoContraband] | ||
description: The Shotgun fires a short range set of three rounds that does more damage than base PKA if all three shots land. This trades mod capacity and cooldown speed. | ||
components: | ||
- type: Sprite | ||
sprite: ADT/Objects/Weapons/Guns/PKAs/kinetic_shotgun.rsi | ||
layers: | ||
- state: icon | ||
- state: animation-icon | ||
visible: false | ||
map: [ "empty-icon" ] | ||
- type: UpgradeableGun | ||
maxUpgradeCount: 2 | ||
whitelist: | ||
tags: | ||
- PKAUpgrade | ||
- type: ContainerContainer | ||
containers: | ||
upgrades: !type:Container | ||
- type: Item | ||
sprite: ADT/Objects/Weapons/Guns/PKAs/kinetic_shotgun.rsi | ||
size: Normal | ||
- type: BasicEntityAmmoProvider | ||
proto: ADTBulletKineticShotgunSpread | ||
capacity: 1 | ||
count: 1 | ||
- type: Clothing | ||
sprite: ADT/Objects/Weapons/Guns/PKAs/kinetic_shotgun.rsi | ||
quickEquip: false | ||
slots: | ||
- suitStorage | ||
- Belt |
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
Oops, something went wrong.