From f9ff91d74b94a50a4f63e7bc63990e7bcdcc9baf Mon Sep 17 00:00:00 2001 From: Ed <96445749+TheShuEd@users.noreply.github.com> Date: Tue, 4 Mar 2025 13:56:12 +0300 Subject: [PATCH 01/25] Update default.yml --- Resources/Prototypes/_CP14/Maps/Pools/default.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Resources/Prototypes/_CP14/Maps/Pools/default.yml b/Resources/Prototypes/_CP14/Maps/Pools/default.yml index 68c3cbd8a0..1b11f7ef80 100644 --- a/Resources/Prototypes/_CP14/Maps/Pools/default.yml +++ b/Resources/Prototypes/_CP14/Maps/Pools/default.yml @@ -2,9 +2,9 @@ id: DefaultMapPool maps: - Comoss - - Factoria + #- Factoria - type: gameMapPool id: DeathMatchMapPool maps: - - MeteorArena \ No newline at end of file + - MeteorArena From d9a5869504cf60e77ef5b0a3319897e768d9ca52 Mon Sep 17 00:00:00 2001 From: creamybag Date: Wed, 5 Mar 2025 17:28:41 +0300 Subject: [PATCH 02/25] Merge pull request #973 from creamybag/GuildmasterHat Guildmaster hat --- .../Locale/en-US/_CP14/loadouts/loadout.ftl | 1 + .../ru-RU/_CP14/_PROTO/entities/entities.ftl | 3 +++ .../Locale/ru-RU/_CP14/loadouts/loadout.ftl | 1 + .../Clothing/Head/Roles/guildmaster.yml | 10 ++++++++++ .../_CP14/Loadouts/Jobs/guildmaster.yml | 10 ++++++++++ .../_CP14/Loadouts/role_loadouts.yml | 1 + .../guildmaster_hat.rsi/equipped-HELMET.png | Bin 0 -> 1090 bytes .../Guildmaster/guildmaster_hat.rsi/icon.png | Bin 0 -> 477 bytes .../Guildmaster/guildmaster_hat.rsi/meta.json | 18 ++++++++++++++++++ 9 files changed, 44 insertions(+) create mode 100644 Resources/Prototypes/_CP14/Entities/Clothing/Head/Roles/guildmaster.yml create mode 100644 Resources/Textures/_CP14/Clothing/Head/Roles/Guildmaster/guildmaster_hat.rsi/equipped-HELMET.png create mode 100644 Resources/Textures/_CP14/Clothing/Head/Roles/Guildmaster/guildmaster_hat.rsi/icon.png create mode 100644 Resources/Textures/_CP14/Clothing/Head/Roles/Guildmaster/guildmaster_hat.rsi/meta.json diff --git a/Resources/Locale/en-US/_CP14/loadouts/loadout.ftl b/Resources/Locale/en-US/_CP14/loadouts/loadout.ftl index a91bd27996..5fb56fe888 100644 --- a/Resources/Locale/en-US/_CP14/loadouts/loadout.ftl +++ b/Resources/Locale/en-US/_CP14/loadouts/loadout.ftl @@ -54,6 +54,7 @@ cp14-loadout-merchant-shoes = Merchant's shoes # Guildmaster cp14-loadout-guildmaster-outer = Guildmaster outer clothes +cp14-loadout-guildmaster-head = Guildmaster hat cp14-loadout-guildmaster-cloak = Guildmaster cloak cp14-loadout-guildmaster-shirt = Guildmaster shirt cp14-loadout-guildmaster-pants = Guildmaster pants diff --git a/Resources/Locale/ru-RU/_CP14/_PROTO/entities/entities.ftl b/Resources/Locale/ru-RU/_CP14/_PROTO/entities/entities.ftl index 95bc03f9db..cdb9f40b46 100644 --- a/Resources/Locale/ru-RU/_CP14/_PROTO/entities/entities.ftl +++ b/Resources/Locale/ru-RU/_CP14/_PROTO/entities/entities.ftl @@ -601,6 +601,9 @@ ent-CP14ClothingHeadAlchemistBeret = берет алхимика ent-CP14ClothingHeadCaptainCap = капитанская кепка .desc = Нет, ну вы посмотрите какой красавчик! +ent-CP14ClothingHeadGildmaster = шляпа гильдмастера + .desc = Знак безграничного опыта и чести. + ent-CP14ClothingHeadBeretBase = { ent-CP14ClothingHeadBase } .desc = Это берет. diff --git a/Resources/Locale/ru-RU/_CP14/loadouts/loadout.ftl b/Resources/Locale/ru-RU/_CP14/loadouts/loadout.ftl index 7d32157e9c..54f5041b1a 100644 --- a/Resources/Locale/ru-RU/_CP14/loadouts/loadout.ftl +++ b/Resources/Locale/ru-RU/_CP14/loadouts/loadout.ftl @@ -54,6 +54,7 @@ cp14-loadout-merchant-shoes = Ботинки торговца # Guildmaster cp14-loadout-guildmaster-outer = Верхняя одежда гильдмастера +cp14-loadout-guildmaster-head = Шляпа гильдмастера cp14-loadout-guildmaster-cloak = Накидка гильдмастера cp14-loadout-guildmaster-shirt = Рубашка гильдмастера cp14-loadout-guildmaster-pants = Штаны гильдмастера diff --git a/Resources/Prototypes/_CP14/Entities/Clothing/Head/Roles/guildmaster.yml b/Resources/Prototypes/_CP14/Entities/Clothing/Head/Roles/guildmaster.yml new file mode 100644 index 0000000000..03d52e0e88 --- /dev/null +++ b/Resources/Prototypes/_CP14/Entities/Clothing/Head/Roles/guildmaster.yml @@ -0,0 +1,10 @@ +- type: entity + parent: CP14ClothingHeadBase + id: CP14ClothingHeadGildmaster + name: guildmaster hat + description: A sign of unlimited experience and honor. + components: + - type: Sprite + sprite: _CP14/Clothing/Head/Roles/Guildmaster/guildmaster_hat.rsi + - type: Clothing + sprite: _CP14/Clothing/Head/Roles/Guildmaster/guildmaster_hat.rsi \ No newline at end of file diff --git a/Resources/Prototypes/_CP14/Loadouts/Jobs/guildmaster.yml b/Resources/Prototypes/_CP14/Loadouts/Jobs/guildmaster.yml index a31095c1e9..bd9cc3f1a7 100644 --- a/Resources/Prototypes/_CP14/Loadouts/Jobs/guildmaster.yml +++ b/Resources/Prototypes/_CP14/Loadouts/Jobs/guildmaster.yml @@ -1,6 +1,16 @@ # Head +- type: loadoutGroup + id: CP14GuildmasterHead + name: cp14-loadout-guildmaster-head + loadouts: + - CP14ClothingHeadGildmaster +- type: loadout + id: CP14ClothingHeadGildmaster + equipment: + cloak: CP14ClothingHeadGildmaster + # Cloak - type: loadoutGroup diff --git a/Resources/Prototypes/_CP14/Loadouts/role_loadouts.yml b/Resources/Prototypes/_CP14/Loadouts/role_loadouts.yml index 002e9cd80d..fa5076515f 100644 --- a/Resources/Prototypes/_CP14/Loadouts/role_loadouts.yml +++ b/Resources/Prototypes/_CP14/Loadouts/role_loadouts.yml @@ -127,6 +127,7 @@ - CP14GeneralSpells - CP14GuildmasterOuterClothing - CP14GeneralEyes + - CP14GuildmasterHead - CP14GuildmasterCloak - CP14GuildmasterShirt - CP14GuildmasterPants diff --git a/Resources/Textures/_CP14/Clothing/Head/Roles/Guildmaster/guildmaster_hat.rsi/equipped-HELMET.png b/Resources/Textures/_CP14/Clothing/Head/Roles/Guildmaster/guildmaster_hat.rsi/equipped-HELMET.png new file mode 100644 index 0000000000000000000000000000000000000000..8a5dabfd80e8e904cbdd286f121ab86f1908904a GIT binary patch literal 1090 zcmV-I1ikx-P)Px&{7FPXRCt{2+`&tmX8_0XZ_2g~H+-cIG8@_~MbOkDY%eHj=%|AXdhrh!V;}>2 z96L>R-Jyfs2MT4UfQJdPONRyB#Rdy0RJ5TWYIM=Pj11q6h;)=^hxlgE+Ie^%&FlL6 zTw-2d-~68Eecsm)!Vg45MC5EL&Q6(1sbE^2<1|%D1yh`zvNGm#VS@ln=JVJJ6m`Yf zDKnYR1OJXcj9AzMR7wT&+x8aawK9X(GbGZP(8r9bN~vHL9u!EXlDyk>(aKm~3wwY> zIuomu3Z}eP2EcV)QlDNuurhql=a2i97(lUD4EvHN>bU%XwaJH&x1c~Gorxt=Nhb4o zCcgXHY%H!G_`MT%xR6U2s1LCDF)Ccw#dTfw+WnX2pUme;rjjJmnV7Bop|1dd+}Lnq z#eDY7R{(76Kfm06rLo`Whv&?X=ex+|5(idPs|ERYrXN6i2eozY$oy~D78sk^AU8H_ zY~>Gq0tQC1#)&)Jc|6VQkE*n7?~uI~C*AQ3fYIJL046rNC~fZIWE}wf{;HuE{(n$d zL4JT8XyoUw9nzQDPCS3;6Hr_C@Z+60afiQioiGmbOCIw}ki8aXVx|j#(&jF|WNan^7srWr0`+_5VZP_@KUS%&do0hb zw0!jkTAAP4B=ik+8-V74Gz)?Qk(&HKtMXf)h+rT`dGk*v7WKEGr=9=QR$}wpwy2+k zqn!2pA|fIpA|fIp(t45mSl9-Aa3&%mA|fIpA|fIpA|fIpA|hhPtI``}vnvQJm36!- zy+O9Sg23W8(qW_kbT!v!6=&hxbOzGGsU9snNxFdup>p${-H zk~Kl8QF;6x0NqyxxY_eN0HYsoH};*F>EiCr8-ShgHU*35^NwdPWQKZOO;BT#ynPFR zjm6c_NHv7vy`@m+lt~()WCPuNs-Fpx&C**|=36?u=^|jL}wSkd-T7 zd2S`vH-xFJdt4m63LIa0^n7tI5|a<`d~q-4_g5S5>zjMx0zvkzg(rZ$&Y)B63kpQB zHz;UKJZ`@zmQ9I>h=_=Yh=_=Yh=_=Yh=_=Yh=_=Yh)8Sw1G|X?DKE4GDgXcg07*qo IM6N<$g2F2j%>V!Z literal 0 HcmV?d00001 diff --git a/Resources/Textures/_CP14/Clothing/Head/Roles/Guildmaster/guildmaster_hat.rsi/icon.png b/Resources/Textures/_CP14/Clothing/Head/Roles/Guildmaster/guildmaster_hat.rsi/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..6076521759408a37c077cb6cda115cb8d216bc57 GIT binary patch literal 477 zcmV<30V4j1P)Px$mq|oHRA_Jzk*R4XWvZA9~MIo%@S9wfzGF&1${A~rG$Dg1w$VVT|e&u`}egb+dq zA%qa(z4A|vbStRnQPm$a`8b|SgD2#YGZdm}n@0*q!Vzh-~P9|r~&d*XVl_>7-=*H#E zP`|PjpFBrHFW_Kn%6J6;ydN9=Kfbm59e~F3^UTWU{(FUQWBPD1jpsT26)|NT;On-l zm95yj_{qe1n~!&oxXU(~>3;we7Eb{vHqr#mF3ME^L@RBLZ+-@i19WO3k)1->ivL~; z4&baBa#jU**{1j_4M5QB^4nbndS{|j3r$M{3EV;eOZf#oHD{yj6wurAFGXSW+_ve| zLat7)6RDlpmA8~%&;Wx$2E`Kx5}Q0E7$6o0dCiBv%1Zhg6+#Fhgb+dqA>OMeKfi Date: Wed, 5 Mar 2025 16:30:06 +0200 Subject: [PATCH 03/25] Sheep (#972) * sheep * demi mod --- .../en-US/_CP14/demiplane/modifiers.ftl | 1 + .../ru-RU/_CP14/demiplane/modifiers.ftl | 1 + .../_CP14/Entities/Markers/Spawners/mobs.yml | 16 ++++ .../_CP14/Entities/Mobs/NPC/animals.yml | 89 +++++++++++++++++- .../Demiplane/Modifiers/Reward/misc.yml | 18 ++++ Resources/Prototypes/_CP14/tags.yml | 3 + .../_CP14/Mobs/Animals/sheep.rsi/dead.png | Bin 0 -> 1040 bytes .../_CP14/Mobs/Animals/sheep.rsi/meta.json | 18 ++++ .../_CP14/Mobs/Animals/sheep.rsi/sheep.png | Bin 0 -> 2071 bytes 9 files changed, 145 insertions(+), 1 deletion(-) create mode 100644 Resources/Textures/_CP14/Mobs/Animals/sheep.rsi/dead.png create mode 100644 Resources/Textures/_CP14/Mobs/Animals/sheep.rsi/meta.json create mode 100644 Resources/Textures/_CP14/Mobs/Animals/sheep.rsi/sheep.png diff --git a/Resources/Locale/en-US/_CP14/demiplane/modifiers.ftl b/Resources/Locale/en-US/_CP14/demiplane/modifiers.ftl index 1fe01cd27c..aecd02ba47 100644 --- a/Resources/Locale/en-US/_CP14/demiplane/modifiers.ftl +++ b/Resources/Locale/en-US/_CP14/demiplane/modifiers.ftl @@ -18,6 +18,7 @@ cp14-modifier-mole = predatory moles cp14-modifier-rabbits = rabbits cp14-modifier-boars = wild boars cp14-modifier-invisible-whistler = invisible whistlers +cp14-modifier-sheeps = sheeps cp14-modifier-chasm = bottomless chasms cp14-modifier-air-lily = air lilies cp14-modifier-time-limit-10 = temporary disintegration (10 minutes) diff --git a/Resources/Locale/ru-RU/_CP14/demiplane/modifiers.ftl b/Resources/Locale/ru-RU/_CP14/demiplane/modifiers.ftl index 9528bdefa0..92d94a608e 100644 --- a/Resources/Locale/ru-RU/_CP14/demiplane/modifiers.ftl +++ b/Resources/Locale/ru-RU/_CP14/demiplane/modifiers.ftl @@ -17,6 +17,7 @@ cp14-modifier-dyno = доисторической фауны cp14-modifier-mole = хищных кротов cp14-modifier-rabbits = кроликов cp14-modifier-boars = диких кабанов +cp14-modifier-sheeps = овец cp14-modifier-invisible-whistler = невидимых свистунов cp14-modifier-chasm = бездонных пропастей cp14-modifier-air-lily = воздушных лилий diff --git a/Resources/Prototypes/_CP14/Entities/Markers/Spawners/mobs.yml b/Resources/Prototypes/_CP14/Entities/Markers/Spawners/mobs.yml index 334932cc9c..60a5f2584a 100644 --- a/Resources/Prototypes/_CP14/Entities/Markers/Spawners/mobs.yml +++ b/Resources/Prototypes/_CP14/Entities/Markers/Spawners/mobs.yml @@ -89,6 +89,22 @@ prototypes: - CP14MobFrog +- type: entity + name: sheep spawner + id: CP14SpawnMobSheep + parent: MarkerBase + categories: [ ForkFiltered ] + components: + - type: Sprite + layers: + - sprite: Markers/cross.rsi + state: green + - sprite: _CP14/Mobs/Animals/sheep.rsi + state: sheep + - type: ConditionalSpawner + prototypes: + - CP14MobSheep + # Dino - type: entity diff --git a/Resources/Prototypes/_CP14/Entities/Mobs/NPC/animals.yml b/Resources/Prototypes/_CP14/Entities/Mobs/NPC/animals.yml index 8108ae1d2b..365288c597 100644 --- a/Resources/Prototypes/_CP14/Entities/Mobs/NPC/animals.yml +++ b/Resources/Prototypes/_CP14/Entities/Mobs/NPC/animals.yml @@ -105,7 +105,7 @@ shape: !type:PhysShapeCircle radius: 0.35 - density: 100 + density: 150 mask: - MobMask layer: @@ -330,3 +330,90 @@ volume: -8 variation: 0.125 - type: SoundWhileAlive + +- type: entity + id: CP14MobSheep + parent: CP14SimpleMobBase + name: sheep + description: White and fluffy as a cloud sheep. + categories: [ ForkFiltered ] + components: + - type: HTN + rootTask: + task: RuminantCompound + - type: NpcFactionMember + factions: + - CP14PeacefulAnimals + - type: Sprite + drawdepth: Mobs + layers: + - map: ["enum.DamageStateVisualLayers.Base"] + sprite: _CP14/Mobs/Animals/sheep.rsi + state: sheep + - type: Fixtures + fixtures: + fix1: + shape: + !type:PhysShapeCircle + radius: 0.35 + density: 100 + mask: + - MobMask + layer: + - MobLayer + - type: Tag + tags: + - CP14Sheep + - type: Reproductive + partnerWhitelist: + tags: + - CP14Sheep + offspring: + - id: CP14MobSheep + maxAmount: 1 + - type: ReproductivePartner + - type: Speech + speechSounds: Goat + speechVerb: Goat + - type: Vocal + sounds: + Female: Goat + Male: Goat + Unsexed: Goat + - type: Appearance + - type: MobThresholds + thresholds: + 0: Alive + 50: Dead + - type: CombatMode + - type: MeleeWeapon + angle: 0 + animation: WeaponArcPunch + damage: + types: + Blunt: 5 + - type: MovementSpeedModifier + baseWalkSpeed : 4 + baseSprintSpeed : 4 + - type: DamageStateVisuals + states: + Alive: + Base: sheep + Dead: + Base: dead + - type: Butcherable + spawned: + - id: CP14FoodMeatLamb + amount: 4 + - id: CP14String # As long as there are no mechanics to shearing wool, the only way to get string. + amount: 4 + - type: Bloodstream + bloodMaxVolume: 200 + bloodReagent: CP14Blood + - type: InteractionPopup + successChance: 0.5 + interactSuccessString: petting-success-goat + interactFailureString: petting-failure-goat + interactSuccessSpawn: EffectHearts + interactSuccessSound: + path: /Audio/Animals/goat_bah.ogg diff --git a/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/Reward/misc.yml b/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/Reward/misc.yml index 1b5559dde0..04ce8a8d4c 100644 --- a/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/Reward/misc.yml +++ b/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/Reward/misc.yml @@ -71,6 +71,24 @@ minGroupSize: 2 maxGroupSize: 3 +- type: cp14DemiplaneModifier + id: Sheep + tiers: + - 1 + - 2 + name: cp14-modifier-sheeps + generationWeight: 0.4 + categories: + Reward: 0.2 + requiredTags: + - CP14DemiplanePeacefulAnimals + layers: + - !type:OreDunGen + entity: CP14MobSheep + count: 1 + minGroupSize: 4 + maxGroupSize: 5 + # TIER 2 - type: cp14DemiplaneModifier diff --git a/Resources/Prototypes/_CP14/tags.yml b/Resources/Prototypes/_CP14/tags.yml index 0d41504c86..6bd6ea8851 100644 --- a/Resources/Prototypes/_CP14/tags.yml +++ b/Resources/Prototypes/_CP14/tags.yml @@ -132,3 +132,6 @@ - type: Tag id: CP14Dayflin + +- type: Tag + id: CP14Sheep diff --git a/Resources/Textures/_CP14/Mobs/Animals/sheep.rsi/dead.png b/Resources/Textures/_CP14/Mobs/Animals/sheep.rsi/dead.png new file mode 100644 index 0000000000000000000000000000000000000000..e39f74638b06ac409244bcffa3d018db55954ee5 GIT binary patch literal 1040 zcmV+r1n>KaP)Px&%1J~)R9J=Wm0wJoRT##9m4V0_7HQHnYq8%p$_g?w8%H%|Q6dXVgluyq*~UI+ z%*>1qZ%CtAm={3emC-~mT;jikWl_5*lkH-E6q3P`LQ-R3(1~tM`28ocDR&=e*~9P(T3%6i~qb9fp6qVP$1SS?k);($a_KUz30j3V{6s$P%(K0gd)G|s=eXs6mfH3-vC;8<3F2WwY8xE z5eLUcdAYR(NEPLjo)98(3YeUl7O`tbJ%Aw3hKWkd;78AMscMRf0I;~-ls>hc=Y5^JV^GO! zYaASE^BMpi0r>pA4h10eYidDLqX%cT1822^rbZ6{LxGT(Kl$oj0AlC9XSlbA`06SE ziDZ&QGRfl145o5phBLJ_4i3N4E{;SvaB!zfv02T`%}0d*6)LGZXS14x6P?~804yxU z0J!nh7Zk0m@Mwhz+-|mSs}p(D{z<SH8X%+Pg` zU~_Yd1W>(DiB)pDEVJO;Dy+YMGos6x^=FiREnD9{0l@Obi&WYr?6NGnU)y-OFx=Y0 z?S%yr_wE7Ewfv|48m6PG`+a3%{5k-x2lv@%F;i)m0Qh6}p9<7(c3IZ#zw}~bM$ULR z%vEnY0R8^cxdrTPJFL`gdlG<&@$2;aPa8fv`nv9xoL_t(;+74Mu{`)wwmOK1!@BWR zZ#(I^vkFjStuy#7`H)ZCf5l%Uubiq|4#Ir^0000< KMNUMnLSTZnH1^s6 literal 0 HcmV?d00001 diff --git a/Resources/Textures/_CP14/Mobs/Animals/sheep.rsi/meta.json b/Resources/Textures/_CP14/Mobs/Animals/sheep.rsi/meta.json new file mode 100644 index 0000000000..8d680fb824 --- /dev/null +++ b/Resources/Textures/_CP14/Mobs/Animals/sheep.rsi/meta.json @@ -0,0 +1,18 @@ +{ + "version": 1, + "license": "All right reserved", + "copyright": "Created by Jaraten (discord/Github)", + "size": { + "x": 32, + "y": 32 + }, + "states": [ + { + "name": "sheep", + "directions": 4 + }, + { + "name": "dead" + } + ] +} diff --git a/Resources/Textures/_CP14/Mobs/Animals/sheep.rsi/sheep.png b/Resources/Textures/_CP14/Mobs/Animals/sheep.rsi/sheep.png new file mode 100644 index 0000000000000000000000000000000000000000..58f2cf719f7dfbae105f483305781579c084a0b7 GIT binary patch literal 2071 zcmV+y2Px+(Md!>RCt{2TTMt@R}}s%U1XibV_=3b&`g-$MF&(+0t!m9h%ls8lE#GCmL{7N zvM{v8B-Dlo&7zQQTr^3EKP`@xfpJlYU?3QXf?cRHgJVI$2r>)T?p_z>T+hAlzQ6fN zOPLP>FZ1rb-#O==d+vSr9NSPM4i67adOmUDL|d)nc*T=@x6GyG6@-EYqGuwO_oeMJ zDtlG*^>*Wn@t-}*Qjmld4zbHLi{H^Yhlht| zy^7Tn2i^z2?aO+CkLrrGEQ9yOZyN;b31p2}0(SiLyOVr=_ivB9X z0Yg%Z2S_r63O9c3+MwVQ4j35e??PX1xA@qgvvw$WEQtDh^h^Xx%PZnkw!2^T6$d!K z6UZaT5ULmOc6R)>OMsKpSJ+PF007X}+by*vg?B0k2n7u+Ew4BV?ghkex9sTmaKJ#= zL2)-Dx}F64db`E!zABaw3K}SFm!&qP?J`0^1FwoD;RW1CjXD<)_{=Zl7cEBO0djZ0 z>Ufs0T>|t>Usv4iqh}(L5%~Z4a-byu_&X19e)Swc3UPPm-oV>)#qB=VwI1-`$DhQ& z_os5=QC#Uk_Tm9LK*OKzP`&BWXS8#q(EF3VfkYBXSraHqsP|_|^D9Rqo zp^X8X8(U&9GQ#@Ws!;ND=%m!1{?CoT6`=9FLgnYPzK~x;p;$(tXf-O21>75)_-);i zwhq5N)jp1Wc#CqX-Ya(yxc0K{Vv%MRd`-!=$F!>8J&pU(im zJB!P1)YBQo>Cj2^bVjwLBz&!3gKqp62QFaj&TWj{xh<5hh2Qlg$gKwP%PuYy>IKj5^FZUCl3IQ_i+-4lM;weCUa{2jUOt;P`+B=EIhEJ;>*kf2s z&^w+UTVGq1ZjNa(gb)<``2D_aP=e}ScduteW|-1uH?Iyz0!~ilMH-D)b@NK_mv2hi ze!y`Gju%VQGUd4goy=S>9t@>f;5z^xWFfx@ULCF)N39|OAf?g?R5+nlbgR|iytaU+ z-KnpgCve%EQs{gq5D&UK8r6k3cwkw1`ba3ZQ#lYWtg9p7F8=8EKidFc^wN2gFA-hs z0llY8bYE{bx<4Nklc3fJsY_S|ZOxWsgPMlYK@CC+`9=Ko$1l=)-0n{IW zWenc`<4?YH%m~{-4Tjk?X9J<-c;KX zDtlFY)ISJ7pDi#=??TT%+mX6HH2sFcPf68+CY}y21>8mR5 zHYr?gsxzSe{5&EZg}L%PA5R0SMT+Xy!uzS<3c10qEsY%x7*e#is}UmE)!FBeW+O9r zluk;f62kr6pptQ6@{b=1h5Y;>le#SqeEpqxr*6Ss>zSvY&uCL^7JzRARt?f|I;aHxX`} zx^~o7{T|U~hp8dY&#OebiVXEbBQrQ`CQ}K-V-e)C)3$=@Ff^1wp;*S;Tuw3`$)pxZ z*vSVRd7s_qwPXObAc2&j*`PI)OeMs7+CJ^R_TsTf&7Z^ZSj3X+=gN@5$Hpg2UPq8j zC9t`%B^l1HXhJf8ojcJil9IXX@w?59Eo^RV38Sd}sEuE2ZfqeQiy)awfb)?ud`zwo zpJ}xpVAWA Date: Thu, 6 Mar 2025 18:22:01 +1000 Subject: [PATCH 04/25] refactor: Orthographic and obsolete in Knowledge --- .../_CP14/Knowledge/CP14KnowledgeSystem.cs | 16 ++++++++-------- .../Components/CP14AutoAddKnowledgeComponent.cs | 5 +++-- .../CP14KnowledgeLearningSourceComponent.cs | 2 +- .../CP14KnowledgePaperTextComponent.cs | 8 +++----- .../Components/CP14KnowledgeStorageComponent.cs | 4 ++-- .../Prototypes/CP14KnowledgePrototype.cs | 9 ++++----- .../_CP14/Knowledge/SharedCP14KnowledgeSystem.cs | 8 ++++---- 7 files changed, 25 insertions(+), 27 deletions(-) diff --git a/Content.Server/_CP14/Knowledge/CP14KnowledgeSystem.cs b/Content.Server/_CP14/Knowledge/CP14KnowledgeSystem.cs index 4e867f5310..e632be9614 100644 --- a/Content.Server/_CP14/Knowledge/CP14KnowledgeSystem.cs +++ b/Content.Server/_CP14/Knowledge/CP14KnowledgeSystem.cs @@ -55,7 +55,7 @@ public sealed partial class CP14KnowledgeSystem : SharedCP14KnowledgeSystem private void AddKnowledgeLearningVerb(Entity ent, ref GetVerbsEvent args) { var user = args.User; - foreach (var knowledge in ent.Comp.Knowledges) + foreach (var knowledge in ent.Comp.Knowledge) { if (!_proto.TryIndex(knowledge, out var indexedKnowledge)) continue; @@ -91,7 +91,7 @@ public sealed partial class CP14KnowledgeSystem : SharedCP14KnowledgeSystem return; //Remove knowledge - foreach (var knowledge in ent.Comp.Knowledges) + foreach (var knowledge in ent.Comp.Knowledge) { if (!_proto.TryIndex(knowledge, out var indexedKnowledge)) continue; @@ -112,7 +112,7 @@ public sealed partial class CP14KnowledgeSystem : SharedCP14KnowledgeSystem //Add knowledge foreach (var knowledge in _proto.EnumeratePrototypes()) { - if (ent.Comp.Knowledges.Contains(knowledge)) + if (ent.Comp.Knowledge.Contains(knowledge)) continue; args.Verbs.Add(new Verb() @@ -147,7 +147,7 @@ public sealed partial class CP14KnowledgeSystem : SharedCP14KnowledgeSystem if (!_proto.TryIndex(proto, out var indexedKnowledge)) return false; - if (knowledgeStorage.Knowledges.Contains(proto)) + if (knowledgeStorage.Knowledge.Contains(proto)) return false; foreach (var dependency in indexedKnowledge.Dependencies) @@ -214,7 +214,7 @@ public sealed partial class CP14KnowledgeSystem : SharedCP14KnowledgeSystem LogType.Mind, LogImpact.Medium, $"{EntityManager.ToPrettyString(uid):player} learned new knowledge: {Loc.GetString(indexedKnowledge.Name)}"); - return knowledgeStorage.Knowledges.Add(proto); + return knowledgeStorage.Knowledge.Add(proto); } public bool TryForgotKnowledge(EntityUid uid, ProtoId proto, bool silent = false) @@ -222,13 +222,13 @@ public sealed partial class CP14KnowledgeSystem : SharedCP14KnowledgeSystem if (!TryComp(uid, out var knowledgeStorage)) return false; - if (!knowledgeStorage.Knowledges.Contains(proto)) + if (!knowledgeStorage.Knowledge.Contains(proto)) return false; if (!_proto.TryIndex(proto, out var indexedKnowledge)) return false; - knowledgeStorage.Knowledges.Remove(proto); + knowledgeStorage.Knowledge.Remove(proto); if (_mind.TryGetMind(uid, out var mind, out var mindComp) && mindComp.Session is not null) { @@ -264,6 +264,6 @@ public sealed partial class CP14KnowledgeSystem : SharedCP14KnowledgeSystem if (!TryComp(entity, out var knowledgeComp)) return; - RaiseNetworkEvent(new CP14KnowledgeInfoEvent(GetNetEntity(entity),knowledgeComp.Knowledges), args.SenderSession); + RaiseNetworkEvent(new CP14KnowledgeInfoEvent(GetNetEntity(entity),knowledgeComp.Knowledge), args.SenderSession); } } diff --git a/Content.Shared/_CP14/Knowledge/Components/CP14AutoAddKnowledgeComponent.cs b/Content.Shared/_CP14/Knowledge/Components/CP14AutoAddKnowledgeComponent.cs index 3fcb3e7976..39aa528229 100644 --- a/Content.Shared/_CP14/Knowledge/Components/CP14AutoAddKnowledgeComponent.cs +++ b/Content.Shared/_CP14/Knowledge/Components/CP14AutoAddKnowledgeComponent.cs @@ -4,11 +4,12 @@ using Robust.Shared.Prototypes; namespace Content.Shared._CP14.Knowledge.Components; /// -/// The ability to add a skill to an entity and quickly teach it some skills +/// The ability to add a to an entity +/// and quickly teach it some skills. /// [RegisterComponent, Access(typeof(SharedCP14KnowledgeSystem))] public sealed partial class CP14AutoAddKnowledgeComponent : Component { [DataField] - public List> Knowledge = new(); + public List> Knowledge = []; } diff --git a/Content.Shared/_CP14/Knowledge/Components/CP14KnowledgeLearningSourceComponent.cs b/Content.Shared/_CP14/Knowledge/Components/CP14KnowledgeLearningSourceComponent.cs index 23af4f2cb9..065f19a0dc 100644 --- a/Content.Shared/_CP14/Knowledge/Components/CP14KnowledgeLearningSourceComponent.cs +++ b/Content.Shared/_CP14/Knowledge/Components/CP14KnowledgeLearningSourceComponent.cs @@ -10,7 +10,7 @@ namespace Content.Shared._CP14.Knowledge.Components; public sealed partial class CP14KnowledgeLearningSourceComponent : Component { [DataField, ViewVariables(VVAccess.ReadOnly)] - public HashSet> Knowledges { get; private set; } = new(); + public HashSet> Knowledge { get; private set; } = []; [DataField] public TimeSpan DoAfter = TimeSpan.FromSeconds(5f); diff --git a/Content.Shared/_CP14/Knowledge/Components/CP14KnowledgePaperTextComponent.cs b/Content.Shared/_CP14/Knowledge/Components/CP14KnowledgePaperTextComponent.cs index 7e5f291dc5..a97ce508ec 100644 --- a/Content.Shared/_CP14/Knowledge/Components/CP14KnowledgePaperTextComponent.cs +++ b/Content.Shared/_CP14/Knowledge/Components/CP14KnowledgePaperTextComponent.cs @@ -1,10 +1,8 @@ - namespace Content.Shared._CP14.Knowledge.Components; /// -/// automatically generates content for PaperComponent, based on the knowledge that can be learnt from this object +/// Automatically generates content for PaperComponent, +/// based on the knowledge that can be learnt from this object. /// [RegisterComponent, Access(typeof(SharedCP14KnowledgeSystem))] -public sealed partial class CP14KnowledgePaperTextComponent : Component -{ -} +public sealed partial class CP14KnowledgePaperTextComponent : Component; diff --git a/Content.Shared/_CP14/Knowledge/Components/CP14KnowledgeStorageComponent.cs b/Content.Shared/_CP14/Knowledge/Components/CP14KnowledgeStorageComponent.cs index cd5605affa..94aeace471 100644 --- a/Content.Shared/_CP14/Knowledge/Components/CP14KnowledgeStorageComponent.cs +++ b/Content.Shared/_CP14/Knowledge/Components/CP14KnowledgeStorageComponent.cs @@ -4,11 +4,11 @@ using Robust.Shared.Prototypes; namespace Content.Shared._CP14.Knowledge.Components; /// -/// a list of skills learned by this entity +/// A list of learned by this entity. /// [RegisterComponent, Access(typeof(SharedCP14KnowledgeSystem))] public sealed partial class CP14KnowledgeStorageComponent : Component { [DataField, ViewVariables(VVAccess.ReadOnly)] - public HashSet> Knowledges { get; private set; } = new(); + public HashSet> Knowledge { get; private set; } = []; } diff --git a/Content.Shared/_CP14/Knowledge/Prototypes/CP14KnowledgePrototype.cs b/Content.Shared/_CP14/Knowledge/Prototypes/CP14KnowledgePrototype.cs index 9380c8c40d..4dd19ef81e 100644 --- a/Content.Shared/_CP14/Knowledge/Prototypes/CP14KnowledgePrototype.cs +++ b/Content.Shared/_CP14/Knowledge/Prototypes/CP14KnowledgePrototype.cs @@ -8,19 +8,18 @@ namespace Content.Shared._CP14.Knowledge.Prototypes; [Prototype("CP14Knowledge")] public sealed partial class CP14KnowledgePrototype : IPrototype { - [ViewVariables] [IdDataField] public string ID { get; private set; } = default!; [DataField(required: true)] - public LocId Name { get; private set; } = default!; + public LocId Name { get; private set; } [DataField] - public LocId Desc{ get; private set; } = default!; + public LocId Desc { get; private set; } /// - /// to study this knowledge, other knowledge on which it is based may be necessary. + /// To study this knowledge, other knowledge on which it is based may be necessary. /// [DataField] - public HashSet> Dependencies = new(); + public HashSet> Dependencies = []; } diff --git a/Content.Shared/_CP14/Knowledge/SharedCP14KnowledgeSystem.cs b/Content.Shared/_CP14/Knowledge/SharedCP14KnowledgeSystem.cs index 063ee84e84..2d6f0ef7d5 100644 --- a/Content.Shared/_CP14/Knowledge/SharedCP14KnowledgeSystem.cs +++ b/Content.Shared/_CP14/Knowledge/SharedCP14KnowledgeSystem.cs @@ -26,13 +26,13 @@ public abstract partial class SharedCP14KnowledgeSystem : EntitySystem return; if (!TryComp(ent, out var knowledge)) return; - if (knowledge.Knowledges.Count <= 0) + if (knowledge.Knowledge.Count <= 0) return; var sb = new StringBuilder(); sb.Append(Loc.GetString("cp14-knowledge-book-pre-text")); - foreach (var k in knowledge.Knowledges) + foreach (var k in knowledge.Knowledge) { if (!_proto.TryIndex(k, out var indexedKnowledge)) continue; @@ -54,7 +54,7 @@ public abstract partial class SharedCP14KnowledgeSystem : EntitySystem if (!Resolve(uid, ref knowledgeStorage, false)) return false; - if (!knowledgeStorage.Knowledges.Contains(knowledge)) + if (!knowledgeStorage.Knowledge.Contains(knowledge)) return false; var ev = new CP14KnowledgeUsedEvent(uid, knowledge, factor); @@ -72,7 +72,7 @@ public abstract partial class SharedCP14KnowledgeSystem : EntitySystem if (!Resolve(uid, ref knowledgeStorage, false)) return false; - return knowledgeStorage.Knowledges.Contains(knowledge); + return knowledgeStorage.Knowledge.Contains(knowledge); } } From 35e6bae5fe4f2abcf259aecf41e864c40481bdbc Mon Sep 17 00:00:00 2001 From: Tornado Tech <54727692+Tornado-Technology@users.noreply.github.com> Date: Thu, 6 Mar 2025 18:40:17 +1000 Subject: [PATCH 05/25] refactor: Add AllKnowing comp, separate paper and events --- .../Knowledge/CP14KnowledgePaperTextSystem.cs | 62 ++++++++++ .../Components/CP14AllKnowingComponent.cs | 6 + .../Events/CP14KnowledgeInfoEvent.cs | 18 +++ .../Events/CP14KnowledgeLearnDoAfterEvent.cs | 17 +++ .../Events/CP14KnowledgeUsedEvent.cs | 18 +++ .../Events/CP14RequestKnowledgeInfoEvent.cs | 14 +++ .../Knowledge/SharedCP14KnowledgeSystem.cs | 111 ++---------------- 7 files changed, 148 insertions(+), 98 deletions(-) create mode 100644 Content.Shared/_CP14/Knowledge/CP14KnowledgePaperTextSystem.cs create mode 100644 Content.Shared/_CP14/Knowledge/Components/CP14AllKnowingComponent.cs create mode 100644 Content.Shared/_CP14/Knowledge/Events/CP14KnowledgeInfoEvent.cs create mode 100644 Content.Shared/_CP14/Knowledge/Events/CP14KnowledgeLearnDoAfterEvent.cs create mode 100644 Content.Shared/_CP14/Knowledge/Events/CP14KnowledgeUsedEvent.cs create mode 100644 Content.Shared/_CP14/Knowledge/Events/CP14RequestKnowledgeInfoEvent.cs diff --git a/Content.Shared/_CP14/Knowledge/CP14KnowledgePaperTextSystem.cs b/Content.Shared/_CP14/Knowledge/CP14KnowledgePaperTextSystem.cs new file mode 100644 index 0000000000..3101ba75a7 --- /dev/null +++ b/Content.Shared/_CP14/Knowledge/CP14KnowledgePaperTextSystem.cs @@ -0,0 +1,62 @@ +using System.Text; +using Content.Shared._CP14.Knowledge.Components; +using Content.Shared.Paper; +using Robust.Shared.Prototypes; + +namespace Content.Shared._CP14.Knowledge; + +public sealed class CP14KnowledgePaperTextSystem : EntitySystem +{ + [Dependency] private readonly IPrototypeManager _prototype = default!; + [Dependency] private readonly PaperSystem _paper = default!; + + public override void Initialize() + { + SubscribeLocalEvent(OnPaperMapInit); + } + + private void OnPaperMapInit(Entity ent, ref MapInitEvent args) + { + if (!TryComp(ent, out var paperComponent)) + return; + + var paper = new Entity(ent, paperComponent); + + if (!TryComp(ent, out var knowledge)) + return; + + if (knowledge.Knowledge.Count == 0) + return; + + var content = GenerateText(knowledge); + + _paper.SetContent(paper, content); + paper.Comp.EditingDisabled = true; + + // Yes we need to do synchronization after such changes, + // yes predict, but we need to + Dirty(paper); + } + + private string GenerateText(CP14KnowledgeLearningSourceComponent source) + { + var stringBuilder = new StringBuilder(); + + // Header + stringBuilder.Append(Loc.GetString("cp14-knowledge-book-pre-text")); + + // Main body + foreach (var prototypeId in source.Knowledge) + { + if (!_prototype.TryIndex(prototypeId, out var indexedKnowledge)) + continue; + + stringBuilder.Append($"\n{Loc.GetString(indexedKnowledge.Desc)}"); + } + + // Footer + stringBuilder.Append($"\n\n{Loc.GetString("cp14-knowledge-book-post-text")}"); + + return stringBuilder.ToString(); + } +} diff --git a/Content.Shared/_CP14/Knowledge/Components/CP14AllKnowingComponent.cs b/Content.Shared/_CP14/Knowledge/Components/CP14AllKnowingComponent.cs new file mode 100644 index 0000000000..f110be086d --- /dev/null +++ b/Content.Shared/_CP14/Knowledge/Components/CP14AllKnowingComponent.cs @@ -0,0 +1,6 @@ +using Robust.Shared.GameStates; + +namespace Content.Shared._CP14.Knowledge.Components; + +[RegisterComponent, NetworkedComponent] +public sealed partial class CP14AllKnowingComponent : Component; diff --git a/Content.Shared/_CP14/Knowledge/Events/CP14KnowledgeInfoEvent.cs b/Content.Shared/_CP14/Knowledge/Events/CP14KnowledgeInfoEvent.cs new file mode 100644 index 0000000000..638cb24e29 --- /dev/null +++ b/Content.Shared/_CP14/Knowledge/Events/CP14KnowledgeInfoEvent.cs @@ -0,0 +1,18 @@ +using Content.Shared._CP14.Knowledge.Prototypes; +using Robust.Shared.Prototypes; +using Robust.Shared.Serialization; + +namespace Content.Shared._CP14.Knowledge.Events; + +[Serializable, NetSerializable] +public sealed class CP14KnowledgeInfoEvent : EntityEventArgs +{ + public readonly NetEntity NetEntity; + public readonly HashSet> AllKnowledge; + + public CP14KnowledgeInfoEvent(NetEntity netEntity, HashSet> allKnowledge) + { + NetEntity = netEntity; + AllKnowledge = allKnowledge; + } +} diff --git a/Content.Shared/_CP14/Knowledge/Events/CP14KnowledgeLearnDoAfterEvent.cs b/Content.Shared/_CP14/Knowledge/Events/CP14KnowledgeLearnDoAfterEvent.cs new file mode 100644 index 0000000000..3a015e09ac --- /dev/null +++ b/Content.Shared/_CP14/Knowledge/Events/CP14KnowledgeLearnDoAfterEvent.cs @@ -0,0 +1,17 @@ +using Content.Shared._CP14.Knowledge.Prototypes; +using Content.Shared.DoAfter; +using Robust.Shared.Prototypes; +using Robust.Shared.Serialization; + +namespace Content.Shared._CP14.Knowledge.Events; + +[Serializable, NetSerializable] +public sealed partial class CP14KnowledgeLearnDoAfterEvent : DoAfterEvent +{ + public ProtoId Knowledge; + + public override DoAfterEvent Clone() + { + return this; + } +} diff --git a/Content.Shared/_CP14/Knowledge/Events/CP14KnowledgeUsedEvent.cs b/Content.Shared/_CP14/Knowledge/Events/CP14KnowledgeUsedEvent.cs new file mode 100644 index 0000000000..df5049bb3f --- /dev/null +++ b/Content.Shared/_CP14/Knowledge/Events/CP14KnowledgeUsedEvent.cs @@ -0,0 +1,18 @@ +using Content.Shared._CP14.Knowledge.Prototypes; +using Robust.Shared.Prototypes; + +namespace Content.Shared._CP14.Knowledge.Events; + +public sealed class CP14KnowledgeUsedEvent : EntityEventArgs +{ + public readonly EntityUid User; + public readonly ProtoId Knowledge; + public readonly float Factor; + + public CP14KnowledgeUsedEvent(EntityUid uid, ProtoId knowledge, float factor) + { + User = uid; + Knowledge = knowledge; + Factor = factor; + } +} diff --git a/Content.Shared/_CP14/Knowledge/Events/CP14RequestKnowledgeInfoEvent.cs b/Content.Shared/_CP14/Knowledge/Events/CP14RequestKnowledgeInfoEvent.cs new file mode 100644 index 0000000000..9ac9261a5e --- /dev/null +++ b/Content.Shared/_CP14/Knowledge/Events/CP14RequestKnowledgeInfoEvent.cs @@ -0,0 +1,14 @@ +using Robust.Shared.Serialization; + +namespace Content.Shared._CP14.Knowledge.Events; + +[Serializable, NetSerializable] +public sealed class CP14RequestKnowledgeInfoEvent : EntityEventArgs +{ + public readonly NetEntity NetEntity; + + public CP14RequestKnowledgeInfoEvent(NetEntity netEntity) + { + NetEntity = netEntity; + } +} diff --git a/Content.Shared/_CP14/Knowledge/SharedCP14KnowledgeSystem.cs b/Content.Shared/_CP14/Knowledge/SharedCP14KnowledgeSystem.cs index 2d6f0ef7d5..164a16bb98 100644 --- a/Content.Shared/_CP14/Knowledge/SharedCP14KnowledgeSystem.cs +++ b/Content.Shared/_CP14/Knowledge/SharedCP14KnowledgeSystem.cs @@ -1,5 +1,6 @@ using System.Text; using Content.Shared._CP14.Knowledge.Components; +using Content.Shared._CP14.Knowledge.Events; using Content.Shared._CP14.Knowledge.Prototypes; using Content.Shared.DoAfter; using Content.Shared.Ghost; @@ -10,113 +11,27 @@ using Robust.Shared.Serialization; namespace Content.Shared._CP14.Knowledge; -public abstract partial class SharedCP14KnowledgeSystem : EntitySystem +public abstract class SharedCP14KnowledgeSystem : EntitySystem { - [Dependency] private readonly IPrototypeManager _proto = default!; - [Dependency] private readonly PaperSystem _paper = default!; - - public override void Initialize() + public bool HasKnowledge(Entity entity, ProtoId knowledge) { - SubscribeLocalEvent(OnPaperMapInit); + if (HasComp(entity)) + return true; + + return Resolve(entity, ref entity.Comp, false) && entity.Comp.Knowledge.Contains(knowledge); } - private void OnPaperMapInit(Entity ent, ref MapInitEvent args) + public bool TryUseKnowledge(Entity entity, ProtoId knowledge, float factor = 1f) { - if (!TryComp(ent, out var paper)) - return; - if (!TryComp(ent, out var knowledge)) - return; - if (knowledge.Knowledge.Count <= 0) - return; - - var sb = new StringBuilder(); - - sb.Append(Loc.GetString("cp14-knowledge-book-pre-text")); - foreach (var k in knowledge.Knowledge) - { - if (!_proto.TryIndex(k, out var indexedKnowledge)) - continue; - - sb.Append($"\n{Loc.GetString(indexedKnowledge.Desc)}"); - } - - sb.Append($"\n\n{Loc.GetString("cp14-knowledge-book-post-text")}"); - - _paper.SetContent((ent, paper), sb.ToString()); - paper.EditingDisabled = true; - } - - public bool UseKnowledge(EntityUid uid, - ProtoId knowledge, - float factor = 1f, - CP14KnowledgeStorageComponent? knowledgeStorage = null) - { - if (!Resolve(uid, ref knowledgeStorage, false)) + if (!Resolve(entity, ref entity.Comp, false)) return false; - if (!knowledgeStorage.Knowledge.Contains(knowledge)) + if (!entity.Comp.Knowledge.Contains(knowledge)) return false; - var ev = new CP14KnowledgeUsedEvent(uid, knowledge, factor); - RaiseLocalEvent(uid, ev); + var ev = new CP14KnowledgeUsedEvent(entity, knowledge, factor); + RaiseLocalEvent(entity, ev); + return true; } - - public bool HasKnowledge(EntityUid uid, - ProtoId knowledge, - CP14KnowledgeStorageComponent? knowledgeStorage = null) - { - if (HasComp(uid)) //All-knowing ghosts - return true; - - if (!Resolve(uid, ref knowledgeStorage, false)) - return false; - - return knowledgeStorage.Knowledge.Contains(knowledge); - } -} - -public sealed class CP14KnowledgeUsedEvent : EntityEventArgs -{ - public readonly EntityUid User; - public readonly ProtoId Knowledge; - public readonly float Factor; - - public CP14KnowledgeUsedEvent(EntityUid uid, ProtoId knowledge, float factor) - { - User = uid; - Knowledge = knowledge; - Factor = factor; - } -} - -[Serializable, NetSerializable] -public sealed partial class CP14KnowledgeLearnDoAfterEvent : DoAfterEvent -{ - public ProtoId Knowledge; - public override DoAfterEvent Clone() => this; -} - -[Serializable, NetSerializable] -public sealed class CP14KnowledgeInfoEvent : EntityEventArgs -{ - public readonly NetEntity NetEntity; - public readonly HashSet> AllKnowledge; - - public CP14KnowledgeInfoEvent(NetEntity netEntity, HashSet> allKnowledge) - { - NetEntity = netEntity; - AllKnowledge = allKnowledge; - } -} - -[Serializable, NetSerializable] -public sealed class RequestKnowledgeInfoEvent : EntityEventArgs -{ - public readonly NetEntity NetEntity; - - public RequestKnowledgeInfoEvent(NetEntity netEntity) - { - NetEntity = netEntity; - } } From 0d23f79eb65f71d73ae1ecad08b983e80c7b1425 Mon Sep 17 00:00:00 2001 From: Viator-MV Date: Thu, 6 Mar 2025 11:40:30 +0300 Subject: [PATCH 06/25] =?UTF-8?q?=D0=9E=D0=B1=D0=BD=D0=BE=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D0=B8=D0=B5=20=D1=81=D0=BA=D0=B5=D0=BB=D0=B5=D1=82?= =?UTF-8?q?=D0=BE=D0=B2=20(#971)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Literally everything Как будто я не должен был делать всё в 1 коммит * фиксы маленькие изменения по запросу Эда * fix HideSpawnMenu * fix2 fix * final fix final fix --- .../_CP14/Entities/Clothing/Belt/quiver.yml | 11 ++ .../_CP14/Entities/Clothing/Rings/ring.yml | 23 +++ .../_CP14/Entities/Mobs/NPC/skeleton.yml | 135 +++++++++++++++++- .../Objects/Weapons/ModularPresets/arrow.yml | 17 +++ .../Objects/Weapons/ModularPresets/sword.yml | 15 ++ .../Loadouts/Misc/undead_startinggear.yml | 45 +++++- 6 files changed, 240 insertions(+), 6 deletions(-) diff --git a/Resources/Prototypes/_CP14/Entities/Clothing/Belt/quiver.yml b/Resources/Prototypes/_CP14/Entities/Clothing/Belt/quiver.yml index c87ca6a983..7f30df98d8 100644 --- a/Resources/Prototypes/_CP14/Entities/Clothing/Belt/quiver.yml +++ b/Resources/Prototypes/_CP14/Entities/Clothing/Belt/quiver.yml @@ -42,6 +42,17 @@ - id: CP14ModularIronArrow amount: 16 +- type: entity + parent: CP14ClothingBeltQuiver + id: CP14ClothingBeltQuiverCopperArrow + categories: [ ForkFiltered ] + suffix: Full. Copper. Arrow + components: + - type: StorageFill + contents: + - id: CP14ModularCopperArrow + amount: 16 + - type: entity parent: CP14ClothingBeltQuiver id: CP14ClothingBeltQuiverMithrilArrow diff --git a/Resources/Prototypes/_CP14/Entities/Clothing/Rings/ring.yml b/Resources/Prototypes/_CP14/Entities/Clothing/Rings/ring.yml index 8d3cadc6cb..488878a542 100644 --- a/Resources/Prototypes/_CP14/Entities/Clothing/Rings/ring.yml +++ b/Resources/Prototypes/_CP14/Entities/Clothing/Rings/ring.yml @@ -28,6 +28,29 @@ spells: - CP14ActionSpellIceShards +- type: entity + id: CP14ClothingRingSkeletonWizard + parent: CP14ClothingRingBase + name: skeleton wizard conductive ring + suffix: Skeleton, Unremoveable + description: A mana conuctive ring for the true wizards + categories: [ HideSpawnMenu ] + components: + - type: Unremoveable + - type: CP14SpellStorageRequireAttune + - type: CP14MagicAttuningItem + - type: CP14SpellStorageAccessWearing + - type: CP14SpellStorage + spells: + - CP14ActionSpellIceShards + - CP14ActionSpellSphereOfLight + - CP14ActionSpellCureWounds + - CP14ActionSpellFlameCreation + - type: Sprite + layers: + - state: brass_ring + - state: berill_stone_small + - type: entity id: CP14ClothingRingFireball parent: CP14ClothingRingBase diff --git a/Resources/Prototypes/_CP14/Entities/Mobs/NPC/skeleton.yml b/Resources/Prototypes/_CP14/Entities/Mobs/NPC/skeleton.yml index e36beb5584..5c7bc25e3c 100644 --- a/Resources/Prototypes/_CP14/Entities/Mobs/NPC/skeleton.yml +++ b/Resources/Prototypes/_CP14/Entities/Mobs/NPC/skeleton.yml @@ -1,22 +1,103 @@ - type: entity - id: CP14MobUndeadSkeleton + id: CP14MobUndeadSkeletonHalberd parent: CP14BaseMobSkeleton name: skeleton description: Animated by the dark magic of a fragile skeleton. Skeletons are usually extremely intelligent creatures, controlled by a recently deceased soul. categories: [ ForkFiltered ] + suffix: Halebard components: - type: NpcFactionMember factions: - CP14Monster - type: Loadout prototypes: - - CP14MobSkeleton + - CP14MobSkeletonHalberd + +- type: entity + id: CP14MobUndeadSkeletonSword + parent: CP14MobUndeadSkeletonHalberd + name: skeleton + description: Animated by the dark magic of a fragile skeleton. Skeletons are usually extremely intelligent creatures, controlled by a recently deceased soul. + categories: [ ForkFiltered ] + suffix: Sword + components: + - type: Loadout + prototypes: + - CP14MobSkeletonSword + +- type: entity + id: CP14MobUndeadSkeletonDodger + parent: CP14MobUndeadSkeletonHalberd + name: skeleton + description: Animated by the dark magic of a fragile skeleton. Skeletons are usually extremely intelligent creatures, controlled by a recently deceased soul. + categories: [ ForkFiltered ] + suffix: Dodger + components: + - type: Loadout + prototypes: + - CP14MobSkeletonDodger + +- type: entity + id: CP14MobUndeadSkeletonArcher + parent: CP14MobUndeadSkeletonHalberd + name: skeleton + description: Animated by the dark magic of a fragile skeleton. Skeletons are usually extremely intelligent creatures, controlled by a recently deceased soul. + categories: [ ForkFiltered ] + suffix: Archer + components: + - type: Loadout + prototypes: + - CP14MobSkeletonArcher + +- type: entity + id: CP14MobUndeadSkeletonWizard + parent: CP14MobUndeadSkeletonHalberd + name: skeleton + description: Animated by the dark magic of a fragile skeleton. Skeletons are usually extremely intelligent creatures, controlled by a recently deceased soul. + categories: [ ForkFiltered ] + suffix: Wizard + components: + - type: Loadout + prototypes: + - CP14MobSkeletonWizard - type: entity id: SpawnPointGhostDemiplaneSkeleton name: ghost role spawn point description: A ghost role for a bloodthirsty and cunning skeleton. - suffix: skeleton + suffix: skeleton random + categories: [ ForkFiltered ] + parent: MarkerBase + components: + - type: EntityTableSpawner + table: !type:GroupSelector + children: + - !type:GroupSelector + weight: 10 + children: + - id: SpawnPointGhostDemiplaneSkeletonWizard + - !type:GroupSelector + weight: 25 + children: + - id: SpawnPointGhostDemiplaneSkeletonHalberd + - !type:GroupSelector + weight: 60 + children: + - id: SpawnPointGhostDemiplaneSkeletonSword + - id: SpawnPointGhostDemiplaneSkeletonDodger + - id: SpawnPointGhostDemiplaneSkeletonArcher + - type: Sprite + sprite: Markers/jobs.rsi + layers: + - state: green + - sprite: _CP14/Mobs/Species/Skeleton/parts.rsi + state: full + +- type: entity + id: SpawnPointGhostDemiplaneSkeletonHalberd + name: ghost role spawn point + description: A ghost role for a bloodthirsty and cunning skeleton. + suffix: skeleton Halebard categories: [ ForkFiltered ] parent: MarkerBase components: @@ -30,10 +111,54 @@ raffle: settings: default - type: GhostRoleMobSpawner - prototype: CP14MobUndeadSkeleton + prototype: CP14MobUndeadSkeletonHalberd - type: Sprite sprite: Markers/jobs.rsi layers: - state: green - sprite: _CP14/Mobs/Species/Skeleton/parts.rsi - state: full \ No newline at end of file + state: full + +- type: entity + id: SpawnPointGhostDemiplaneSkeletonSword + name: ghost role spawn point + description: A ghost role for a bloodthirsty and cunning skeleton. + suffix: skeleton Sword + categories: [ ForkFiltered ] + parent: SpawnPointGhostDemiplaneSkeletonHalberd + components: + - type: GhostRoleMobSpawner + prototype: CP14MobUndeadSkeletonSword + +- type: entity + id: SpawnPointGhostDemiplaneSkeletonDodger + name: ghost role spawn point + description: A ghost role for a bloodthirsty and cunning skeleton. + suffix: skeleton Dodger + categories: [ ForkFiltered ] + parent: SpawnPointGhostDemiplaneSkeletonHalberd + components: + - type: GhostRoleMobSpawner + prototype: CP14MobUndeadSkeletonDodger + +- type: entity + id: SpawnPointGhostDemiplaneSkeletonArcher + name: ghost role spawn point + description: A ghost role for a bloodthirsty and cunning skeleton. + suffix: skeleton Archer + categories: [ ForkFiltered ] + parent: SpawnPointGhostDemiplaneSkeletonHalberd + components: + - type: GhostRoleMobSpawner + prototype: CP14MobUndeadSkeletonArcher + +- type: entity + id: SpawnPointGhostDemiplaneSkeletonWizard + name: ghost role spawn point + description: A ghost role for a bloodthirsty and cunning skeleton. + suffix: skeleton Wizard + categories: [ ForkFiltered ] + parent: SpawnPointGhostDemiplaneSkeletonHalberd + components: + - type: GhostRoleMobSpawner + prototype: CP14MobUndeadSkeletonWizard \ No newline at end of file diff --git a/Resources/Prototypes/_CP14/Entities/Objects/Weapons/ModularPresets/arrow.yml b/Resources/Prototypes/_CP14/Entities/Objects/Weapons/ModularPresets/arrow.yml index 47ffda7e2e..aaabeeb755 100644 --- a/Resources/Prototypes/_CP14/Entities/Objects/Weapons/ModularPresets/arrow.yml +++ b/Resources/Prototypes/_CP14/Entities/Objects/Weapons/ModularPresets/arrow.yml @@ -31,3 +31,20 @@ - type: CP14ModularCraftAutoAssemble details: - TipMithrilArrow + +- type: entity + id: CP14ModularCopperArrow + parent: CP14ModularRodLucens + name: copper arrow + description: It's the cheapest and weakest arrow you've ever seen, but it's better than nothing. + components: + - type: Sprite + layers: + - state: icon + - state: tail + - sprite: _CP14/Objects/ModularTools/Tip/arrow.rsi + state: icon + color: "#bd712f" + - type: CP14ModularCraftAutoAssemble + details: + - TipCopperArrow \ No newline at end of file diff --git a/Resources/Prototypes/_CP14/Entities/Objects/Weapons/ModularPresets/sword.yml b/Resources/Prototypes/_CP14/Entities/Objects/Weapons/ModularPresets/sword.yml index d9c3c8bd76..c195226313 100644 --- a/Resources/Prototypes/_CP14/Entities/Objects/Weapons/ModularPresets/sword.yml +++ b/Resources/Prototypes/_CP14/Entities/Objects/Weapons/ModularPresets/sword.yml @@ -37,6 +37,21 @@ name: bone halberd description: Monstrous weapons of bone. components: + - type: Sprite + layers: + - state: icon + - sprite: _CP14/Objects/ModularTools/Blade/Sword/bone_sword.rsi + state: icon + - type: CP14ModularCraftAutoAssemble + details: + - BladeBoneSword + +- type: entity + id: CP14ModularSkeletonSword + parent: CP14ModularGripWooden + name: bone sword + description: Monstrous weapons of bone. + components: - type: Sprite layers: - state: icon diff --git a/Resources/Prototypes/_CP14/Loadouts/Misc/undead_startinggear.yml b/Resources/Prototypes/_CP14/Loadouts/Misc/undead_startinggear.yml index 1ded128f40..e7cfe0570f 100644 --- a/Resources/Prototypes/_CP14/Loadouts/Misc/undead_startinggear.yml +++ b/Resources/Prototypes/_CP14/Loadouts/Misc/undead_startinggear.yml @@ -17,13 +17,56 @@ mask: CP14ClothingMaskSinner - type: startingGear - id: CP14MobSkeleton + id: CP14MobSkeletonHalberd equipment: + shirt: CP14ClothingWarriorsGarbDress pants: CP14ClothingPantsLoincloth neck: CP14ModularSkeletonHalberd + shoes: CP14ClothingShoesSandals inhand: - CP14TorchIgnited +- type: startingGear + id: CP14MobSkeletonSword + equipment: + pants: CP14ClothingPantsLoincloth + belt1: CP14ModularSkeletonSword + shoes: CP14ClothingShoesSandals + head: CP14ClothingHeadMetalHeadband + inhand: + - CP14TorchIgnited + +- type: startingGear + id: CP14MobSkeletonDodger + equipment: + mask: CP14ClothingMaskSinner + pants: CP14ClothingPantsLoincloth + belt1: CP14ModularIronDagger + belt2: CP14ModularIronDagger + inhand: + - CP14TorchIgnited + +- type: startingGear + id: CP14MobSkeletonArcher + equipment: + shirt: CP14ClothingWarriorsGarbDress + pants: CP14ClothingPantsLoincloth + neck: CP14BowCombat + belt1: CP14ClothingBeltQuiverCopperArrow + pocket1: CP14SpellScrollSphereOfLight + #inhand: + # - CP14SpellScrollSphereOfLight + +- type: startingGear + id: CP14MobSkeletonWizard + equipment: + head: CP14ClothingHeadTriangularHat + shirt: CP14ClothingShirtCottonBlack + pants: CP14ClothingPantsBrown + shoes: CP14LongLeatherBoots + cloak: CP14ClothingCloakWhite + ring2: CP14ClothingRingSkeletonWizard + - type: startingGear id: CP14MobSkeletonCloset equipment: From 45a6919994340f52ec8ff1d98635ba2b169f1255 Mon Sep 17 00:00:00 2001 From: Tornado Tech <54727692+Tornado-Technology@users.noreply.github.com> Date: Thu, 6 Mar 2025 18:46:51 +1000 Subject: [PATCH 07/25] fix: KnowledgeRequired --- .../_CP14/Workbench/Requirements/KnowledgeRequired.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Content.Shared/_CP14/Workbench/Requirements/KnowledgeRequired.cs b/Content.Shared/_CP14/Workbench/Requirements/KnowledgeRequired.cs index 02d71cbd8b..c62d1aabdc 100644 --- a/Content.Shared/_CP14/Workbench/Requirements/KnowledgeRequired.cs +++ b/Content.Shared/_CP14/Workbench/Requirements/KnowledgeRequired.cs @@ -26,7 +26,7 @@ public sealed partial class KnowledgeRequired : CP14WorkbenchCraftRequirement public override void PostCraft(EntityManager entManager, HashSet placedEntities, EntityUid user) { var knowledgeSystem = entManager.System(); - knowledgeSystem.UseKnowledge(user, Knowledge); + knowledgeSystem.TryUseKnowledge(user, Knowledge); } public override string GetRequirementTitle(IPrototypeManager protoManager) @@ -41,8 +41,8 @@ public sealed partial class KnowledgeRequired : CP14WorkbenchCraftRequirement return null; } - public override SpriteSpecifier? GetRequirementTexture(IPrototypeManager protoManager) + public override SpriteSpecifier GetRequirementTexture(IPrototypeManager protoManager) { - return new SpriteSpecifier.Texture(new("/Textures/Interface/students-cap.svg.192dpi.png")); + return new SpriteSpecifier.Texture(new ResPath("/Textures/Interface/students-cap.svg.192dpi.png")); } } From 7b5283b35b9d977e28e47e63302481657fe70911 Mon Sep 17 00:00:00 2001 From: Tornado Tech <54727692+Tornado-Technology@users.noreply.github.com> Date: Thu, 6 Mar 2025 18:56:06 +1000 Subject: [PATCH 08/25] fix: Knowledge events usings (I hate Rider) --- .../_CP14/Knowledge/ClientCP14KnowledgeSystem.cs | 7 ++++--- Content.Server/_CP14/Knowledge/CP14KnowledgeSystem.cs | 5 +++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/Content.Client/_CP14/Knowledge/ClientCP14KnowledgeSystem.cs b/Content.Client/_CP14/Knowledge/ClientCP14KnowledgeSystem.cs index 5c43fbda72..e493caa375 100644 --- a/Content.Client/_CP14/Knowledge/ClientCP14KnowledgeSystem.cs +++ b/Content.Client/_CP14/Knowledge/ClientCP14KnowledgeSystem.cs @@ -1,11 +1,12 @@ using Content.Shared._CP14.Knowledge; +using Content.Shared._CP14.Knowledge.Events; using Content.Shared._CP14.Knowledge.Prototypes; using Robust.Client.Player; using Robust.Shared.Prototypes; namespace Content.Client._CP14.Knowledge; -public sealed partial class ClientCP14KnowledgeSystem : SharedCP14KnowledgeSystem +public sealed class ClientCP14KnowledgeSystem : SharedCP14KnowledgeSystem { [Dependency] private readonly IPlayerManager _players = default!; @@ -24,7 +25,7 @@ public sealed partial class ClientCP14KnowledgeSystem : SharedCP14KnowledgeSyste if (entity is null) return; - RaiseNetworkEvent(new RequestKnowledgeInfoEvent(GetNetEntity(entity.Value))); + RaiseNetworkEvent(new CP14RequestKnowledgeInfoEvent(GetNetEntity(entity.Value))); } private void OnCharacterKnowledgeEvent(CP14KnowledgeInfoEvent msg, EntitySessionEventArgs args) @@ -37,6 +38,6 @@ public sealed partial class ClientCP14KnowledgeSystem : SharedCP14KnowledgeSyste public readonly record struct KnowledgeData( EntityUid Entity, - HashSet> AllKnowledges + HashSet> AllKnowledge ); } diff --git a/Content.Server/_CP14/Knowledge/CP14KnowledgeSystem.cs b/Content.Server/_CP14/Knowledge/CP14KnowledgeSystem.cs index e632be9614..8dda24305e 100644 --- a/Content.Server/_CP14/Knowledge/CP14KnowledgeSystem.cs +++ b/Content.Server/_CP14/Knowledge/CP14KnowledgeSystem.cs @@ -4,6 +4,7 @@ using Content.Server.Mind; using Content.Server.Popups; using Content.Shared._CP14.Knowledge; using Content.Shared._CP14.Knowledge.Components; +using Content.Shared._CP14.Knowledge.Events; using Content.Shared._CP14.Knowledge.Prototypes; using Content.Shared.Administration; using Content.Shared.Administration.Logs; @@ -39,7 +40,7 @@ public sealed partial class CP14KnowledgeSystem : SharedCP14KnowledgeSystem SubscribeLocalEvent>(AddKnowledgeLearningVerb); SubscribeLocalEvent(KnowledgeLearnedEvent); - SubscribeNetworkEvent(OnRequestKnowledgeInfoEvent); + SubscribeNetworkEvent(OnRequestKnowledgeInfoEvent); } private void KnowledgeLearnedEvent(Entity ent, ref CP14KnowledgeLearnDoAfterEvent args) @@ -254,7 +255,7 @@ public sealed partial class CP14KnowledgeSystem : SharedCP14KnowledgeSystem return true; } - private void OnRequestKnowledgeInfoEvent(RequestKnowledgeInfoEvent msg, EntitySessionEventArgs args) + private void OnRequestKnowledgeInfoEvent(CP14RequestKnowledgeInfoEvent msg, EntitySessionEventArgs args) { if (!args.SenderSession.AttachedEntity.HasValue || args.SenderSession.AttachedEntity != GetEntity(msg.NetEntity)) return; From c1acf815418050f981d747a84e28496fb92a96c6 Mon Sep 17 00:00:00 2001 From: Ed <96445749+TheShuEd@users.noreply.github.com> Date: Thu, 6 Mar 2025 12:01:43 +0300 Subject: [PATCH 09/25] NewTrade (#969) * trading portal replace traveling storeship * clean up content * clean up content 2 * seel and buy realization * fixes * Update migration.yml * Update migration.yml * Update dev_map.yml * Update dev_map.yml * thats work correctly now * bugfies and visual * factions * faction restruct + name reduce * unnesting sell cargo positions * unnesting cargo positions * more cargo content * Update buy.yml * improve tradeportal visual * Update migration.yml * Bank ad Commandant removal * merchant objectives * finish * clean up content * Update migration.yml * fix goal calculation * Update comoss.yml * Update dev_map.yml --- .../CP14StoreProductControl.xaml | 10 +- .../CP14StoreProductControl.xaml.cs | 15 +- .../TravelingStoreShip/CP14StoreWindow.xaml | 3 +- .../CP14StoreWindow.xaml.cs | 21 +- .../_CP14/Cargo/CP14CargoSystem.Portals.cs | 55 + .../_CP14/Cargo/CP14CargoSystem.Shuttle.cs | 118 - .../_CP14/Cargo/CP14CargoSystem.UI.cs | 106 +- Content.Server/_CP14/Cargo/CP14CargoSystem.cs | 349 +- .../Cargo/CP14TravelingStoreshipComponent.cs | 8 - ...P14TravelingStoreshipFTLTargetComponent.cs | 10 - .../_CP14/Currency/CP14CurrencySystem.cs | 42 +- .../CP14CurrencyStoredConditionComponent.cs | 20 - .../CP14RichestJobConditionComponent.cs | 25 + .../CP14CurrencyCollectConditionSystem.cs | 99 +- .../Systems/CP14RichestJobCondtionSystem.cs | 74 + .../_CP14/RoleSalary/CP14SalarySystem.cs | 23 +- .../_CP14/Cargo/CP14CargoMoneyBoxComponent.cs | 9 - .../_CP14/Cargo/CP14CargoStoreComponent.cs | 11 - .../_CP14/Cargo/CP14SellingPalettComponent.cs | 11 - Content.Shared/_CP14/Cargo/CP14StoreUI.cs | 15 +- .../Cargo/CP14TradingInfoBoardComponent.cs | 17 + ...onent.cs => CP14TradingPortalComponent.cs} | 43 +- .../BuyServices/CP14BuyItemsService.cs | 45 +- .../BuyServices/CP14UnlockPositionsService.cs | 53 +- .../CP14StoreBuyPositionPrototype.cs | 35 +- .../Prototype/CP14StoreFactionPrototype.cs | 16 + .../CP14StoreSellPositionPrototype.cs | 24 +- .../SellServices/CP14SellProrotypeService.cs | 65 + .../SellServices/CP14SellStackService.cs | 26 +- .../SellServices/CP14SellWhitelistService.cs | 24 +- .../Currency/CP14SharedCurrencySystem.cs | 13 +- .../en-US/_CP14/lockKey/locks-types.ftl | 10 +- .../_CP14/objectives/condition/personal.ftl | 5 +- .../Locale/en-US/_CP14/store/factions.ftl | 11 + .../positions_buy.ftl | 0 .../services.ftl | 0 Resources/Locale/en-US/_CP14/store/ui.ftl | 11 + .../travelingStoreship/positions_sell.ftl | 37 - .../positions_sell_special.ftl | 20 - .../en-US/_CP14/travelingStoreship/ui.ftl | 9 - .../ru-RU/_CP14/lockKey/locks-types.ftl | 10 +- .../_CP14/objectives/condition/personal.ftl | 5 +- .../Locale/ru-RU/_CP14/store/factions.ftl | 11 + .../positions_buy.ftl | 0 .../services.ftl | 0 Resources/Locale/ru-RU/_CP14/store/ui.ftl | 11 + .../position_sell_special.ftl | 20 - .../travelingStoreship/positions_sell.ftl | 37 - .../ru-RU/_CP14/travelingStoreship/ui.ftl | 9 - Resources/Maps/_CP14/comoss.yml | 10692 +++++++--------- Resources/Maps/_CP14/comoss_d.yml | 1297 +- Resources/Maps/_CP14/dev_map.yml | 13 +- .../Catalog/Cargo/Store/BradFamily/buy.yml | 188 + .../Cargo/Store/BradFamily/sell_special.yml | 99 + .../Cargo/Store/General/sell_special.yml | 15 + .../Catalog/Cargo/Store/HelmirWeapon/buy.yml | 99 + .../Catalog/Cargo/Store/Sell/metalls.yml | 95 - .../_CP14/Catalog/Cargo/Store/Sell/misc.yml | 37 - .../Catalog/Cargo/Store/SpiceStream/buy.yml | 221 + .../Catalog/Cargo/Store/SpiceStream/sell.yml | 94 + .../Cargo/Store/SpiceStream/sell_special.yml | 29 + .../Cargo/Store/Sylphoria/sell_special.yml | 19 + .../_CP14/Catalog/Cargo/Store/buy.yml | 184 - .../_CP14/Catalog/Cargo/Store/factions.yml | 19 + .../Catalog/Cargo/Store/sell_special.yml | 100 - .../Prototypes/_CP14/Catalog/Cargo/crates.yml | 157 - .../_CP14/Catalog/Fills/closets.yml | 39 - .../_CP14/Entities/Markers/Spawners/jobs.yml | 44 +- .../_CP14/Entities/Markers/misc.yml | 38 - .../_CP14/Entities/Objects/Keys/bank.yml | 48 - .../_CP14/Entities/Objects/Keys/keyrings.yml | 19 +- .../_CP14/Entities/Objects/Keys/merchant.yml | 31 + .../_CP14/Entities/Objects/Materials/dye.yml | 6 + ...ls_filled.yml => vials_filled_aspects.yml} | 0 .../Specific/Alchemy/vials_filled_potions.yml | 107 + .../_CP14/Entities/Stations/base.yml | 7 - .../Structures/Doors/Locked/alchemist.yml | 18 +- .../Entities/Structures/Doors/Locked/bank.yml | 75 - .../Structures/Doors/Locked/merchant.yml | 52 + .../Structures/Flora/Crystal/shards.yml | 12 +- .../Structures/Furniture/barrel_crane.yml | 1 - .../Structures/Furniture/cabinets.yml | 10 +- .../Entities/Structures/Furniture/closets.yml | 127 +- .../Structures/Furniture/glass_showcase.yml | 103 + .../Entities/Structures/Furniture/pallets.yml | 2 - .../Entities/Structures/Furniture/safe.yml | 70 + .../Specific/Economy/trade_board.yml | 23 + .../Specific/Economy/trade_portal.yml | 113 + .../_CP14/Entities/Structures/test.yml | 24 - .../Prototypes/_CP14/GameRules/roundstart.yml | 4 +- .../_CP14/LockCategories/LockCategory.yml | 5 +- .../_CP14/LockCategories/lockTypes.yml | 45 +- Resources/Prototypes/_CP14/Maps/Factoria.yml | 4 +- Resources/Prototypes/_CP14/Maps/comoss.yml | 8 +- .../_CP14/Objectives/empire_orders.yml | 34 - .../_CP14/Objectives/personal_objectives.yml | 20 +- .../_CP14/Roles/Jobs/Traders/commandant.yml | 26 - .../_CP14/Roles/Jobs/departments.yml | 12 +- Resources/Prototypes/_CP14/StatusIcon/job.yml | 8 - .../Misc/job_icons.rsi/Commandant.png | Bin 204 -> 0 bytes .../Interface/Misc/job_icons.rsi/Merchant.png | Bin 212 -> 188 bytes .../Interface/Misc/job_icons.rsi/meta.json | 3 - .../Economy/trade_portal.rsi/base.png | Bin 0 -> 2578 bytes .../Economy/trade_portal.rsi/base_door.png | Bin 0 -> 104 bytes .../Economy/trade_portal.rsi/base_open.png | Bin 0 -> 1981 bytes .../Economy/trade_portal.rsi/flag_bard.png | Bin 0 -> 1496 bytes .../Economy/trade_portal.rsi/flag_helmir.png | Bin 0 -> 1339 bytes .../Economy/trade_portal.rsi/flag_spice.png | Bin 0 -> 1435 bytes .../trade_portal.rsi/flag_sylphoria.png | Bin 0 -> 1344 bytes .../Economy/trade_portal.rsi/icon.png | Bin 0 -> 3050 bytes .../Economy/trade_portal.rsi/meta.json | 68 + Resources/migration.yml | 108 +- 112 files changed, 7448 insertions(+), 8815 deletions(-) create mode 100644 Content.Server/_CP14/Cargo/CP14CargoSystem.Portals.cs delete mode 100644 Content.Server/_CP14/Cargo/CP14CargoSystem.Shuttle.cs delete mode 100644 Content.Server/_CP14/Cargo/CP14TravelingStoreshipComponent.cs delete mode 100644 Content.Server/_CP14/Cargo/CP14TravelingStoreshipFTLTargetComponent.cs delete mode 100644 Content.Server/_CP14/Objectives/Components/CP14CurrencyStoredConditionComponent.cs create mode 100644 Content.Server/_CP14/Objectives/Components/CP14RichestJobConditionComponent.cs create mode 100644 Content.Server/_CP14/Objectives/Systems/CP14RichestJobCondtionSystem.cs delete mode 100644 Content.Shared/_CP14/Cargo/CP14CargoMoneyBoxComponent.cs delete mode 100644 Content.Shared/_CP14/Cargo/CP14CargoStoreComponent.cs delete mode 100644 Content.Shared/_CP14/Cargo/CP14SellingPalettComponent.cs create mode 100644 Content.Shared/_CP14/Cargo/CP14TradingInfoBoardComponent.cs rename Content.Shared/_CP14/Cargo/{CP14StationTravelingStoreShipTargetComponent.cs => CP14TradingPortalComponent.cs} (56%) create mode 100644 Content.Shared/_CP14/Cargo/Prototype/CP14StoreFactionPrototype.cs create mode 100644 Content.Shared/_CP14/Cargo/Prototype/SellServices/CP14SellProrotypeService.cs create mode 100644 Resources/Locale/en-US/_CP14/store/factions.ftl rename Resources/Locale/en-US/_CP14/{travelingStoreship => store}/positions_buy.ftl (100%) rename Resources/Locale/en-US/_CP14/{travelingStoreship => store}/services.ftl (100%) create mode 100644 Resources/Locale/en-US/_CP14/store/ui.ftl delete mode 100644 Resources/Locale/en-US/_CP14/travelingStoreship/positions_sell.ftl delete mode 100644 Resources/Locale/en-US/_CP14/travelingStoreship/positions_sell_special.ftl delete mode 100644 Resources/Locale/en-US/_CP14/travelingStoreship/ui.ftl create mode 100644 Resources/Locale/ru-RU/_CP14/store/factions.ftl rename Resources/Locale/ru-RU/_CP14/{travelingStoreship => store}/positions_buy.ftl (100%) rename Resources/Locale/ru-RU/_CP14/{travelingStoreship => store}/services.ftl (100%) create mode 100644 Resources/Locale/ru-RU/_CP14/store/ui.ftl delete mode 100644 Resources/Locale/ru-RU/_CP14/travelingStoreship/position_sell_special.ftl delete mode 100644 Resources/Locale/ru-RU/_CP14/travelingStoreship/positions_sell.ftl delete mode 100644 Resources/Locale/ru-RU/_CP14/travelingStoreship/ui.ftl create mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/BradFamily/buy.yml create mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/BradFamily/sell_special.yml create mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/General/sell_special.yml create mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/HelmirWeapon/buy.yml delete mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/Sell/metalls.yml delete mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/Sell/misc.yml create mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/SpiceStream/buy.yml create mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/SpiceStream/sell.yml create mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/SpiceStream/sell_special.yml create mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/Sylphoria/sell_special.yml delete mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/buy.yml create mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/factions.yml delete mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/Store/sell_special.yml delete mode 100644 Resources/Prototypes/_CP14/Catalog/Cargo/crates.yml delete mode 100644 Resources/Prototypes/_CP14/Entities/Objects/Keys/bank.yml create mode 100644 Resources/Prototypes/_CP14/Entities/Objects/Keys/merchant.yml rename Resources/Prototypes/_CP14/Entities/Objects/Specific/Alchemy/{vials_filled.yml => vials_filled_aspects.yml} (100%) create mode 100644 Resources/Prototypes/_CP14/Entities/Objects/Specific/Alchemy/vials_filled_potions.yml delete mode 100644 Resources/Prototypes/_CP14/Entities/Structures/Doors/Locked/bank.yml create mode 100644 Resources/Prototypes/_CP14/Entities/Structures/Doors/Locked/merchant.yml create mode 100644 Resources/Prototypes/_CP14/Entities/Structures/Furniture/glass_showcase.yml create mode 100644 Resources/Prototypes/_CP14/Entities/Structures/Furniture/safe.yml create mode 100644 Resources/Prototypes/_CP14/Entities/Structures/Specific/Economy/trade_board.yml create mode 100644 Resources/Prototypes/_CP14/Entities/Structures/Specific/Economy/trade_portal.yml delete mode 100644 Resources/Prototypes/_CP14/Roles/Jobs/Traders/commandant.yml delete mode 100644 Resources/Textures/_CP14/Interface/Misc/job_icons.rsi/Commandant.png create mode 100644 Resources/Textures/_CP14/Structures/Specific/Economy/trade_portal.rsi/base.png create mode 100644 Resources/Textures/_CP14/Structures/Specific/Economy/trade_portal.rsi/base_door.png create mode 100644 Resources/Textures/_CP14/Structures/Specific/Economy/trade_portal.rsi/base_open.png create mode 100644 Resources/Textures/_CP14/Structures/Specific/Economy/trade_portal.rsi/flag_bard.png create mode 100644 Resources/Textures/_CP14/Structures/Specific/Economy/trade_portal.rsi/flag_helmir.png create mode 100644 Resources/Textures/_CP14/Structures/Specific/Economy/trade_portal.rsi/flag_spice.png create mode 100644 Resources/Textures/_CP14/Structures/Specific/Economy/trade_portal.rsi/flag_sylphoria.png create mode 100644 Resources/Textures/_CP14/Structures/Specific/Economy/trade_portal.rsi/icon.png create mode 100644 Resources/Textures/_CP14/Structures/Specific/Economy/trade_portal.rsi/meta.json diff --git a/Content.Client/_CP14/TravelingStoreShip/CP14StoreProductControl.xaml b/Content.Client/_CP14/TravelingStoreShip/CP14StoreProductControl.xaml index a599bca8f7..1637e572e2 100644 --- a/Content.Client/_CP14/TravelingStoreShip/CP14StoreProductControl.xaml +++ b/Content.Client/_CP14/TravelingStoreShip/CP14StoreProductControl.xaml @@ -1,11 +1,19 @@