Skip to content

Commit

Permalink
Рефактор Локализации + Фиксы (#339)
Browse files Browse the repository at this point in the history
* init

* fix

* upd scripts

* trying to rework syntax finder

* upd

* upd

* upd

* transate AI

* upd

* upd

* upd

* fix

* translate

* upd

* ай бля

* fix

* upd

* upd

* fix
  • Loading branch information
Rinary1 authored Aug 30, 2024
1 parent fd0311a commit 74e733e
Show file tree
Hide file tree
Showing 4,447 changed files with 3,697 additions and 939 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
36 changes: 33 additions & 3 deletions Content.Shared/Bed/Sleep/SleepingSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ public override void Initialize()

SubscribeLocalEvent<ForcedSleepingComponent, ComponentInit>(OnInit);
SubscribeLocalEvent<SleepingComponent, UnbuckleAttemptEvent>(OnUnbuckleAttempt);
SubscribeLocalEvent<SleepingComponent, ComponentShutdown>(OnSleepingShutdown);
}

private void OnUnbuckleAttempt(Entity<SleepingComponent> ent, ref UnbuckleAttemptEvent args)
Expand Down Expand Up @@ -92,6 +93,10 @@ private void OnSleepAction(Entity<MobStateComponent> ent, ref SleepActionEvent a
/// </summary>
private void OnSleepStateChanged(Entity<MobStateComponent> ent, ref SleepStateChangedEvent args)
{




if (args.FellAsleep)
{
// Expiring status effects would remove the components needed for sleeping
Expand All @@ -100,6 +105,15 @@ private void OnSleepStateChanged(Entity<MobStateComponent> ent, ref SleepStateCh

EnsureComp<StunnedComponent>(ent);
EnsureComp<KnockedDownComponent>(ent);

if (TryComp<SleepingComponent>(ent, out var sleepingComp))
{
var wakeAction = sleepingComp.WakeAction;

_actionsSystem.AddAction(ent, ref wakeAction, WakeActionId, ent);

_actionsSystem.SetCooldown(wakeAction, _gameTiming.CurTime, _gameTiming.CurTime + TimeSpan.FromSeconds(2f));
}

if (TryComp<SleepEmitSoundComponent>(ent, out var sleepSound))
{
Expand All @@ -120,17 +134,21 @@ private void OnSleepStateChanged(Entity<MobStateComponent> ent, ref SleepStateCh
RemComp<StunnedComponent>(ent);
RemComp<KnockedDownComponent>(ent);
RemComp<SpamEmitSoundComponent>(ent);
if (TryComp<SleepingComponent>(ent, out var sleepingComponent))
{
_actionsSystem.RemoveAction(ent, sleepingComponent.WakeAction);
}
}

private void OnMapInit(Entity<SleepingComponent> ent, ref MapInitEvent args)
{
var ev = new SleepStateChangedEvent(true);
RaiseLocalEvent(ent, ref ev);
_blindableSystem.UpdateIsBlind(ent.Owner);
_actionsSystem.AddAction(ent, ref ent.Comp.WakeAction, WakeActionId, ent);
//_actionsSystem.AddAction(ent, ref ent.Comp.WakeAction, WakeActionId, ent);

// TODO remove hardcoded time.
_actionsSystem.SetCooldown(ent.Comp.WakeAction, _gameTiming.CurTime, _gameTiming.CurTime + TimeSpan.FromSeconds(2f));
//_actionsSystem.SetCooldown(ent.Comp.WakeAction, _gameTiming.CurTime, _gameTiming.CurTime + TimeSpan.FromSeconds(2f));
}

private void OnSpeakAttempt(Entity<SleepingComponent> ent, ref SpeakAttemptEvent args)
Expand Down Expand Up @@ -239,15 +257,27 @@ private void OnInit(Entity<ForcedSleepingComponent> ent, ref ComponentInit args)

private void Wake(Entity<SleepingComponent> ent)
{
if (TryComp<SleepingComponent>(ent, out var sleepingComp))
{
_actionsSystem.RemoveAction(ent, sleepingComp.WakeAction);
}

RemComp<SleepingComponent>(ent);
_actionsSystem.RemoveAction(ent, ent.Comp.WakeAction);

var ev = new SleepStateChangedEvent(false);
RaiseLocalEvent(ent, ref ev);

_blindableSystem.UpdateIsBlind(ent.Owner);
}

private void OnSleepingShutdown(Entity<SleepingComponent> ent, ref ComponentShutdown args)
{
if (TryComp<SleepingComponent>(ent, out var sleepingComp))
{
_actionsSystem.RemoveAction(ent, sleepingComp.WakeAction);
}
}

/// <summary>
/// Try sleeping. Only mobs can sleep.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
ent-ActionToggleBorgMagboots = { "" }
.desc = { "" }
ent-BorgCuffed = { "" }
.desc = { "" }
ent-FabricateLollipop = { "" }
.desc = { "" }
ent-FabricateGumball = { "" }
.desc = { "" }
ent-FabricateCookie = { "" }
.desc = { "" }
ent-FabricateSoap = { "" }
.desc = { "" }
ent-ActionViewCrewManifest = View Crew Manifest
.desc = View the View crew manifest station.
32 changes: 32 additions & 0 deletions Resources/Locale/en-US/_prototypes/_sunrise/actions/disease.ftl
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
ent-ActionInfect = action-disease-infect-name
.desc = action-disease-infect-description
ent-ActionDiseaseShop = action-disease-shop-name
.desc = action-disease-shop-description
ent-ActionDiseaseBaseChance = listing-disease-base-chance-name
.desc = listing-disease-base-chance-description
ent-ActionDiseaseInfectChance = listing-disease-infect-chance-name
.desc = listing-disease-infect-chance-description
ent-ActionDiseaseShield = listing-disease-shield-name
.desc = listing-disease-shield-description
ent-ActionDiseaseLethal = listing-disease-lethal-name
.desc = listing-disease-lethal-description
ent-ActionDiseaseCough = listing-disease-cough-name
.desc = listing-disease-cough-description
ent-ActionDiseaseSneeze = listing-disease-sneeze-name
.desc = listing-disease-sneeze-description
ent-ActionDiseaseVomit = listing-disease-vomit-name
.desc = listing-disease-vomit-description
ent-ActionDiseaseNarcolepsy = listing-disease-narcolepsy-name
.desc = listing-disease-narcolepsy-description
ent-ActionDiseaseCrying = listing-disease-cry-name
.desc = listing-disease-cry-description
ent-ActionDiseaseMuted = listing-disease-muted-name
.desc = listing-disease-muted-description
ent-ActionDiseaseSlowness = listing-disease-slowness-name
.desc = listing-disease-slowness-description
ent-ActionDiseaseBleed = listing-disease-bleed-name
.desc = listing-disease-bleed-description
ent-ActionDiseaseBlindness = listing-disease-blindness-name
.desc = listing-disease-blindness-description
ent-ActionDiseaseInsult = listing-disease-insult-name
.desc = listing-disease-insult-description
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ent-ActionRevenantLock = Lock Airlock
.desc = Costs 60 Essence.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
ent-ZombieJump = { "" }
.desc = { "" }
ent-ZombieFlair = { "" }
.desc = { "" }
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ent-BaseTail = tail
.desc = { ent-BasePart.desc }
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
ent-PartHumanoidXeno = правая рука ксеноморфа
.desc = { ent-BaseItem.desc }
ent-TorsoHumanoidXeno = торс ксеноморфа
.desc = { ent-PartHumanoidXeno.desc }
ent-HeadHumanoidXeno = голова ксеноморфа
.desc = { ent-PartHumanoidXeno.desc }
ent-LeftArmHumanoidXeno = левая рука ксеноморфа
.desc = { ent-PartHumanoidXeno.desc }
ent-RightArmHumanoidXeno = правая рука ксеноморфа
.desc = { ent-PartHumanoidXeno.desc }
ent-LeftHandHumanoidXeno = левая кисть ксеноморфа
.desc = { ent-PartHumanoidXeno.desc }
ent-RightHandHumanoidXeno = правая кисть ксеноморфа
.desc = { ent-PartHumanoidXeno.desc }
ent-LeftLegHumanoidXeno = левая нога ксеноморфа
.desc = { ent-PartHumanoidXeno.desc }
ent-RightLegHumanoidXeno = правая нога ксеноморфа
.desc = { ent-PartHumanoidXeno.desc }
ent-LeftFootHumanoidXeno = левая стопа ксеноморфа
.desc = { ent-PartHumanoidXeno.desc }
ent-RightFootHumanoidXeno = правая стопа ксеноморфа
.desc = { ent-PartHumanoidXeno.desc }
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
ent-PartPredator = голова яутжи
.desc = { ent-BaseItem.desc }
ent-TorsoPredator = торс яутжи
.desc = { ent-PartPredator.desc }
ent-HeadPredator = голова яутжи
.desc = { ent-PartPredator.desc }
ent-LeftArmPredator = левая рука яутжи
.desc = { ent-PartPredator.desc }
ent-RightArmPredator = правая рука яутжи
.desc = { ent-PartPredator.desc }
ent-LeftHandPredator = левая кисть яутжи
.desc = { ent-PartPredator.desc }
ent-RightHandPredator = правая кисть яутжи
.desc = { ent-PartPredator.desc }
ent-LeftLegPredator = левая нога яутжи
.desc = { ent-PartPredator.desc }
ent-RightLegPredator = правая нога нога уятжи
.desc = { ent-PartPredator.desc }
ent-LeftFootPredator = левая стопа яутжи
.desc = { ent-PartPredator.desc }
ent-RightFootPredator = правая стопа яутжи
.desc = { ent-PartPredator.desc }
22 changes: 22 additions & 0 deletions Resources/Locale/en-US/_prototypes/_sunrise/body/parts/swine.ftl
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
ent-PartSwine = swine body part
.desc = { ent-BaseItem.desc }
ent-TorsoSwine = swine torso
.desc = { ent-PartSwine.desc }
ent-HeadSwine = swine head
.desc = { ent-PartSwine.desc }
ent-LeftArmSwine = left swine arm
.desc = { ent-PartSwine.desc }
ent-RightArmSwine = right swine arm
.desc = { ent-PartSwine.desc }
ent-LeftHandSwine = left swine hand
.desc = { ent-PartSwine.desc }
ent-RightHandSwine = right swine hand
.desc = { ent-PartSwine.desc }
ent-LeftLegSwine = left swine leg
.desc = { ent-PartSwine.desc }
ent-RightLegSwine = right swine leg
.desc = { ent-PartSwine.desc }
ent-LeftFootSwine = left swine foot
.desc = { ent-PartSwine.desc }
ent-RightFootSwine = right swine foot
.desc = { ent-PartSwine.desc }
24 changes: 24 additions & 0 deletions Resources/Locale/en-US/_prototypes/_sunrise/body/parts/tajaran.ftl
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
ent-PartTajaran = tajaran body part
.desc = { ent-BaseItem.desc }
ent-TorsoTajaran = тело таяра
.desc = { ent-PartTajaran.desc }
ent-HeadTajaran = голова таяра
.desc = { ent-PartTajaran.desc }
ent-LeftArmTajaran = левая рука таяра
.desc = { ent-PartTajaran.desc }
ent-RightArmTajaran = правая рука таяра
.desc = { ent-PartTajaran.desc }
ent-LeftHandTajaran = левая кисть таяра
.desc = { ent-PartTajaran.desc }
ent-RightHandTajaran = правая кисть таяра
.desc = { ent-PartTajaran.desc }
ent-TailTajaran = хвост таяра
.desc = { ent-PartTajaran.desc }
ent-LeftLegTajaran = левая нога таяра
.desc = { ent-PartTajaran.desc }
ent-RightLegTajaran = правая нога таяра
.desc = { ent-PartTajaran.desc }
ent-LeftFootTajaran = левая ступня таяра
.desc = { ent-PartTajaran.desc }
ent-RightFootTajaran = правая ступня таяра
.desc = { ent-PartTajaran.desc }
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
ent-PartVulpkanin = fox body part
.desc = { ent-BaseItem.desc }
ent-TorsoVulpkanin = fox torso
.desc = { ent-PartVulpkanin.desc }
ent-HeadVulpkanin = fox head
.desc = { ent-PartVulpkanin.desc }
ent-LeftArmVulpkanin = left fox arm
.desc = { ent-PartVulpkanin.desc }
ent-RightArmVulpkanin = right fox arm
.desc = { ent-PartVulpkanin.desc }
ent-LeftHandVulpkanin = left fox hand
.desc = { ent-PartVulpkanin.desc }
ent-RightHandVulpkanin = right fox hand
.desc = { ent-PartVulpkanin.desc }
ent-LeftLegVulpkanin = left fox leg
.desc = { ent-PartVulpkanin.desc }
ent-RightLegVulpkanin = right fox leg
.desc = { ent-PartVulpkanin.desc }
ent-LeftFootVulpkanin = left fox foot
.desc = { ent-PartVulpkanin.desc }
ent-RightFootVulpkanin = right fox foot
.desc = { ent-PartVulpkanin.desc }
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
ent-ClothingBackpackSyndieAJ100Filled = набор AJ-10
.desc = Включает в себя пистолет-пулемёт AJ-100 и два магазина патрон.
ent-ClothingBackpackSyndieDL6902Filled = набор DL-6902
.desc = Включает в себя пулемёт DL6902 и один магазин патрон.
ent-ClothingBackpackSyndieSIAR52Filled = набор SIAR-52
.desc = Включает в себя пулемёт SIAR-52 и два магазина патрон.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ent-ClothingBackpackDuffelBoomboxBundle = syndicate boombox bundle
.desc = Убивайте со стилем
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ent-BookStationsAndAgents = Stations and Syndicates 14th Edition Rulebook
.desc = A book detailing the ruleset for the tabletop RPG, Stations and Syndicates. You don't know what happened to the previous 13 editions but maybe its probably not worth looking for them.
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
ent-BoxMagazineCaselessRifleRubber = box of .25 caseless (rubber) magazines
.desc = A box full of
ent-BoxMagazineLightRifleRubber = box of .30 rifle (rubber) magazines
.desc = A box full of .30 rifle (practice) magazines.
ent-BoxMagazineMagnumSubMachineGunRubber = box of Vector (rubber) magazines
.desc = A box full of Vector (rubber) magazines.
ent-BoxMagazinePistolRubber = box of pistol .35 auto (rubber) magazines
.desc = A box full of pistol .35 auto (rubber) magazines.
ent-BoxMagazinePistolHighCapacityRubber = box of machine pistol .35 auto (rubber) magazines
.desc = A box full of machine pistol .35 auto (rubber) magazines.
ent-BoxMagazinePistolSubMachineGunRubber = box of SMG .35 auto (rubber) magazines
.desc = A box full of SMG .35 auto (rubber) magazines.
ent-BoxMagazineRifleRubber = box of .20 rifle (rubber) magazines
.desc = A box full of .20 rifle (rubber) magazines.
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
ent-BoxRepairSynth = survival box
.desc = It's a box with basic internals inside.
ent-BoxHugSynth = survival box
.desc = It's a box with basic internals inside.
ent-BoxRepairSecurity = survival box
.desc = It's a box with basic internals inside.
ent-BoxRepairSyndicate = survival box
.desc = It's a box with basic internals inside.
ent-BoxSurvivalWithoutGas = { ent-BoxSurvival }
.suffix = Standard withoutGas
.desc = { ent-BoxSurvival.desc }
ent-BoxHugWithoutGas = box of hugs
.desc = A special box for sensitive people.
.suffix = Emergency
ent-BoxSurvivalSecurityWithoutGas = survival box
.desc = It's a box with basic internals inside.
.suffix = Security
ent-BoxSurvivalSyndicateWithoutGas = extended-capacity survival box
.desc = It's a box with basic internals inside. This one is labelled to contain an extended-capacity tank.
.suffix = Syndicate
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ent-CrateFunSprayPaints = spray paint crate
.desc = a crate filled with spray paint.
.suffix = Spray Paint
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ent-BriefcaseIAAFilled = { ent-BriefcaseBrown }
.suffix = IAA
.desc = { ent-BriefcaseBrown.desc }
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
ent-ClothingShoesBootsJackSecFilled = { ent-ClothingShoesBootsJackSec }
.suffix = Filled
.desc = { ent-ClothingShoesBootsJackSec.desc }
ent-ClothingBeltBlueShieldWebbingFilled = { ent-ClothingBeltBlueShieldWebbing }
.suffix = Filled
.desc = { ent-ClothingBeltBlueShieldWebbing.desc }
ent-ClothingShoesBootsBlueShieldFilled = { ent-ClothingShoesBootsBlueShield }
.suffix = Filled
.desc = { ent-ClothingShoesBootsBlueShield.desc }
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ent-ToolboxSyndicateFilledCoreExtraction = { ent-ToolboxSyndicate }
.suffix = Filled, Core Extraction
.desc = { ent-ToolboxSyndicate.desc }
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ent-LockerHeadOfPrisonFilled = шкафчик начальника тюрьмы
.suffix = Filled
.desc = { ent-LockerHeadOfSecurity.desc }
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
ent-LockerBlueshieldFilled = { ent-LockerBlueshield }
.suffix = Filled
.desc = { ent-LockerBlueshield.desc }
ent-LockerBlueshieldFilledHardsuit = { ent-LockerBlueshield }
.suffix = Filled, Hardsuit
.desc = { ent-LockerBlueshield.desc }
ent-GunSafeBlueShield = blue shield safe
.desc = { ent-GunSafe.desc }
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ent-LockerPilotFilledHardsuit = { ent-LockerPilot }
.suffix = Filled, Hardsuit
.desc = { ent-LockerPilot.desc }
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
ent-GunSafeEnergyGunMini = сейф миниатюрных энергетических пушек
.suffix = SUNRISE
.desc = { ent-GunSafe.desc }
ent-GunSafePistolG22 = Сейф Глок-22
.suffix = SUNRISE
.desc = { ent-GunSafe.desc }
ent-GunSafeRifleM16A4 = Сейф M16A4
.suffix = SUNRISE
.desc = { ent-GunSafe.desc }
ent-GunSafeSubMachineGunVector = Сейф векторов
.suffix = SUNRISE
.desc = { ent-GunSafe.desc }
ent-GunSafeShotgunPaladin = Сейф Паладинов 12
.suffix = SUNRISE
.desc = { ent-GunSafe.desc }
ent-GunSafeShotgunTrenchgun4034 = Сейф Тренчганов 4034
.suffix = SUNRISE
.desc = { ent-GunSafe.desc }
ent-GunSafeSubMachineGunMP38 = Сейф MP-38
.suffix = SUNRISE
.desc = { ent-GunSafe.desc }
ent-GunSafeEnergyGun = сейф энергетических пушек
.suffix = SUNRISE
.desc = { ent-GunSafe.desc }
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ent-SuitStorageBlueShield = { ent-SuitStorageBase }
.suffix = BlueShield
.desc = { ent-SuitStorageBase.desc }
Loading

0 comments on commit 74e733e

Please sign in to comment.