Skip to content

Commit

Permalink
[Port] EE Plushie & Xenowears (space-syndicate#751)
Browse files Browse the repository at this point in the history
* [Port] Xenowears (space-syndicate#12)

* Xenowears (space-syndicate#519)

<!--
This is a semi-strict format, you can add/remove sections as needed but
the order/format should be kept the same
Remove these comments before submitting
-->

<!--
Explain this PR in as much detail as applicable

Some example prompts to consider:
How might this affect the game? The codebase?
What might be some alternatives to this?
How/Who does this benefit/hurt [the game/codebase]?
-->

Add a bit of clothing specie related and some tiny misc changes.

Normally i wanted to add the spooders changes here but with the other
spider specie coming in il hold myself for now.

---

<!--
A list of everything you have to do before this PR is "complete"
You probably won't have to complete everything before merging but it's
good to leave future references
-->

- [x] Add clothings
- [x] Loadouts/Vending machines

---

<!--
This is default collapsed, readers click to expand it and see all your
media
The PR media section can get very large at times, so this is a good way
to keep it clean
The title is written using HTML tags
The title must be within the <summary> tags or you won't see it
-->

<details><summary><h1>Media</h1></summary>
<p>

![image](https://github.com/Simple-Station/Einstein-Engines/assets/45297731/47865d65-754d-4b70-9c10-19bc9aa55ac6)

</p>
</details>

---

<!--
You can add an author after the `:cl:` to change the name that appears
in the changelog (ex: `:cl: Death`)
Leaving it blank will default to your GitHub display name
This includes all available types for the changelog
-->

:cl:
- add: Xenowears! new non-human related clothings.

---------

Signed-off-by: FoxxoTrystan <[email protected]>
Co-authored-by: DEATHB4DEFEAT <[email protected]>
Co-authored-by: VMSolidus <[email protected]>

* ooopsie

---------

Signed-off-by: FoxxoTrystan <[email protected]>
Co-authored-by: FoxxoTrystan <[email protected]>
Co-authored-by: DEATHB4DEFEAT <[email protected]>
Co-authored-by: VMSolidus <[email protected]>

* [Port] Plushie (space-syndicate#11)

* Plushie Update! (space-syndicate#654)

<!--
This is a semi-strict format, you can add/remove sections as needed but
the order/format should be kept the same
Remove these comments before submitting
-->

<!--
Explain this PR in as much detail as applicable

Some example prompts to consider:
How might this affect the game? The codebase?
What might be some alternatives to this?
How/Who does this benefit/hurt [the game/codebase]?
-->

By multiple requests i bring my PR from Frontier The [PLUSHIE
UPDATE!](new-frontiers-14/frontier-station-14#886)

This PR add a prize vendor machine where you can trade prize ticket for
a toy/plushie, to get ticket you win those in arcade machines.

This PR will give a chance for everyone to get the toys they need in a
special machine and will make plushies in general more random and fun,
in term of random spawns.

WARNING THIS PR DOES NOT MAP THE PRIZE VENDOR AND WILL MOSTLY NEED TO BE
MAPPED.

---

<!--
A list of everything you have to do before this PR is "complete"
You probably won't have to complete everything before merging but it's
good to leave future references
-->

- [x] Prize Vendor
- [x] Prize Tickets
- [x] New Toys/Plushies
- [x] Prizes

---

<!--
This is default collapsed, readers click to expand it and see all your
media
The PR media section can get very large at times, so this is a good way
to keep it clean
The title is written using HTML tags
The title must be within the <summary> tags or you won't see it
-->

<details><summary><h1>Media</h1></summary>
<p>

![image](https://github.com/user-attachments/assets/643e6c65-bba0-4eef-8e8e-d3510922e51e)

</p>
</details>

---

<!--
You can add an author after the `:cl:` to change the name that appears
in the changelog (ex: `:cl: Death`)
Leaving it blank will default to your GitHub display name
This includes all available types for the changelog
-->

:cl:
- add: A ton of new plushies has arrived
- add: Prize counter are here, get your prizes by winning games and
getting prize tickets! and find prize balls!!

* prize counter to spawner

* Arachne Plushie (space-syndicate#531)

Added everyone's favorite Arachne as an adorable soft toy

---

- [x] Place plushie in spawn location(s)

---

<details><summary><h1>Media</h1></summary>
<p>

![ArchnePlush](https://github.com/Simple-Station/Einstein-Engines/assets/114866135/1ec47181-4827-49f9-8605-9a16764dba89)

</p>
</details>

---

:cl:
- add: Plushie

* ooopsie

---------

Co-authored-by: FoxxoTrystan <[email protected]>
Co-authored-by: CodedCrow <[email protected]>

* [Fix] EE Migration (space-syndicate#14)

* [Tweak] Add Einstein Engines Folders (space-syndicate#17)

* [Tweak] EE Prototypes Folder

* [Tweak] EE RU FTL

* fix dublicate

* yaml fixes

---------

Signed-off-by: FoxxoTrystan <[email protected]>
Co-authored-by: FoxxoTrystan <[email protected]>
Co-authored-by: DEATHB4DEFEAT <[email protected]>
Co-authored-by: VMSolidus <[email protected]>
Co-authored-by: CodedCrow <[email protected]>
  • Loading branch information
5 people committed Nov 25, 2024
1 parent dd0017f commit f673c3c
Show file tree
Hide file tree
Showing 106 changed files with 2,471 additions and 130 deletions.
35 changes: 35 additions & 0 deletions Content.Shared/Clothing/Components/EmitsSoundOnMoveComponent.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
using Robust.Shared.Audio;
using Robust.Shared.GameStates;
using Robust.Shared.Map;

namespace Content.Shared.Clothing.Components; // EinsteinEngines CODE

/// <summary>
/// Indicates that the clothing entity emits sound when it moves.
/// </summary>
[RegisterComponent, NetworkedComponent, AutoGenerateComponentState]
public sealed partial class EmitsSoundOnMoveComponent : Component
{
[ViewVariables(VVAccess.ReadWrite)]
[DataField(required: true), AutoNetworkedField]
public SoundSpecifier SoundCollection = default!;

[ViewVariables(VVAccess.ReadWrite)]
[DataField("requiresGravity"), AutoNetworkedField]
public bool RequiresGravity = true;

[ViewVariables(VVAccess.ReadOnly)]
public EntityCoordinates LastPosition = EntityCoordinates.Invalid;

/// <summary>
/// The distance moved since the played sound.
/// </summary>
[ViewVariables(VVAccess.ReadOnly)]
public float SoundDistance = 0f;

/// <summary>
/// Whether this item is equipped in a inventory item slot.
/// </summary>
[ViewVariables(VVAccess.ReadOnly)]
public bool IsSlotValid = true;
}
96 changes: 96 additions & 0 deletions Content.Shared/Clothing/EntitySystems/EmitsSoundOnMoveSystem.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
using System.Numerics;
using Content.Shared.Clothing.Components;
using Content.Shared.Gravity;
using Content.Shared.Inventory;
using Content.Shared.Inventory.Events;
using Content.Shared.Mobs.Components;
using Content.Shared.Movement.Components;
using Robust.Shared.Audio.Systems;
using Robust.Shared.Physics.Components;
using Robust.Shared.Timing;

namespace Content.Shared.Clothing.Systems; // EinsteinEngines CODE

public sealed class EmitsSoundOnMoveSystem : EntitySystem
{
[Dependency] private readonly SharedAudioSystem _audio = default!;
[Dependency] private readonly SharedMapSystem _grid = default!;
[Dependency] private readonly SharedGravitySystem _gravity = default!;
[Dependency] private readonly IGameTiming _timing = default!;

private EntityQuery<InputMoverComponent> _moverQuery;
private EntityQuery<PhysicsComponent> _physicsQuery;
private EntityQuery<ClothingComponent> _clothingQuery;

public override void Initialize()
{
_moverQuery = GetEntityQuery<InputMoverComponent>();
_physicsQuery = GetEntityQuery<PhysicsComponent>();
_clothingQuery = GetEntityQuery<ClothingComponent>();

SubscribeLocalEvent<EmitsSoundOnMoveComponent, GotEquippedEvent>(OnEquipped);
SubscribeLocalEvent<EmitsSoundOnMoveComponent, GotUnequippedEvent>(OnUnequipped);
}

private void OnEquipped(EntityUid uid, EmitsSoundOnMoveComponent component, GotEquippedEvent args)
{
component.IsSlotValid = !args.SlotFlags.HasFlag(SlotFlags.POCKET);
}

private void OnUnequipped(EntityUid uid, EmitsSoundOnMoveComponent component, GotUnequippedEvent args)
{
component.IsSlotValid = true;
}

public override void Update(float frameTime)
{
var query = EntityQueryEnumerator<EmitsSoundOnMoveComponent>();
while (query.MoveNext(out var uid, out var comp))
{
UpdateSound(uid, comp);
}
query.Dispose();
}

private void UpdateSound(EntityUid uid, EmitsSoundOnMoveComponent component)
{
if (!_physicsQuery.TryGetComponent(uid, out var physics))
return;

// Space does not transmit sound
if (Transform(uid).GridUid == null)
return;

if (component.RequiresGravity && _gravity.IsWeightless(uid, physics, Transform(uid)))
return;

var parent = Transform(uid).ParentUid;

var isWorn = parent is { Valid: true } &&
_clothingQuery.TryGetComponent(uid, out var clothing)
&& clothing.InSlot != null
&& component.IsSlotValid;
// If this entity is worn by another entity, use that entity's coordinates
var coordinates = isWorn ? Transform(parent).Coordinates : Transform(uid).Coordinates;
var distanceNeeded = (isWorn && _moverQuery.TryGetComponent(parent, out var mover) && mover.Sprinting)
? 1.5f // The parent is a mob that is currently sprinting
: 2f; // The parent is not a mob or is not sprinting

if (!coordinates.TryDistance(EntityManager, component.LastPosition, out var distance) || distance > distanceNeeded)
component.SoundDistance = distanceNeeded;
else
component.SoundDistance += distance;

component.LastPosition = coordinates;
if (component.SoundDistance < distanceNeeded)
return;
component.SoundDistance -= distanceNeeded;

var sound = component.SoundCollection;
var audioParams = sound.Params
.WithVolume(sound.Params.Volume)
.WithVariation(sound.Params.Variation ?? 0f);

_audio.PlayPredicted(sound, uid, uid, audioParams);
}
}
Binary file added Resources/Audio/Effects/silence.ogg
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ent-ClothingClothWrap = тканевые обёртки
.desc = Рулон обработанной ткани, используемый для обёртки когтей и лап.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
ent-ClothingNeckOldMantle = старая обертка
.desc = Изношенная тканевая обертка, выцветшая с годами. Слабо пахнет сигарами.
ent-ClothingNeckUnathiMantle = плащ из шкур
.desc = Довольно жуткая подборка высушенных шкур и кожи, сшитых вместе, чтобы создать рваный плащ.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ent-ClothingNeckBellCollar = ошейник с колокольчиком
.desc = Способ уведомить остальных о своем присутствии или просто раздражать всех вокруг!
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ent-ClothingOuterUnathiRobe = традиционная одежда
.desc = Традиционная одежда ящеров.
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
ent-PrizeTicketBase = билет на приз
.desc = Билет на приз, готовый к обмену на приз в бьюти-центре.
ent-PrizeTicket = { ent-PrizeTicketBase }
.desc = { ent-PrizeTicketBase.desc }
ent-PrizeTicket10 = { ent-PrizeTicketBase }
.desc = { ent-PrizeTicketBase.desc }
ent-PrizeTicket30 = { ent-PrizeTicketBase }
.desc = { ent-PrizeTicketBase.desc }
ent-PrizeTicket60 = { ent-PrizeTicketBase }
.desc = { ent-PrizeTicketBase.desc }
ent-PrizeTicket1 = { ent-PrizeTicketBase }
.desc = { ent-PrizeTicketBase.desc }
ent-PrizeBall = призовой шар
.desc = Интересно, что внутри!
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
ent-PetRockCarrier = переноска для камня-питомца
.desc = Ваш новый и единственный лучший друг дома!
ent-BasePetRock = камень-питомец
.desc = Ваш новый и единственный лучший друг!
ent-PetRock = { ent-BasePetRock }
.desc = { ent-BasePetRock.desc }
ent-PetRockFred = Фред
.desc = { ent-BasePetRock.desc }
ent-PetRockRoxie = Рокси
.desc = { ent-BasePetRock.desc }
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
ent-PlushieArachne = плюшевая арахна
.desc = Плюшевая игрушка арахне — полулюдское, полузначное существо. Почему оно выглядит знакомо?
ent-PlushieJester = плюшевый ящер шут
.desc = Сомнительное плюшевое создание, затевающее пакости.
ent-PlushieSlips = плюшевый ящер уборщик
.desc = Тихий уборщик, его позывной подскальзун!
ent-PlushieGnome = плюшевый гном
.desc = Плюшевая игрушка, напоминающая гнома или дварфа...
ent-PlushieLoveable = плюшевый ласкатель
.desc = Плюшевая игрушка, напоминающая... какое-то существо.
ent-PlushieDeer = плюшевый олень
.desc = Плюшевая игрушка, напоминающая оленя!
ent-PlushieIpc = плюшевый ИПС
.desc = Плюшевая игрушка, напоминающая ИПС!
ent-PlushieGrey = плюшевый серый
.desc = Плюшевая игрушка, напоминающая серое существо!
ent-PlushieAbductor = плюшевый абдуктор
.desc = Плюшевая игрушка, напоминающая абдуктора!
ent-PlushieAbductorAgent = плюшевый агент абдуктор
.desc = Плюшевая игрушка, напоминающая агента абдуктора!
ent-PlushieRedFox = плюшевая красная лиса
.desc = Милая плюшевая игрушка, напоминающая красную лису!
ent-PlushiePurpleFox = плюшевая фиолетовая лиса
.desc = Милая плюшевая игрушка, напоминающая фиолетовую лису!
ent-PlushiePinkFox = плюшевая розовая лиса
.desc = Милая плюшевая игрушка, напоминающая розовую лису!
ent-PlushieOrangeFox = плюшевая оранжевая лиса
.desc = Милая плюшевая игрушка, напоминающая оранжевая лису!
ent-PlushieMarbleFox = плюшевая мраморная лиса
.desc = Милая плюшевая игрушка, напоминающая мрамортную лису!
ent-PlushieCrimsonFox = плюшевая алая лиса
.desc = Милая плюшевая игрушка, напоминающая алую лису!
ent-PlushieCoffeeFox = плюшевая кофейная лиса
.desc = Милая плюшевая игрушка, напоминающая кофейную лису!
ent-PlushieBlueFox = плюшевая синяя лиса
.desc = Милая плюшевая игрушка, напоминающая синюю лису!
ent-PlushieBlackFox = плюшевая чёрная лиса
.desc = Милая плюшевая игрушка, напоминающая чёрную лису!
ent-PlushieVulp = плюшевая вульпа
.desc = Миленькая плюшевая игрушка вульпакина, которую можно обнять без риска быть укушенным!
ent-PlushieTrystan = плюшевая офисная вульпа
.desc = Плюшевая вульпа развитая достаточно, чтоб делать йеп йеп на бумажках!
ent-PlushieCorgi = плюшевый корги
.desc = Плюшевый Иан!
ent-PlushieGirlyCorgi = плюшевая корги
.desc = Плюшевая Лиза!
ent-PlushieRobotCorgi = плюшевый робот корги
.desc = Бип-тяф!
ent-BasePlushieCat = плюшевый котёнок
.desc = Плюшевая игрушка, напоминающая милого котенка!
ent-PlushieCatBlack = плюшевый чёрный котёнок
.desc = { ent-BasePlushieCat.desc }
ent-PlushieCatGrey = плюшевый серый котёнок
.desc = { ent-BasePlushieCat.desc }
ent-PlushieCatOrange = плюшевый оранжевый котёнок
.desc = { ent-BasePlushieCat.desc }
ent-PlushieCatSiames = плюшевый сиамский котёнок
.desc = { ent-BasePlushieCat.desc }
ent-PlushieCatTabby = плюшевый табби-котёнок
.desc = { ent-BasePlushieCat.desc }
ent-PlushieCatTuxedo = плюшевый котёнок в смокинге
.desc = { ent-BasePlushieCat.desc }
ent-PlushieCatWhite = плюшевый белый котёнок
.desc = { ent-BasePlushieCat.desc }
ent-ThronglerToy = плюшевый нагибатор
.desc = { ent-Throngler.desc }
.suffix = Игрушка
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ent-PrizeCounter = счетчик призов
.desc = Забери свой приз в виде нескольких игрушек и милых плюшек!
20 changes: 0 additions & 20 deletions Resources/Prototypes/Catalog/Cargo/cargo_fun.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,26 +88,6 @@
category: cargoproduct-category-name-fun
group: market

- type: cargoProduct
id: FunPlushies
icon:
sprite: Objects/Fun/toys.rsi
state: plushie_h
product: CrateFunPlushie
cost: 1000
category: cargoproduct-category-name-fun
group: market

- type: cargoProduct
id: FunLizardPlushies
icon:
sprite: Objects/Fun/toys.rsi
state: plushie_lizard
product: CrateFunLizardPlushieBulk
cost: 500
category: cargoproduct-category-name-fun
group: market

- type: cargoProduct
id: FunBoardGames
icon:
Expand Down
30 changes: 1 addition & 29 deletions Resources/Prototypes/Catalog/Fills/Crates/fun.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,35 +40,7 @@
- id: PlushieArachind
- id: PlushiePenguin

- type: entity
id: CrateFunPlushie
parent: CrateGenericSteel
name: plushie crate
description: A buncha soft plushies. Throw them around and then wonder how you're gonna explain this purchase to NT.
components:
- type: EntityTableContainerFill
containers:
entity_storage: !type:NestedSelector
tableId: AllPlushiesTable
rolls: !type:ConstantNumberSelector
value: 10

- type: entity
id: CrateFunLizardPlushieBulk
parent: CrateGenericSteel
name: bulk lizard plushie crate
description: A buncha soft lizard plushies. Throw them around and then wonder how you're gonna explain this purchase to NT.
components:
- type: EntityTableContainerFill
containers:
entity_storage: !type:AllSelector
children:
- id: PlushieLizard
amount: !type:ConstantNumberSelector
value: 3
- id: PlushieSpaceLizard
amount: !type:ConstantNumberSelector
value: 3
# Removed crates with toys because EE toys

- type: entity
id: CrateFunInstrumentsVariety
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@
ClothingHandsGlovesColorPurple: 2
ClothingEyesGlassesCheapSunglasses: 3
# DO NOT ADD MORE, USE UNIFORM DYING
ClothingClothWrap: 4 # EE
contrabandInventory:
ClothingMaskNeckGaiter: 2
ClothingUniformJumpsuitTacticool: 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@
ClothingShoesBootsCowboyBrown: 1
ClothingShoesBootsCowboyBlack: 1
ClothingShoesBootsCowboyWhite: 1
ClothingNeckBellCollar: 2
ClothingOuterUnathiRobe: 1
emaggedInventory:
ClothingShoesBling: 1
ClothingShoesBootsCowboyFancy: 1
Expand Down
33 changes: 33 additions & 0 deletions Resources/Prototypes/Entities/Markers/Spawners/Random/toy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
rarePrototypes:
- FoamBlade
- PlushieGhost
- PlushieAbductorAgent # EE
rareChance: 0.03
prototypes:
- PlushieBee
Expand All @@ -34,6 +35,38 @@
- ToyMouse
- PlushieDiona
- PlushieArachind
- PlushieArachne # EE toys START
- PlushieAbductor
- PlushieGnome
- PlushieLoveable
- PlushieDeer
- PlushieIpc
- PlushieGrey
- PlushieRedFox
- PlushiePurpleFox
- PlushiePinkFox
- PlushieOrangeFox
- PlushieMarbleFox
- PlushieCrimsonFox
- PlushieCoffeeFox
- PlushieBlueFox
- PlushieBlackFox
- PlushieVulp
- PlushieCorgi
- PlushieGirlyCorgi
- PlushieRobotCorgi
- PlushieCatBlack
- PlushieCatGrey
- PlushieCatOrange
- PlushieCatSiames
- PlushieCatTabby
- PlushieCatTuxedo
- PlushieCatWhite
- PlushieRatvar
- PlushieNar
- PlushieTrystan
- PlushieSlips
- PlushieJester # EE toys END
chance: 0.5
offset: 0.2

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,5 @@
- VendingMachineSoda
- VendingMachineStarkist
- VendingMachineSpaceUp
- PrizeCounter # Corvax-Next-Plushie
chance: 1
Loading

0 comments on commit f673c3c

Please sign in to comment.