--- /dev/null
+namespace Content.Server.NPC.Queries.Considerations;
+
+/// <summary>
+/// Returns if the target is below a certain temperature.
+/// </summary>
+public sealed partial class TargetLowTempCon : UtilityConsideration
+{
+ /// <summary>
+ /// The minimum temperature they must be.
+ /// </summary>
+ [DataField]
+ public float MinTemp;
+}
+
using Content.Server.Nutrition.Components;
using Content.Server.Nutrition.EntitySystems;
using Content.Server.Storage.Components;
+using Content.Server.Temperature.Components;
using Content.Shared.Chemistry.EntitySystems;
using Content.Shared.Damage;
using Content.Shared.Examine;
using Content.Shared.Hands.Components;
using Content.Shared.Inventory;
using Content.Shared.Mobs;
-using Content.Shared.Mobs.Components;
using Content.Shared.Mobs.Systems;
using Content.Shared.NPC.Systems;
using Content.Shared.Nutrition.Components;
return 0f;
}
+ case TargetLowTempCon con:
+ {
+ if (!TryComp<TemperatureComponent>(targetUid, out var temperature))
+ return 0f;
+
+ return temperature.CurrentTemperature <= con.MinTemp ? 1f : 0f;
+ }
default:
throw new NotImplementedException();
}
table: !type:GroupSelector
children:
- id: MobGoliath
- weight: 65
+ weight: 45
- id: MobHivelord
weight: 35
-
+ - id: MobBasilisk
+ weight: 20
6
AggroVisionRadius: !type:Single
10
+ NavSmash: !type:Bool
+ true
- type: NPCUseActionOnTarget
actionId: ActionGoliathTentacle
- type: Tag
4
AggroVisionRadius: !type:Single
9
+ NavSmash: !type:Bool
+ true
- type: Butcherable
spawned:
- id: FoodHivelordRemains
15
AggroVisionRadius: !type:Single
15
+ NavSmash: !type:Bool
+ true
- type: TimedDespawn
lifetime: 100
- type: Tag
tags:
- HivelordRemains
+
+
+- type: entity
+ id: MobBasilisk
+ parent: [ BaseMobAsteroid, MobBloodstream ]
+ name: basilisk
+ description: A territorial beast, covered in a thick shell that absorbs energy. Its stare causes victims to freeze from the inside.
+ components:
+ - type: Sprite
+ sprite: Mobs/Aliens/Asteroid/basilisk.rsi
+ layers:
+ - map: ["enum.DamageStateVisualLayers.Base"]
+ state: basilisk
+ - type: DamageStateVisuals
+ states:
+ Alive:
+ Base: basilisk
+ Dead:
+ Base: basilisk_dead
+ - type: MovementSpeedModifier
+ baseWalkSpeed : 3
+ baseSprintSpeed : 3.5
+ - type: MobThresholds
+ thresholds:
+ 0: Alive
+ 80: Dead
+ - type: MeleeWeapon
+ angle: 0
+ animation: WeaponArcBite
+ soundHit:
+ path: /Audio/Effects/bite.ogg
+ damage:
+ types:
+ Slash: 7
+ Piercing: 5
+ - type: Gun
+ fireRate: 0.75
+ selectedMode: SemiAuto
+ showExamineText: false
+ availableModes: [ SemiAuto ]
+ soundGunshot: /Audio/Weapons/Guns/Gunshots/syringe_gun.ogg
+ - type: RechargeBasicEntityAmmo
+ showExamineText: false
+ rechargeCooldown: 0
+ rechargeSound: null
+ - type: BasicEntityAmmoProvider
+ proto: BasiliskRay
+ capacity: 1
+ count: 1
+ - type: Bloodstream
+ bloodMaxVolume: 200
+ chemicalMaxVolume: 0
+ - type: NpcFactionMember
+ factions:
+ - SimpleHostile
+ - type: HTN
+ rootTask:
+ task: BasiliskCompound
+ blackboard:
+ VisionRadius: !type:Single
+ 7
+ AggroVisionRadius: !type:Single
+ 12
+ NavSmash: !type:Bool
+ true
+ - type: Reflect
+ reflectProb: 1
+ reflects:
+ - Energy
+ - type: Butcherable
+ spawned:
+ - id: DiamondOre1
+ amount: 1
+ maxAmount: 3
- type: ChangeTemperatureOnCollide
heat: 100000 #This may be a bit underpowered, but in testing, 130000 was RIDICULOUS and killed in seconds.
+- type: entity
+ parent: BaseBullet
+ id: BasiliskRay
+ name: basilisk ray
+ categories: [ HideSpawnMenu ]
+ components:
+ - type: FlyBySound
+ sound:
+ collection: EnergyMiss
+ params:
+ volume: 5
+ - type: Sprite
+ sprite: Objects/Weapons/Guns/Projectiles/projectiles_tg.rsi
+ layers:
+ - state: ice
+ shader: unshaded
+ - type: Ammo
+ muzzleFlash: null
+ - type: Physics
+ - type: Fixtures
+ fixtures:
+ projectile:
+ shape:
+ !type:PhysShapeAabb
+ bounds: "-0.2,-0.2,0.2,0.2"
+ hard: false
+ mask:
+ - Opaque
+ fly-by: *flybyfixture
+ - type: Projectile
+ impactEffect: BulletImpactEffectDisabler
+ damage:
+ types:
+ Cold: 5
+ - type: TimedDespawn
+ lifetime: 3
+ - type: ChangeTemperatureOnCollide
+ heat: -50000
+
- type: entity
id: BulletKinetic
name: kinetic bolt
--- /dev/null
+- type: htnCompound
+ id: BasiliskCompound
+ branches:
+ - tasks:
+ - !type:HTNCompoundTask
+ task: BasiliskMeleeCombatCompound
+ - tasks:
+ - !type:HTNCompoundTask
+ task: InnateRangedCombatCompound
+ - tasks:
+ - !type:HTNCompoundTask
+ task: IdleCompound
+
+- type: htnCompound
+ id: BasiliskMeleeCombatCompound
+ branches:
+ - tasks:
+ - !type:HTNPrimitiveTask
+ operator: !type:UtilityOperator
+ proto: NearbyColdMeleeTargets
+ - !type:HTNCompoundTask
+ task: BeforeMeleeAttackTargetCompound
- !type:TargetInLOSOrCurrentCon
curve: !type:BoolCurve
+- type: utilityQuery
+ id: NearbyColdMeleeTargets
+ query:
+ - !type:NearbyHostilesQuery
+ considerations:
+ - !type:TargetLowTempCon
+ curve: !type:BoolCurve
+ minTemp: 250
+ - !type:TargetIsAliveCon
+ curve: !type:BoolCurve
+ - !type:TargetDistanceCon
+ curve: !type:PresetCurve
+ preset: TargetDistance
+ - !type:TargetHealthCon
+ curve: !type:PresetCurve
+ preset: TargetHealth
+ - !type:TargetAccessibleCon
+ curve: !type:BoolCurve
+ - !type:TargetInLOSOrCurrentCon
+ curve: !type:BoolCurve
+
- type: utilityQuery
id: OrderedTargets
query:
- !type:TargetIsCritCon
curve: !type:InverseBoolCurve
- !type:TargetIsStunnedCon
- curve: !type:InverseBoolCurve
+ curve: !type:InverseBoolCurve
- !type:TurretTargetingCon
curve: !type:BoolCurve
- !type:TargetDistanceCon
--- /dev/null
+{
+ "version": 1,
+ "license": "CC-BY-SA-3.0",
+ "copyright": "Taken from vgstation13 at https://github.com/vgstation-coders/vgstation13/blob/9bd459b27c73575fd5e3bf2efea13b816d0ac7c8/icons/mob/animal.dmi",
+ "size": {
+ "x": 32,
+ "y": 32
+ },
+ "states": [
+ {
+ "name": "basilisk",
+ "directions": 4
+ },
+ {
+ "name": "basilisk_alert",
+ "directions": 4,
+ "delays": [
+ [
+ 0.1,
+ 0.1,
+ 0.1,
+ 0.1
+ ],
+ [
+ 0.1,
+ 0.1,
+ 0.1,
+ 0.1
+ ],
+ [
+ 0.1,
+ 0.1,
+ 0.1,
+ 0.1
+ ],
+ [
+ 0.1,
+ 0.1,
+ 0.1,
+ 0.1
+ ]
+ ]
+ },
+ {
+ "name": "basilisk_dead"
+ }
+ ]
+}
},
{
"name": "heavylaser_flash"
+ },
+ {
+ "name": "ice"
}
]
-}
\ No newline at end of file
+}