From b66ee390a6d28aac3df9e6ede7a4db44ee1b7ab6 Mon Sep 17 00:00:00 2001 From: Ed <96445749+TheShuEd@users.noreply.github.com> Date: Fri, 4 Apr 2025 10:35:48 +0300 Subject: [PATCH] Dynamic demiplane weather + farming hotfix (#1131) * dynamic demiplane weather * add skeleton sprite * hotfix farming * Update wheat.yml --- .../GameTicking/Rules/CP14WeatherRule.cs | 2 +- .../CP14WeatherControllerComponent.cs | 6 - .../CP14WeatherControllerSystem.cs | 62 ++++++++--- .../CP14SharedFarmingSystem.Interactions.cs | 4 +- .../_CP14/WeatherControl/CP14WeatherData.cs | 5 +- Resources/Maps/_CP14/comoss.yml | 2 + Resources/Maps/_CP14/comoss_d.yml | 2 + Resources/Maps/_CP14/factoria.yml | 3 +- Resources/Maps/_CP14/factoria_d.yml | 2 + .../Entities/Structures/Floor/floorLava.yml | 2 +- .../Flora/Gatherable/Farm/cabbage.yml | 3 +- .../Flora/Gatherable/Farm/cucumber.yml | 7 +- .../Flora/Gatherable/Farm/onion.yml | 7 +- .../Flora/Gatherable/Farm/pepper.yml | 7 +- .../Flora/Gatherable/Farm/potato.yml | 7 +- .../Flora/Gatherable/Farm/pumpkin.yml | 3 +- .../Structures/Flora/Gatherable/Farm/sage.yml | 5 +- .../Flora/Gatherable/Farm/tomatoes.yml | 6 +- .../Flora/Gatherable/Farm/wheat.yml | 9 +- .../Structures/Flora/Gatherable/base.yml | 20 +++- .../Demiplane/Locations/t2_magma_caves.yml | 9 +- .../Demiplane/Modifiers/Danger/mobs.yml | 2 + .../Demiplane/Modifiers/MapLight/mapLight.yml | 45 +++++++- .../Demiplane/Modifiers/Weather/weather.yml | 104 +++++------------- .../Prototypes/_CP14/Reagents/precurser.yml | 2 +- Resources/Prototypes/_CP14/weather.yml | 25 +++++ .../Mobs/Species/Skeleton/parts.rsi/full.png | Bin 709 -> 1636 bytes .../Mobs/Species/Skeleton/parts.rsi/meta.json | 3 +- 28 files changed, 212 insertions(+), 142 deletions(-) diff --git a/Content.Server/_CP14/GameTicking/Rules/CP14WeatherRule.cs b/Content.Server/_CP14/GameTicking/Rules/CP14WeatherRule.cs index 998ba35e8a..3e1f577d4c 100644 --- a/Content.Server/_CP14/GameTicking/Rules/CP14WeatherRule.cs +++ b/Content.Server/_CP14/GameTicking/Rules/CP14WeatherRule.cs @@ -48,7 +48,7 @@ public sealed class CP14WeatherRule : StationEventSystem(mapUid, out var controller)) { - controller.NextWeatherTime = _timing.CurTime + TimeSpan.FromSeconds(controller.ClearDuration.Max); + controller.NextWeatherTime = _timing.CurTime; controller.Enabled = true; } diff --git a/Content.Server/_CP14/WeatherControl/CP14WeatherControllerComponent.cs b/Content.Server/_CP14/WeatherControl/CP14WeatherControllerComponent.cs index 482330365d..181994632a 100644 --- a/Content.Server/_CP14/WeatherControl/CP14WeatherControllerComponent.cs +++ b/Content.Server/_CP14/WeatherControl/CP14WeatherControllerComponent.cs @@ -13,12 +13,6 @@ public sealed partial class CP14WeatherControllerComponent : Component [DataField] public bool Enabled = true; - /// - /// random time with no weather. - /// - [DataField] - public MinMax ClearDuration = new(120,1200); - [DataField] public HashSet Entries = new(); diff --git a/Content.Server/_CP14/WeatherControl/CP14WeatherControllerSystem.cs b/Content.Server/_CP14/WeatherControl/CP14WeatherControllerSystem.cs index 6aaac8c793..12974e5d48 100644 --- a/Content.Server/_CP14/WeatherControl/CP14WeatherControllerSystem.cs +++ b/Content.Server/_CP14/WeatherControl/CP14WeatherControllerSystem.cs @@ -1,4 +1,7 @@ +using System.Linq; using Content.Server.Weather; +using Content.Shared._CP14.WeatherControl; +using Content.Shared.Weather; using Robust.Shared.Prototypes; using Robust.Shared.Random; using Robust.Shared.Timing; @@ -12,13 +15,6 @@ public sealed class CP14WeatherControllerSystem : EntitySystem [Dependency] private readonly WeatherSystem _weather = default!; [Dependency] private readonly IPrototypeManager _proto = default!; - public override void Initialize() - { - base.Initialize(); - - SubscribeLocalEvent(OnMapInit); - } - public override void Update(float frameTime) { base.Update(frameTime); @@ -32,22 +28,52 @@ public sealed class CP14WeatherControllerSystem : EntitySystem if (!weather.Enabled) continue; - var weatherData = _random.Pick(weather.Entries); + var weatherData = PickWeatherDataByWeight(uid, weather.Entries); if (!_proto.TryIndex(weatherData.Visuals, out var weatherVisualsIndexed)) - continue; - - var weatherDuration = TimeSpan.FromSeconds(weatherData.Duration.Next(_random)); - _weather.SetWeather(Transform(uid).MapID, weatherVisualsIndexed, _timing.CurTime + weatherDuration); - - var clearDuration = TimeSpan.FromSeconds(weather.ClearDuration.Next(_random)); - weather.NextWeatherTime = _timing.CurTime + weatherDuration + clearDuration; + { + var weatherDuration = TimeSpan.FromSeconds(weatherData.Duration.Next(_random)); + _weather.SetWeather(Transform(uid).MapID, null, null); + weather.NextWeatherTime = _timing.CurTime + weatherDuration; + } + else + { + var weatherDuration = TimeSpan.FromSeconds(weatherData.Duration.Next(_random)); + _weather.SetWeather(Transform(uid).MapID, weatherVisualsIndexed, null); + weather.NextWeatherTime = _timing.CurTime + weatherDuration; + } } } - private void OnMapInit(Entity ent, ref MapInitEvent args) + private CP14WeatherData PickWeatherDataByWeight(EntityUid map, HashSet entries) { - ent.Comp.NextWeatherTime = _timing.CurTime + TimeSpan.FromSeconds(ent.Comp.ClearDuration.Next(_random)); + var filteredEntries = new HashSet(entries); + + if (TryComp(map, out var currentWeather)) + { + foreach (var (weatherProto, data) in currentWeather.Weather) + { + if (!_proto.TryIndex(weatherProto, out var weatherPrototype)) + continue; + + filteredEntries.RemoveWhere(entry => entry.Visuals == weatherPrototype); + } + } + + var totalWeight = filteredEntries.Sum(entry => entry.Weight); + var randomWeight = _random.NextFloat() * totalWeight; + var currentWeight = 0f; + + foreach (var entry in filteredEntries) + { + currentWeight += entry.Weight; + if (randomWeight < currentWeight) + { + return entry; + } + } + + // Fallback in case of rounding errors + return filteredEntries.Last(); } } - diff --git a/Content.Shared/_CP14/Farming/CP14SharedFarmingSystem.Interactions.cs b/Content.Shared/_CP14/Farming/CP14SharedFarmingSystem.Interactions.cs index d783bc6dc3..f7059eaa79 100644 --- a/Content.Shared/_CP14/Farming/CP14SharedFarmingSystem.Interactions.cs +++ b/Content.Shared/_CP14/Farming/CP14SharedFarmingSystem.Interactions.cs @@ -141,7 +141,7 @@ public abstract partial class CP14SharedFarmingSystem private void OnSeedInteract(Entity seed, ref AfterInteractEvent args) { - if (args.Handled) + if (args.Handled || !args.CanReach) return; if (!CanPlantSeed(seed, args.ClickLocation, args.User)) @@ -206,7 +206,7 @@ public abstract partial class CP14SharedFarmingSystem if (_map.GetAnchoredEntities((map.Value, gridComp), position).ToList().Count > 0) { - if (user is not null) + if (user is not null && _timing.IsFirstTimePredicted && _net.IsClient) _popup.PopupEntity(Loc.GetString("cp14-farming-soil-occupied"), user.Value, user.Value); return false; } diff --git a/Content.Shared/_CP14/WeatherControl/CP14WeatherData.cs b/Content.Shared/_CP14/WeatherControl/CP14WeatherData.cs index 7de114bd05..c77d2f1257 100644 --- a/Content.Shared/_CP14/WeatherControl/CP14WeatherData.cs +++ b/Content.Shared/_CP14/WeatherControl/CP14WeatherData.cs @@ -8,8 +8,11 @@ namespace Content.Shared._CP14.WeatherControl; public sealed class CP14WeatherData { [DataField(required: true)] - public ProtoId Visuals { get; set; } + public ProtoId? Visuals { get; set; } = null; [DataField] public MinMax Duration { get; set; } = new(30, 300); + + [DataField] + public float Weight { get; set; } = 1f; } diff --git a/Resources/Maps/_CP14/comoss.yml b/Resources/Maps/_CP14/comoss.yml index c63efe584b..b7fb603759 100644 --- a/Resources/Maps/_CP14/comoss.yml +++ b/Resources/Maps/_CP14/comoss.yml @@ -65,6 +65,8 @@ entities: id: Comoss - type: CP14WeatherController entries: + - visuals: null + weight: 3 - visuals: CP14Mist - visuals: CP14Rain - type: LightCycle diff --git a/Resources/Maps/_CP14/comoss_d.yml b/Resources/Maps/_CP14/comoss_d.yml index 76edb46d88..d984791b18 100644 --- a/Resources/Maps/_CP14/comoss_d.yml +++ b/Resources/Maps/_CP14/comoss_d.yml @@ -70,6 +70,8 @@ entities: - 0 - type: CP14WeatherController entries: + - visuals: null + weight: 2 - visuals: CP14Mist - type: MapGrid chunks: diff --git a/Resources/Maps/_CP14/factoria.yml b/Resources/Maps/_CP14/factoria.yml index 5abffcc8ee..57165cdc4f 100644 --- a/Resources/Maps/_CP14/factoria.yml +++ b/Resources/Maps/_CP14/factoria.yml @@ -70,9 +70,10 @@ entities: data: {} - type: CP14WeatherController entries: + - visuals: null + weight: 3 - visuals: CP14Mist - visuals: CP14Rain - - visuals: CP14Storm - type: Biome forcedMarkerLayers: [] markerLayers: [] diff --git a/Resources/Maps/_CP14/factoria_d.yml b/Resources/Maps/_CP14/factoria_d.yml index b4e41cc8bd..80952ac685 100644 --- a/Resources/Maps/_CP14/factoria_d.yml +++ b/Resources/Maps/_CP14/factoria_d.yml @@ -246,6 +246,8 @@ entities: layers: [] - type: CP14WeatherController entries: + - visuals: null + weight: 2 - visuals: CP14Mist - type: Fixtures fixtures: {} diff --git a/Resources/Prototypes/_CP14/Entities/Structures/Floor/floorLava.yml b/Resources/Prototypes/_CP14/Entities/Structures/Floor/floorLava.yml index a2c82601e6..5743342506 100644 --- a/Resources/Prototypes/_CP14/Entities/Structures/Floor/floorLava.yml +++ b/Resources/Prototypes/_CP14/Entities/Structures/Floor/floorLava.yml @@ -12,7 +12,7 @@ key: floorTile - type: TileEmission range: 0.5 - color: "#ff9c40" + color: "#ffc691" - type: StepTrigger requiredTriggeredSpeed: 0 intersectRatio: 0.1 diff --git a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/cabbage.yml b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/cabbage.yml index 47c4873e5d..b5a0cf989d 100644 --- a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/cabbage.yml +++ b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/cabbage.yml @@ -1,6 +1,6 @@ - type: entity id: CP14PlantCabbage - parent: CP14GatherablePlantBoringBase + parent: CP14GatherablePlantSingleHarvestBase name: cabbage description: You see a cabbage in front of you. Perhaps you were born in one. components: @@ -13,7 +13,6 @@ sprite: _CP14/Structures/Flora/Farm/cabbage.rsi map: ["enum.PlantVisualLayers.Base"] - type: CP14PlantGatherable - deleteAfterHarvest: true loot: All: CP14GatherCabbage diff --git a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/cucumber.yml b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/cucumber.yml index a9c5bbe010..abc0cf9149 100644 --- a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/cucumber.yml +++ b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/cucumber.yml @@ -1,6 +1,6 @@ - type: entity id: CP14PlantCucumber - parent: CP14GatherablePlantBoringBase + parent: CP14GatherablePlantMultiHarvestBase name: cucumber description: Don't trust people who know how to turn into pickles. components: @@ -13,7 +13,6 @@ sprite: _CP14/Structures/Flora/Farm/cucumber.rsi map: ["enum.PlantVisualLayers.Base"] - type: CP14PlantGatherable - deleteAfterHarvest: false loot: All: CP14GatherCucumber @@ -21,5 +20,5 @@ id: CP14GatherCucumber entries: - id: CP14FoodCucumber - amount: 3 - maxAmount: 5 + amount: 1 + maxAmount: 3 diff --git a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/onion.yml b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/onion.yml index 5c1466f368..07eb4887cc 100644 --- a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/onion.yml +++ b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/onion.yml @@ -1,6 +1,6 @@ - type: entity id: CP14PlantOnion - parent: CP14GatherablePlantBoringBase + parent: CP14GatherablePlantSingleHarvestBase name: onion description: He's so cute it brings tears to my eyes to cut him up. components: @@ -13,7 +13,6 @@ sprite: _CP14/Structures/Flora/Farm/onion.rsi map: ["enum.PlantVisualLayers.Base"] - type: CP14PlantGatherable - deleteAfterHarvest: false loot: All: CP14GatherOnion @@ -21,5 +20,5 @@ id: CP14GatherOnion entries: - id: CP14FoodOnion - amount: 3 - maxAmount: 5 + amount: 1 + maxAmount: 3 diff --git a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/pepper.yml b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/pepper.yml index f5beed57d1..bf83625f4b 100644 --- a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/pepper.yml +++ b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/pepper.yml @@ -1,6 +1,6 @@ - type: entity id: CP14PlantPepper - parent: CP14GatherablePlantBoringBase + parent: CP14GatherablePlantSingleHarvestBase name: pepper description: Russian roulette. Are you hot, or are you sweet peppers? components: @@ -15,7 +15,6 @@ - type: CP14PlantVisuals growthSteps: 5 - type: CP14PlantGatherable - deleteAfterHarvest: false loot: All: CP14GatherPepper @@ -23,5 +22,5 @@ id: CP14GatherPepper entries: - id: CP14FoodPepper - amount: 3 - maxAmount: 5 + amount: 2 + maxAmount: 4 diff --git a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/potato.yml b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/potato.yml index dd09b00c94..ae5dbe4b90 100644 --- a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/potato.yml +++ b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/potato.yml @@ -1,6 +1,6 @@ - type: entity id: CP14PlantPotato - parent: CP14GatherablePlantBoringBase + parent: CP14GatherablePlantSingleHarvestBase name: potato description: Some like to associate themselves with potatoes. People like that are not bad people. components: @@ -15,7 +15,6 @@ - type: CP14PlantVisuals growthSteps: 5 - type: CP14PlantGatherable - deleteAfterHarvest: true loot: All: CP14GatherPotato @@ -23,5 +22,5 @@ id: CP14GatherPotato entries: - id: CP14FoodPotato - amount: 3 - maxAmount: 5 + amount: 2 + maxAmount: 4 diff --git a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/pumpkin.yml b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/pumpkin.yml index 45c7595c34..98c9f9ee07 100644 --- a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/pumpkin.yml +++ b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/pumpkin.yml @@ -1,6 +1,6 @@ - type: entity id: CP14PlantPumpkin - parent: CP14GatherablePlantBoringBase + parent: CP14GatherablePlantSingleHarvestBase name: pumpkin description: Legends say there is a pumpkin king who stares into your soul through the crowns of trees. components: @@ -13,7 +13,6 @@ sprite: _CP14/Structures/Flora/Farm/pumpkin.rsi map: ["enum.PlantVisualLayers.Base"] - type: CP14PlantGatherable - deleteAfterHarvest: true loot: All: CP14GatherPumpkin diff --git a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/sage.yml b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/sage.yml index 54fd2513ee..ea3e2abe56 100644 --- a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/sage.yml +++ b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/sage.yml @@ -1,6 +1,6 @@ - type: entity id: CP14PlantSage - parent: CP14GatherablePlantBoringBase + parent: CP14GatherablePlantSingleHarvestBase name: sage description: Medicinal sage. Some love it for its medicinal properties, others for its narcotic properties. Which side are you on? components: @@ -15,7 +15,6 @@ - type: CP14PlantVisuals growthSteps: 4 - type: CP14PlantGatherable - deleteAfterHarvest: true loot: All: CP14GatherSage @@ -24,4 +23,4 @@ entries: - id: CP14WildSage amount: 1 - maxAmount: 2 + maxAmount: 3 diff --git a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/tomatoes.yml b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/tomatoes.yml index 10eb654356..c30ae02fe0 100644 --- a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/tomatoes.yml +++ b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/tomatoes.yml @@ -1,6 +1,6 @@ - type: entity id: CP14PlantTomatoes - parent: CP14GatherablePlantBoringBase + parent: CP14GatherablePlantMultiHarvestBase name: tomatoes description: On the one hand, it's a delicious fruit. But why eat it when it's much more fun to use tomatoes as a throwing projectile? components: @@ -21,5 +21,5 @@ id: CP14GatherTomatoes entries: - id: CP14FoodTomatoes - amount: 3 - maxAmount: 5 + amount: 1 + maxAmount: 3 diff --git a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/wheat.yml b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/wheat.yml index 999ba490d2..ef99e2469e 100644 --- a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/wheat.yml +++ b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/Farm/wheat.yml @@ -1,6 +1,6 @@ - type: entity id: CP14PlantWheat - parent: CP14GatherablePlantBoringBase + parent: CP14GatherablePlantSingleHarvestBase name: wheat description: Most popular crop. Unpretentious, it opens the way to an abundance of flour products. components: @@ -13,9 +13,8 @@ sprite: _CP14/Structures/Flora/Farm/wheat.rsi map: ["enum.PlantVisualLayers.Base"] - type: CP14PlantVisuals - growthSteps: 3 + growthSteps: 5 - type: CP14PlantGatherable - deleteAfterHarvest: true loot: All: CP14GatherWheat - type: CP14WaveShader @@ -26,5 +25,5 @@ id: CP14GatherWheat entries: - id: CP14Wheat - amount: 3 - maxAmount: 5 + amount: 2 + maxAmount: 4 diff --git a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/base.yml b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/base.yml index 4c7f8a3fcd..e2a850406b 100644 --- a/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/base.yml +++ b/Resources/Prototypes/_CP14/Entities/Structures/Flora/Gatherable/base.yml @@ -146,8 +146,8 @@ max: 3 - type: entity - id: CP14GatherablePlantBoringBase - parent: + id: CP14GatherablePlantSingleHarvestBase + parent: - CP14BaseFlammableSpreading - CP14GatherablePlantBase abstract: true @@ -170,4 +170,18 @@ - type: FireVisuals sprite: _CP14/Effects/fire.rsi normalState: full - alternateState: full2 \ No newline at end of file + alternateState: full2 + - type: CP14PlantGatherable + deleteAfterHarvest: true + +- type: entity + id: CP14GatherablePlantMultiHarvestBase + parent: CP14GatherablePlantSingleHarvestBase + abstract: true + components: + - type: CP14PlantGrowing + growthPerUpdate: 0.025 + - type: CP14PlantFading + resourcePerMinute: 0.20 + - type: CP14PlantGatherable + deleteAfterHarvest: false \ No newline at end of file diff --git a/Resources/Prototypes/_CP14/Procedural/Demiplane/Locations/t2_magma_caves.yml b/Resources/Prototypes/_CP14/Procedural/Demiplane/Locations/t2_magma_caves.yml index c832b13801..3fdfc4fe38 100644 --- a/Resources/Prototypes/_CP14/Procedural/Demiplane/Locations/t2_magma_caves.yml +++ b/Resources/Prototypes/_CP14/Procedural/Demiplane/Locations/t2_magma_caves.yml @@ -7,11 +7,18 @@ name: cp14-demiplane-location-cave-magma tags: - CP14DemiplaneOres - - CP14DemiplaneUnderground + #- CP14DemiplaneUnderground + - CP14DemiplaneOpenSky - CP14DemiplaneHot components: + - type: MapLight + ambientLightColor: "#BFEEFFFF" + - type: CP14CloudShadows - type: Biome template: CP14LavaOceanFill + - type: SunShadow + - type: SunShadowCycle + - type: Roof - type: dungeonConfig id: CP14DemiplaneCavesRing diff --git a/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/Danger/mobs.yml b/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/Danger/mobs.yml index a8d813cd95..08dbdf323b 100644 --- a/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/Danger/mobs.yml +++ b/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/Danger/mobs.yml @@ -9,6 +9,8 @@ generationWeight: 1.5 categories: Danger: 0.3 + blacklistTags: + - CP14DemiplaneHot layers: - !type:OreDunGen entity: CP14SpawnMobUndeadZombieRandom diff --git a/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/MapLight/mapLight.yml b/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/MapLight/mapLight.yml index 0779c2473b..454509d00c 100644 --- a/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/MapLight/mapLight.yml +++ b/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/MapLight/mapLight.yml @@ -72,4 +72,47 @@ requiredTags: - CP14DemiplaneOpenSky components: - - type: LightCycle \ No newline at end of file + - type: LightCycle + +- type: cp14DemiplaneModifier + id: MapLightCycleCold + levels: + min: 1 + max: 10 + categories: + MapLight: 1 + generationWeight: 2 + requiredTags: + - CP14DemiplaneOpenSky + - CP14DemiplaneCold + components: + - type: LightCycle + originalColor: "#7bc2e0" + +- type: cp14DemiplaneModifier + id: MapLightCycleHot + levels: + min: 1 + max: 10 + categories: + MapLight: 1 + requiredTags: + - CP14DemiplaneOpenSky + - CP14DemiplaneHot + components: + - type: LightCycle + originalColor: "#ff8929" + +- type: cp14DemiplaneModifier + id: MapLightCycleHot2 + levels: + min: 1 + max: 10 + categories: + MapLight: 1 + requiredTags: + - CP14DemiplaneOpenSky + - CP14DemiplaneHot + components: + - type: LightCycle + originalColor: "#d68787" \ No newline at end of file diff --git a/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/Weather/weather.yml b/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/Weather/weather.yml index 90dcbadc43..9fbca7557f 100644 --- a/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/Weather/weather.yml +++ b/Resources/Prototypes/_CP14/Procedural/Demiplane/Modifiers/Weather/weather.yml @@ -5,19 +5,13 @@ Weather: 1 - type: cp14DemiplaneModifier - id: WeatherMist + id: WeatherInfinityMist categories: Weather: 1 components: - type: CP14WeatherController - clearDuration: - min: 0 - max: 0 entries: - visuals: CP14Mist - duration: - min: 10000 - max: 10000 - type: cp14DemiplaneModifier id: WeatherRain @@ -27,17 +21,18 @@ - CP14DemiplaneOpenSky components: - type: CP14WeatherController - clearDuration: - min: 0 - max: 0 entries: + - visuals: null + duration: + min: 30 + max: 120 - visuals: CP14Rain duration: - min: 10000 - max: 10000 + min: 180 + max: 240 - type: cp14DemiplaneModifier - id: WeatherStorm + id: WeatherInfinityStorm levels: min: 3 max: 10 @@ -48,14 +43,8 @@ - CP14DemiplaneOpenSky components: - type: CP14WeatherController - clearDuration: - min: 0 - max: 0 entries: - visuals: CP14Storm - duration: - min: 10000 - max: 10000 layers: - !type:OreDunGen entity: CP14DemiplaneRuinsRoomSpawner @@ -64,7 +53,7 @@ maxGroupSize: 1 - type: cp14DemiplaneModifier - id: WeatherSnowLight + id: WeatherSnow levels: min: 1 max: 4 @@ -74,38 +63,15 @@ - CP14DemiplaneCold components: - type: CP14WeatherController - clearDuration: - min: 0 - max: 0 entries: - visuals: CP14SnowLight duration: - min: 10000 - max: 10000 - -- type: cp14DemiplaneModifier - id: WeatherSnowMedium - categories: - Weather: 1 - name: cp14-modifier-snow-storm - requiredTags: - - CP14DemiplaneCold - components: - - type: CP14WeatherController - clearDuration: - min: 0 - max: 0 - entries: + min: 30 + max: 180 - visuals: CP14SnowMedium duration: - min: 10000 - max: 10000 - layers: - - !type:OreDunGen - entity: CP14DemiplaneRuinsRoomSpawner - count: 10 - minGroupSize: 1 - maxGroupSize: 1 + min: 30 + max: 180 - type: cp14DemiplaneModifier id: WeatherSnowHeavy @@ -119,14 +85,15 @@ - CP14DemiplaneCold components: - type: CP14WeatherController - clearDuration: - min: 0 - max: 0 entries: - - visuals: CP14SnowHeavy + - visuals: CP14SnowHeavyWithStorm duration: - min: 10000 - max: 10000 + min: 30 + max: 180 + - visuals: SnowfallHeavy + duration: + min: 30 + max: 60 layers: - !type:OreDunGen entity: CP14DemiplaneRuinsRoomSpawner @@ -144,14 +111,8 @@ Weather: 1 components: - type: CP14WeatherController - clearDuration: - min: 0 - max: 0 entries: - - visuals: CP14ManaMist - duration: - min: 10000 - max: 10000 + - visuals: CP14ManaMist layers: - !type:OreDunGen entity: CP14DemiplaneRuinsRoomSpawner @@ -169,14 +130,8 @@ Weather: 1 components: - type: CP14WeatherController - clearDuration: - min: 0 - max: 0 entries: - - visuals: CP14AntiManaMist - duration: - min: 10000 - max: 10000 + - visuals: CP14AntiManaMist layers: - !type:OreDunGen entity: CP14DemiplaneRuinsRoomSpawner @@ -185,7 +140,7 @@ maxGroupSize: 1 - type: cp14DemiplaneModifier - id: CP14FireStorm + id: CP14FireStormPeriod name: cp14-modifier-fire-storm levels: min: 4 @@ -196,14 +151,15 @@ Weather: 1 components: - type: CP14WeatherController - clearDuration: - min: 0 - max: 0 entries: - - visuals: CP14FireStorm + - visuals: AshfallLight duration: - min: 10000 - max: 10000 + min: 30 + max: 180 + - visuals: CP14FireStorm + duration: + min: 30 + max: 60 layers: - !type:OreDunGen entity: CP14DemiplaneRuinsRoomSpawner diff --git a/Resources/Prototypes/_CP14/Reagents/precurser.yml b/Resources/Prototypes/_CP14/Reagents/precurser.yml index dca28615d1..0e78cd33d1 100644 --- a/Resources/Prototypes/_CP14/Reagents/precurser.yml +++ b/Resources/Prototypes/_CP14/Reagents/precurser.yml @@ -66,7 +66,7 @@ - !type:HealthChange damage: types: - Blunt: 1 + Blunt: -1 - !type:GenericStatusEffect key: SeeingRainbows component: SeeingRainbows diff --git a/Resources/Prototypes/_CP14/weather.yml b/Resources/Prototypes/_CP14/weather.yml index e231b34996..394713590f 100644 --- a/Resources/Prototypes/_CP14/weather.yml +++ b/Resources/Prototypes/_CP14/weather.yml @@ -143,6 +143,31 @@ # - !type:AdjustTemperature # amount: -60000 +- type: weather + id: CP14SnowHeavyWithStorm + sprite: + sprite: /Textures/_CP14/Effects/weather.rsi + state: snowfall_heavy + sound: + path: /Audio/Effects/Weather/snowstorm.ogg + params: + loop: true + volume: -6 + config: + - maxEntities: 2 + frequency: 10 + canAffectOnWeatherBlocker: false + effects: + - !type:SpawnEntityOnTop + prob: 0.25 + entity: CP14SkyLightning + #- effects: + #- !type:ApplyEntityEffect + # prob: 1 + # effects: + # - !type:AdjustTemperature + # amount: -60000 + - type: weather id: CP14FireStorm sprite: diff --git a/Resources/Textures/_CP14/Mobs/Species/Skeleton/parts.rsi/full.png b/Resources/Textures/_CP14/Mobs/Species/Skeleton/parts.rsi/full.png index d164b1c9a3abc6ad0e0f7256bf58e117301b01ac..be74c7330ce63c0466b3806306db563b5a1ae464 100644 GIT binary patch literal 1636 zcmV-q2AlbbP)Px*9!W$&RCt{2TP<_rNDzIxI^dsRD2+Xo0?;rZnip69|3Hh6k?gdc1o zji?%aumRvk=0L&^$N69jU^ZXi+tR0+=ij|^%|YF6|KU}WO8s*pybC7HfS{)nHoU8h+_(SFC^mS%0;JbK?n-~ zQZ`6qbRBmhMfkscy#xR}zr035pqD2ToXr<3{=Ft3goW9BfvMvdC#EgQ{yu&A99^TX z!qjmL;7ZbD%YuAP$ZyJ4vk}vP5N?eB#I$8mpR`v1p6C8}DWp`7piTq;rjBED+EyxG z*MaA`kx3Chjni)$BmSGo#27Wx`-Lpz3SczoO4Yln&L%4tS3mcI4Mu~mEMo?F{Hg|! zFm(8H6Cok2P?|sNkbD5;0Q7SzP9cO9+1_Z-l{b@#v0WKG?BXZeC&AO04u7r&sE!T@ zoyzsql~g@G06aZBV!7Iy%C7sl$m36HfG&To0O%#vmz_F}F?He@SyIii?$g0?{`CX?7b`#APqkbGF*w&nXe%tfb; z6Oo;mW)!YC6X2o?5^7JCs`XM%b8y}ECxDkGyTa2J0q+2H^9$?zfj0}eTd57!@X=sA3-{(vgx zz)pp;h-tho5SLmWZ?;UWIk5W!2t=;-2h^1fCV2rwi^4sL*6I*ZC9m$$>*y08j*IiN z*g2tYrwB^`M5wA7mB^kR9@)~@fe=>ImylF>@&O#M9TsJTG#NSwt+FzlsU;gS0|Hd@U_tT0PZtHK^uP2_T+F15Qj#xXrlHFRh9?PR+I?I1cb2I`|vX8+qO*dQ+=?~Fi5=u z)F?qve1WXP2~zB*9tE{Ig4>r+SO99RKG~t66Mo8oLT)?^ZX*GwFQKpigs{*XemAnJ zuCxNlv$`q}a+pvxkkp@EoO3Ew*axU9JarsnxpFa^FH$dGr7xgozpvNugAF_{oI~=I zildE%H6W|zPe)+kfut4l#8n_{(Y=f%K5F>W=}Rc=u(Emu)SkWPmsbGwWrCCes(k`9 zFHT=VVGT(33Q#f94>nk?7L}C3vk;Zw*Wn@Pb~6?afkpcgSd*q&Jb$0}(iP&-pexnI;Xvy=Ky6C_>a7j~=?XE;MW-F7bORH4WFaj4 z{^$2v%;5g+R;s*Z_9EKf8KOcZdEH}ZK&QQpKDyBQ$_%jm+DvaaHmE+|x9v)O!TsH> zq)xF;+d^+RHp+fwM@s-n_3sVG#%#VotJx^MB6*b-QEN(6CjmOhMqD# zfklv&WM$2T11$}pdVHs?FZn}YH0VloE;`Wm0aTB#vL_%9YQI96(`YRL^oC=Dc4B0c ibwlMo#*y4lgMR=X694Ae!a6Mg0000Px%e@R3^R9J=8R#8|&}p|ohz0-{4SVo?Ps%v(&LZ4zcesCicvle$M}QCwhvNml?;(t0?6*6FQH;^B zC%ToK1IyJ0-@kn+wc&ELk#eAM$fmkZfh7N@vxmEG+J>(|fI(kF7{vg9nQb@Tw^op` z-s$XN(ARkJWeYF6#^iuz?D(lpfRN;5j_WF66m!G(j}QD|#+lsd>~W{+P+J4O@9~hb z_EU+9tAFJ(X+0#)Ij*Y=`dVpT2s>bz24#5#k~EZ!rn4aXJ&a;lra|k{P?-WkG|X&U zVRgW2fN=nORHA|qjpyDn4LY-JrAZnpBT!_xr{@=CG9J@x#RI^8yTj@1!Es%sN?+Ik zW+ZFOab3l6Q%1bSfVcGCLS=r6r|q;`IU}8Ri@%G;8DA8mQbc70Sk4Ja+bpGAufz?9 z<0Ut!0KjppEHogZ$#_hYjgpg0b)CKj0oWS*e%I~tb}j0B7^b>TZ`}uhq$U_$i$G`? z6~miFvMzrwXpHq@UW$Tc8g#vw3!fg47{`a>1*`@bPG_%C%iTilFe+j+>~Y3p81yyi z3yF{eZxvwE@3$b7f-s5^Mjx93;VwwtT8?0fDG@>A6s#9>8b&b)(Q;!KNFu;4E~4Gg rI0B4jm#a;Q;r{%mgMM;j{;%*GRElV|w_Ub#00000NkvXXu0mjfR%}SG diff --git a/Resources/Textures/_CP14/Mobs/Species/Skeleton/parts.rsi/meta.json b/Resources/Textures/_CP14/Mobs/Species/Skeleton/parts.rsi/meta.json index fbd5dc2f7e..4c10a7932b 100644 --- a/Resources/Textures/_CP14/Mobs/Species/Skeleton/parts.rsi/meta.json +++ b/Resources/Textures/_CP14/Mobs/Species/Skeleton/parts.rsi/meta.json @@ -8,7 +8,8 @@ }, "states": [ { - "name": "full" + "name": "full", + "directions": 4 }, { "name": "head",