-
Notifications
You must be signed in to change notification settings - Fork 523
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Artifexum spray chance to disintegrate (#1044)
* Add chance for artifact disintegration * Add MobGrimForged * Add ambient sound * Progress * Update grim_forged.rsi * Fix faction and animation
- Loading branch information
1 parent
42f58e0
commit 0af9b8c
Showing
13 changed files
with
289 additions
and
5 deletions.
There are no files selected for viewing
36 changes: 36 additions & 0 deletions
36
Content.Server/Chemistry/ReagentEffects/DisintegrateArtifact.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
using Content.Server.Xenoarchaeology.XenoArtifacts; | ||
using Content.Shared.Chemistry.Reagent; | ||
using Robust.Shared.Prototypes; | ||
|
||
namespace Content.Server.Chemistry.ReagentEffects; | ||
|
||
public sealed partial class DisintegrateArtifact : ReagentEffect | ||
{ | ||
|
||
/// <summary> | ||
/// Disintegrate chance | ||
/// </summary> | ||
[DataField("probabilityMin"), ViewVariables(VVAccess.ReadWrite)] | ||
public float ProbabilityMax = 0.05f; | ||
|
||
/// <summary> | ||
/// Disintegrate chance | ||
/// </summary> | ||
[DataField("probabilityMax"), ViewVariables(VVAccess.ReadWrite)] | ||
public float ProbabilityMin = 0.15f; | ||
|
||
/// <summary> | ||
/// The range around the artifact that it will spawn the entity | ||
/// </summary> | ||
[DataField("range")] | ||
public float Range = 0.5f; | ||
|
||
public override void Effect(ReagentEffectArgs args) | ||
{ | ||
var artifact = args.EntityManager.EntitySysManager.GetEntitySystem<ArtifactSystem>(); | ||
artifact.DisintegrateArtifact(args.SolutionEntity, ProbabilityMin, ProbabilityMax, Range); | ||
} | ||
|
||
protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys) => | ||
null; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
131 changes: 131 additions & 0 deletions
131
Resources/Prototypes/_NF/Entities/Mobs/NPCs/artifact_construct.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,131 @@ | ||
- type: entity | ||
abstract: true | ||
parent: | ||
- BaseMob | ||
- MobDamageable | ||
- MobCombat | ||
id: SimpleArtifactMobBase # Mob without barotrauma, freezing and asphyxiation (for space carps!?) | ||
suffix: AI | ||
components: | ||
- type: NpcFactionMember | ||
factions: | ||
- ArtifactConstruct | ||
- type: HTN | ||
rootTask: | ||
task: SimpleHostileCompound | ||
blackboard: | ||
NavClimb: !type:Bool | ||
true | ||
NavSmash: !type:Bool | ||
true | ||
- type: MobThresholds | ||
thresholds: | ||
0: Alive | ||
120: Dead | ||
- type: Body | ||
- type: Climbing | ||
- type: NameIdentifier | ||
group: GenericNumber | ||
- type: SlowOnDamage | ||
speedModifierThresholds: | ||
60: 0.7 | ||
80: 0.5 | ||
- type: ZombieImmune # Artifact constructs should not be able to become zombie | ||
- type: MobPrice | ||
price: 1000 # Living critters are valuable in space. | ||
|
||
- type: entity | ||
parent: [ SimpleArtifactMobBase, FlyingMobBase ] | ||
id: BaseMobArtifactConstruct | ||
name: artifact construct | ||
description: A towering golem crafted from twisted metal and ancient stones. | ||
abstract: true | ||
components: | ||
- type: Tag | ||
tags: | ||
- DoorBumpOpener | ||
- type: Sprite | ||
drawdepth: Mobs | ||
sprite: _NF/Mobs/Aliens/grim_forged.rsi | ||
- type: MovementAlwaysTouching | ||
- type: MovementSpeedModifier | ||
baseWalkSpeed: 1 | ||
baseSprintSpeed: 1.5 | ||
- type: StatusEffects | ||
allowed: | ||
- SlowedDown | ||
- Electrocution | ||
- type: MobState | ||
allowedStates: | ||
- Alive | ||
- Dead | ||
- type: CombatMode | ||
- type: MeleeWeapon | ||
damage: | ||
types: | ||
Blunt: 20 | ||
animation: WeaponArcFist | ||
- type: ReplacementAccent | ||
accent: genericAggressive | ||
|
||
- type: entity | ||
parent: BaseMobArtifactConstruct | ||
id: MobGrimForged | ||
name: artifact construct 1 | ||
components: | ||
- type: Sprite | ||
layers: | ||
- map: [ "enum.DamageStateVisualLayers.Base" ] | ||
state: move | ||
- map: [ "enum.DamageStateVisualLayers.BaseUnshaded" ] | ||
state: flash | ||
shader: unshaded | ||
- map: [ "clownedon" ] | ||
sprite: "_NF/Effects/creampie_64.rsi" | ||
state: "creampie_grimforged" | ||
visible: false | ||
- type: GenericVisualizer | ||
visuals: | ||
enum.CreamPiedVisuals.Creamed: | ||
clownedon: | ||
True: { visible: true } | ||
False: { visible: false } | ||
- type: AmbientSound | ||
volume: -6 | ||
range: 8 | ||
sound: | ||
path: /Audio/_NF/Ambience/force-field.ogg | ||
- type: CreamPied | ||
- type: DamageStateVisuals | ||
states: | ||
Alive: | ||
Base: move | ||
Critical: | ||
Base: dead | ||
Dead: | ||
Base: dead | ||
- type: MobThresholds | ||
thresholds: | ||
0: Alive | ||
50: Dead | ||
- type: HTN | ||
rootTask: | ||
task: SimpleRangedHostileCompound | ||
- type: Stamina | ||
critThreshold: 300 | ||
- type: HitscanBatteryAmmoProvider | ||
proto: RedLightLaser | ||
fireCost: 50 | ||
- type: BatterySelfRecharger | ||
autoRecharge: true | ||
autoRechargeRate: 50 | ||
- type: Battery | ||
maxCharge: 1000 | ||
startingCharge: 1000 | ||
- type: Gun | ||
fireRate: 1 | ||
useKey: false | ||
selectedMode: SemiAuto | ||
availableModes: | ||
- SemiAuto | ||
soundGunshot: /Audio/Weapons/Guns/Gunshots/laser_cannon.ogg |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file added
BIN
+2.41 KB
Resources/Textures/_NF/Effects/creampie_64.rsi/creampie_grimforged.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"version": 1, | ||
"license": "CC-BY-SA-3.0", | ||
"copyright": "Taken from https://github.com/tgstation/tgstation at 0d9c9a8233dfc3fc55edc538955a761a6328bee0. creampie_moth by MilenVolf, creampie_arachnid by PixelTheKermit (Github)", | ||
"size": { | ||
"x": 64, | ||
"y": 64 | ||
}, | ||
"states": [ | ||
{ | ||
"name": "creampie_grimforged" | ||
} | ||
] | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
71 changes: 71 additions & 0 deletions
71
Resources/Textures/_NF/Mobs/Aliens/grim_forged.rsi/meta.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
{ | ||
"version": 1, | ||
"size": { | ||
"x": 64, | ||
"y": 64 | ||
}, | ||
"license": "CC-BY-SA-3.0", | ||
"copyright": "Created by GreaseMonk for frontier-station-14, credit to MatthewBadger (discord) for original concepts and designs", | ||
"states": [ | ||
{ | ||
"name": "dead" | ||
}, | ||
{ | ||
"name": "off" | ||
}, | ||
{ | ||
"name": "move", | ||
"delays": [ | ||
[ | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06 | ||
] | ||
] | ||
}, | ||
{ | ||
"name": "flash", | ||
"delays": [ | ||
[ | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06, | ||
0.06 | ||
] | ||
] | ||
} | ||
] | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.