Merge remote-tracking branch 'upstream/master'

This commit is contained in:
ShadowCommander
2019-08-10 15:46:57 -07:00
320 changed files with 2413 additions and 224 deletions

View File

@@ -0,0 +1,152 @@
using System;
using System.Collections.Generic;
using System.Runtime.CompilerServices;
using BenchmarkDotNet.Attributes;
using Robust.Shared.Maths;
using SysVector4 = System.Numerics.Vector4;
namespace Content.Benchmarks
{
public class ColorInterpolateBenchmark
{
private readonly List<(Color, Color)> _colors = new List<(Color, Color)>();
[Params(100)] public int N { get; set; }
[GlobalSetup]
public void Setup()
{
var random = new Random(3005);
for (var i = 0; i < N; i++)
{
var r1 = random.NextFloat();
var g1 = random.NextFloat();
var b1 = random.NextFloat();
var a1 = random.NextFloat();
var r2 = random.NextFloat();
var g2 = random.NextFloat();
var b2 = random.NextFloat();
var a2 = random.NextFloat();
_colors.Add((new Color(r1, g1, b1, a1), new Color(r2, g2, b2, a2)));
}
}
[Benchmark]
public void BenchSimple()
{
foreach (var (a, b) in _colors)
{
InterpolateSimple(a, b, 0.5f);
}
}
//[Benchmark]
public void BenchSysVector4()
{
foreach (var (a, b) in _colors)
{
InterpolateSysVector4(a, b, 0.5f);
}
}
//[Benchmark]
public void BenchSysVector4Blit()
{
foreach (var (a, b) in _colors)
{
InterpolateSysVector4Blit(a, b, 0.5f);
}
}
//[Benchmark]
public void BenchSysVector4BlitNoException()
{
foreach (var (a, b) in _colors)
{
InterpolateSysVector4BlitNoException(a, b, 0.5f);
}
}
[Benchmark]
public void BenchSysVector4AsRefNoException()
{
foreach (var (a, b) in _colors)
{
InterpolateSysVector4BlitNoExceptionAsRef(a, b, 0.5f);
}
}
public static Color InterpolateSimple(Color endPoint1, Color endPoint2, float lambda)
{
if (lambda < 0 || lambda > 1)
throw new ArgumentOutOfRangeException(nameof(lambda));
return new Color(
endPoint1.R * lambda + endPoint2.R * (1 - lambda),
endPoint1.G * lambda + endPoint2.G * (1 - lambda),
endPoint1.B * lambda + endPoint2.B * (1 - lambda),
endPoint1.A * lambda + endPoint2.A * (1 - lambda)
);
}
public static Color InterpolateSysVector4(Color endPoint1, Color endPoint2, float lambda)
{
if (lambda < 0 || lambda > 1)
throw new ArgumentOutOfRangeException(nameof(lambda));
var vec1 = new SysVector4(endPoint1.R, endPoint1.G, endPoint1.B, endPoint1.A);
var vec2 = new SysVector4(endPoint2.R, endPoint2.G, endPoint2.B, endPoint2.A);
var res = SysVector4.Lerp(vec1, vec2, 1 - lambda);
return new Color(
res.X, res.Y, res.Z, res.W);
}
public static unsafe Color InterpolateSysVector4Blit(in Color endPoint1, in Color endPoint2, float lambda)
{
if (lambda < 0 || lambda > 1)
throw new ArgumentOutOfRangeException(nameof(lambda));
fixed (Color* p1 = &endPoint1)
fixed (Color* p2 = &endPoint2)
{
var vp1 = (SysVector4*) p1;
var vp2 = (SysVector4*) p2;
var res = SysVector4.Lerp(*vp1, *vp2, 1 - lambda);
return *(Color*) (&res);
}
}
public static unsafe Color InterpolateSysVector4BlitNoException(in Color endPoint1, in Color endPoint2,
float lambda)
{
fixed (Color* p1 = &endPoint1)
fixed (Color* p2 = &endPoint2)
{
var vp1 = (SysVector4*) p1;
var vp2 = (SysVector4*) p2;
var res = SysVector4.Lerp(*vp2, *vp1, lambda);
return *(Color*) (&res);
}
}
public static unsafe Color InterpolateSysVector4BlitNoExceptionAsRef(in Color endPoint1, in Color endPoint2,
float lambda)
{
ref var sv1 = ref Unsafe.As<Color, SysVector4>(ref Unsafe.AsRef(endPoint1));
ref var sv2 = ref Unsafe.As<Color, SysVector4>(ref Unsafe.AsRef(endPoint2));
var res = SysVector4.Lerp(sv2, sv1, lambda);
return Unsafe.As<SysVector4, Color>(ref res);
}
}
}

View File

@@ -8,6 +8,8 @@
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
<Platforms>x64</Platforms>
<OutputType>Exe</OutputType>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<LangVersion>7.3</LangVersion>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="BenchmarkDotNet" Version="0.11.5" />

View File

@@ -1,9 +1,8 @@
using BenchmarkDotNet.Configs;
using BenchmarkDotNet.Running;
using BenchmarkDotNet.Running;
namespace Content.Benchmarks
{
internal class Program
internal static class Program
{
public static void Main(string[] args)
{

View File

@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Globalization;
using Nett;
using SixLabors.ImageSharp;
@@ -7,9 +8,9 @@ using SixLabors.ImageSharp.PixelFormats;
using SixLabors.Primitives;
using Robust.Client.Utility;
using Robust.Shared.Interfaces.Log;
using Robust.Shared.Log;
using Robust.Shared.Maths;
using Robust.Shared.Noise;
using SixLabors.ImageSharp.Advanced;
using BlendFactor = Robust.Shared.Maths.Color.BlendFactor;
namespace Content.Client.Parallax
@@ -24,6 +25,9 @@ namespace Content.Client.Parallax
var generator = new ParallaxGenerator();
generator._loadConfig(config);
sawmill.Debug("Timing start!");
var sw = new Stopwatch();
sw.Start();
var image = new Image<Rgba32>(Configuration.Default, size.Width, size.Height, Rgba32.Black);
var count = 0;
foreach (var layer in generator.Layers)
@@ -32,6 +36,9 @@ namespace Content.Client.Parallax
sawmill.Debug("Layer {0} done!", count++);
}
sw.Stop();
sawmill.Debug("Total time: {0}", sw.Elapsed.TotalSeconds);
return image;
}
@@ -69,12 +76,12 @@ namespace Content.Client.Parallax
private readonly Color OuterColor = Color.Black;
private readonly NoiseGenerator.NoiseType NoiseType = NoiseGenerator.NoiseType.Fbm;
private readonly uint Seed = 1234;
private readonly double Persistence = 0.5;
private readonly double Lacunarity = Math.PI * 2 / 3;
private readonly double Frequency = 1;
private readonly float Persistence = 0.5f;
private readonly float Lacunarity = (float) (Math.PI * 2 / 3);
private readonly float Frequency = 1;
private readonly uint Octaves = 3;
private readonly double Threshold;
private readonly double Power = 1;
private readonly float Threshold;
private readonly float Power = 1;
private readonly BlendFactor SrcFactor = BlendFactor.One;
private readonly BlendFactor DstFactor = BlendFactor.One;
@@ -97,17 +104,17 @@ namespace Content.Client.Parallax
if (table.TryGetValue("persistence", out tomlObject))
{
Persistence = double.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
Persistence = float.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
}
if (table.TryGetValue("lacunarity", out tomlObject))
{
Lacunarity = double.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
Lacunarity = float.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
}
if (table.TryGetValue("frequency", out tomlObject))
{
Frequency = double.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
Frequency = float.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
}
if (table.TryGetValue("octaves", out tomlObject))
@@ -117,7 +124,7 @@ namespace Content.Client.Parallax
if (table.TryGetValue("threshold", out tomlObject))
{
Threshold = double.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
Threshold = float.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
}
if (table.TryGetValue("sourcefactor", out tomlObject))
@@ -132,7 +139,7 @@ namespace Content.Client.Parallax
if (table.TryGetValue("power", out tomlObject))
{
Power = double.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
Power = float.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
}
if (table.TryGetValue("noise_type", out tomlObject))
@@ -163,9 +170,12 @@ namespace Content.Client.Parallax
noise.SetPeriodY(bitmap.Height);
var threshVal = 1 / (1 - Threshold);
var powFactor = 1 / Power;
for (var x = 0; x < bitmap.Width; x++)
var span = bitmap.GetPixelSpan();
for (var y = 0; y < bitmap.Height; y++)
{
for (var y = 0; y < bitmap.Height; y++)
for (var x = 0; x < bitmap.Width; x++)
{
// Do noise calculations.
var noiseVal = Math.Min(1, Math.Max(0, (noise.GetNoiseTiled(x, y) + 1) / 2));
@@ -173,15 +183,16 @@ namespace Content.Client.Parallax
// Threshold
noiseVal = Math.Max(0, noiseVal - Threshold);
noiseVal *= threshVal;
noiseVal = Math.Pow(noiseVal, powFactor);
noiseVal = (float) Math.Pow(noiseVal, powFactor);
// Get colors based on noise values.
var srcColor = Color.InterpolateBetween(InnerColor, OuterColor, (float) noiseVal)
.WithAlpha((float) noiseVal);
var srcColor = Color.InterpolateBetween(OuterColor, InnerColor, noiseVal)
.WithAlpha(noiseVal);
// Apply blending factors & write back.
var dstColor = bitmap[x, y].ConvertImgSharp();
bitmap[x, y] = Color.Blend(dstColor, srcColor, DstFactor, SrcFactor).ConvertImgSharp();
var i = y * bitmap.Width + x;
var dstColor = span[i].ConvertImgSharp();
span[i] = Color.Blend(dstColor, srcColor, DstFactor, SrcFactor).ConvertImgSharp();
}
}
}
@@ -202,13 +213,13 @@ namespace Content.Client.Parallax
private readonly bool Masked;
private readonly NoiseGenerator.NoiseType MaskNoiseType = NoiseGenerator.NoiseType.Fbm;
private readonly uint MaskSeed = 1234;
private readonly double MaskPersistence = 0.5;
private readonly double MaskLacunarity = Math.PI * 2 / 3;
private readonly double MaskFrequency = 1;
private readonly float MaskPersistence = 0.5f;
private readonly float MaskLacunarity = (float) Math.PI * 2 / 3;
private readonly float MaskFrequency = 1;
private readonly uint MaskOctaves = 3;
private readonly double MaskThreshold;
private readonly float MaskThreshold;
private readonly int PointSize = 1;
private readonly double MaskPower = 1;
private readonly float MaskPower = 1;
public LayerPoints(TomlTable table)
@@ -261,17 +272,17 @@ namespace Content.Client.Parallax
if (table.TryGetValue("maskpersistence", out tomlObject))
{
MaskPersistence = double.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
MaskPersistence = float.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
}
if (table.TryGetValue("masklacunarity", out tomlObject))
{
MaskLacunarity = double.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
MaskLacunarity = float.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
}
if (table.TryGetValue("maskfrequency", out tomlObject))
{
MaskFrequency = double.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
MaskFrequency = float.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
}
if (table.TryGetValue("maskoctaves", out tomlObject))
@@ -281,7 +292,7 @@ namespace Content.Client.Parallax
if (table.TryGetValue("maskthreshold", out tomlObject))
{
MaskThreshold = double.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
MaskThreshold = float.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
}
if (table.TryGetValue("masknoise_type", out tomlObject))
@@ -301,7 +312,7 @@ namespace Content.Client.Parallax
if (table.TryGetValue("maskpower", out tomlObject))
{
MaskPower = double.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
MaskPower = float.Parse(tomlObject.Get<string>(), CultureInfo.InvariantCulture);
}
}
@@ -319,14 +330,22 @@ namespace Content.Client.Parallax
GenPoints(buffer);
}
for (var x = 0; x < bitmap.Width; x++)
{
for (var y = 0; y < bitmap.Height; y++)
{
var dstColor = bitmap[x, y].ConvertImgSharp();
var srcColor = buffer[x, y].ConvertImgSharp();
var srcSpan = buffer.GetPixelSpan();
var dstSpan = bitmap.GetPixelSpan();
bitmap[x, y] = Color.Blend(dstColor, srcColor, DstFactor, SrcFactor).ConvertImgSharp();
var width = bitmap.Width;
var height = bitmap.Height;
for (var y = 0; y < height; y++)
{
for (var x = 0; x < width; x++)
{
var i = y * width + x;
var dstColor = dstSpan[i].ConvertImgSharp();
var srcColor = srcSpan[i].ConvertImgSharp();
dstSpan[i] = Color.Blend(dstColor, srcColor, DstFactor, SrcFactor).ConvertImgSharp();
}
}
}
@@ -335,28 +354,30 @@ namespace Content.Client.Parallax
{
var o = PointSize - 1;
var random = new Random(Seed);
var span = buffer.GetPixelSpan();
for (var i = 0; i < PointCount; i++)
{
var relX = random.NextDouble();
var relY = random.NextDouble();
var x = random.Next(0, buffer.Width);
var y = random.Next(0, buffer.Height);
var x = (int) (relX * buffer.Width);
var y = (int) (relY * buffer.Height);
var dist = random.NextFloat();
var dist = random.NextDouble();
for (var ox = x - o; ox <= x + o; ox++)
for (var oy = y - o; oy <= y + o; oy++)
{
for (var oy = y - o; oy <= y + o; oy++)
for (var ox = x - o; ox <= x + o; ox++)
{
var color = Color.InterpolateBetween(FarColor, CloseColor, (float) dist).ConvertImgSharp();
buffer[MathHelper.Mod(ox, buffer.Width), MathHelper.Mod(oy, buffer.Width)] = color;
var ix = MathHelper.Mod(ox, buffer.Width);
var iy = MathHelper.Mod(oy, buffer.Height);
var color = Color.InterpolateBetween(FarColor, CloseColor, dist).ConvertImgSharp();
span[iy * buffer.Width + ix] = color;
}
}
}
}
void GenPointsMasked(Image<Rgba32> buffer)
private void GenPointsMasked(Image<Rgba32> buffer)
{
var o = PointSize - 1;
var random = new Random(Seed);
@@ -375,22 +396,21 @@ namespace Content.Client.Parallax
const int maxPointAttemptCount = 9999;
var pointAttemptCount = 0;
var span = buffer.GetPixelSpan();
for (var i = 0; i < PointCount; i++)
{
var relX = random.NextDouble();
var relY = random.NextDouble();
var x = (int) (relX * buffer.Width);
var y = (int) (relY * buffer.Height);
var x = random.Next(0, buffer.Width);
var y = random.Next(0, buffer.Height);
// Grab noise at this point.
var noiseVal = Math.Min(1, Math.Max(0, (noise.GetNoiseTiled(x, y) + 1) / 2));
// Threshold
noiseVal = Math.Max(0, noiseVal - MaskThreshold);
noiseVal *= threshVal;
noiseVal = Math.Pow(noiseVal, powFactor);
noiseVal = (float) Math.Pow(noiseVal, powFactor);
var randomThresh = random.NextDouble();
var randomThresh = random.NextFloat();
if (randomThresh > noiseVal)
{
if (++pointAttemptCount <= maxPointAttemptCount)
@@ -401,14 +421,17 @@ namespace Content.Client.Parallax
continue;
}
var dist = random.NextDouble();
var dist = random.NextFloat();
for (var ox = x - o; ox <= x + o; ox++)
for (var oy = y - o; oy <= y + o; oy++)
{
for (var oy = y - o; oy <= y + o; oy++)
for (var ox = x - o; ox <= x + o; ox++)
{
var color = Color.InterpolateBetween(FarColor, CloseColor, (float) dist).ConvertImgSharp();
buffer[MathHelper.Mod(ox, buffer.Width), MathHelper.Mod(oy, buffer.Height)] = color;
var ix = MathHelper.Mod(ox, buffer.Width);
var iy = MathHelper.Mod(oy, buffer.Height);
var color = Color.InterpolateBetween(FarColor, CloseColor, dist).ConvertImgSharp();
span[iy * buffer.Width + ix] = color;
}
}
}

View File

@@ -29,5 +29,5 @@
<PropertyGroup>
<RobustToolsPath>..\RobustToolbox\Tools\</RobustToolsPath>
</PropertyGroup>
<Target Name="RobustAfterBuild" DependsOnTargets="CopySS14Noise;CopyMiscDependencies;CopySwnfd" AfterTargets="Build" />
<Target Name="RobustAfterBuild" DependsOnTargets="CopyMiscDependencies;CopySwnfd" AfterTargets="Build" />
</Project>

View File

@@ -20,9 +20,11 @@ namespace Content.Server.AI
[AiLogicProcessor("AimShootLife")]
class AimShootLifeProcessor : AiLogicProcessor
{
private readonly IPhysicsManager _physMan;
private readonly IServerEntityManager _entMan;
private readonly IGameTiming _timeMan;
#pragma warning disable 649
[Dependency] private readonly IPhysicsManager _physMan;
[Dependency] private readonly IServerEntityManager _entMan;
[Dependency] private readonly IGameTiming _timeMan;
#pragma warning restore 649
private readonly List<IEntity> _workList = new List<IEntity>();
@@ -32,16 +34,6 @@ namespace Content.Server.AI
private IEntity _curTarget;
/// <summary>
/// Creates an instance of this LogicProcessor.
/// </summary>
public AimShootLifeProcessor()
{
_physMan = IoCManager.Resolve<IPhysicsManager>();
_entMan = IoCManager.Resolve<IServerEntityManager>();
_timeMan = IoCManager.Resolve<IGameTiming>();
}
/// <inheritdoc />
public override void Update(float frameTime)
{

View File

@@ -0,0 +1,71 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Content.Server.Interfaces.Chat;
using JetBrains.Annotations;
using Robust.Server.AI;
using Robust.Shared.Interfaces.Timing;
using Robust.Shared.IoC;
using Robust.Shared.Utility;
namespace Content.Server.AI
{
/// <summary>
/// Designed for a a stationary entity that regularly advertises things (vending machine).
/// </summary>
[AiLogicProcessor("StaticBarker")]
class StaticBarkerProcessor : AiLogicProcessor
{
#pragma warning disable 649
[Dependency] private readonly IGameTiming _timeMan;
[Dependency] private readonly IChatManager _chatMan;
#pragma warning restore 649
private static readonly TimeSpan MinimumDelay = TimeSpan.FromSeconds(15);
private TimeSpan _nextBark;
private static List<string> slogans = new List<string>
{
"Come try my great products today!",
"More value for the way you live.",
"Quality you'd expect at prices you wouldn't.",
"The right stuff. The right price.",
};
public override void Update(float frameTime)
{
if(_timeMan.CurTime < _nextBark)
return;
var rngState = GenSeed();
_nextBark = _timeMan.CurTime + MinimumDelay + TimeSpan.FromSeconds(Random01(ref rngState) * 10);
var pick = (int)Math.Round(Random01(ref rngState) * (slogans.Count - 1));
_chatMan.EntitySay(SelfEntity, slogans[pick]);
}
private uint GenSeed()
{
return RotateRight((uint)_timeMan.CurTick.GetHashCode(), 11) ^ (uint)SelfEntity.Uid.GetHashCode();
}
private uint RotateRight(uint n, int s)
{
return (n << (32 - s)) | (n >> s);
}
private float Random01(ref uint state)
{
DebugTools.Assert(state != 0);
//xorshift32
state ^= state << 13;
state ^= state >> 17;
state ^= state << 5;
return state / (float)uint.MaxValue;
}
}
}

View File

@@ -0,0 +1,249 @@
using System;
using System.Collections.Generic;
using Content.Server.GameObjects.Components.Movement;
using Content.Server.GameObjects.EntitySystems;
using Content.Server.Interfaces.Chat;
using Content.Shared.Physics;
using Robust.Server.AI;
using Robust.Server.Interfaces.GameObjects;
using Robust.Shared.GameObjects;
using Robust.Shared.Interfaces.GameObjects;
using Robust.Shared.Interfaces.Physics;
using Robust.Shared.Interfaces.Timing;
using Robust.Shared.IoC;
using Robust.Shared.Maths;
using Robust.Shared.Utility;
namespace Content.Server.AI
{
/// <summary>
/// Designed to control a mob. The mob will wander around, then idle at a the destination for awhile.
/// </summary>
[AiLogicProcessor("Wander")]
class WanderProcessor : AiLogicProcessor
{
#pragma warning disable 649
[Dependency] private readonly IPhysicsManager _physMan;
[Dependency] private readonly IServerEntityManager _entMan;
[Dependency] private readonly IGameTiming _timeMan;
[Dependency] private readonly IEntitySystemManager _entSysMan;
[Dependency] private readonly IChatManager _chatMan;
#pragma warning restore 649
private static readonly TimeSpan IdleTimeSpan = TimeSpan.FromSeconds(1);
private static readonly TimeSpan WalkingTimeout = TimeSpan.FromSeconds(3);
private static readonly TimeSpan DisabledTimeout = TimeSpan.FromSeconds(10);
private static List<string> _normalAssistantConversation = new List<string>
{
"stat me",
"roll it easy!",
"waaaaaagh!!!",
"red wonz go fasta",
"FOR TEH EMPRAH",
"lol2cat",
"dem dwarfs man, dem dwarfs",
"SPESS MAHREENS",
"hwee did eet fhor khayosss",
"lifelike texture ;_;",
"luv can bloooom",
"PACKETS!!!",
"SARAH HALE DID IT!!!",
"Don't tell Chase",
"not so tough now huh",
"WERE NOT BAY!!",
"IF YOU DONT LIKE THE CYBORGS OR SLIMES WHY DONT YU O JUST MAKE YORE OWN!",
"DONT TALK TO ME ABOUT BALANCE!!!!",
"YOU AR JUS LAZY AND DUMB JAMITORS AND SERVICE ROLLS",
"BLAME HOSHI!!!",
"ARRPEE IZ DED!!!",
"THERE ALL JUS MEATAFRIENDS!",
"SOTP MESING WITH THE ROUNS SHITMAN!!!",
"SKELINGTON IS 4 SHITERS!",
"MOMMSI R THE WURST SCUM!!",
"How do we engiener=",
"try to live freely and automatically good bye",
"why woud i take a pin pointner??",
"How do I set up the. SHow do I set u p the Singu. how I the scrungularity????",
};
private const float MaxWalkDistance = 3; // meters
private const float AdditionalIdleTime = 2; // 0 to this many more seconds
private FsmState _CurrentState;
private TimeSpan _startStateTime;
private Vector2 _walkTargetPos;
public override void Update(float frameTime)
{
if (SelfEntity == null)
return;
ProcessState();
}
private void ProcessState()
{
switch (_CurrentState)
{
case FsmState.None:
_CurrentState = FsmState.Idle;
break;
case FsmState.Idle:
IdleState();
break;
case FsmState.Walking:
WalkingState();
break;
case FsmState.Disabled:
DisabledState();
break;
}
}
private void IdlePositiveEdge(ref uint rngState)
{
_startStateTime = _timeMan.CurTime + IdleTimeSpan + TimeSpan.FromSeconds(Random01(ref rngState) * AdditionalIdleTime);
_CurrentState = FsmState.Idle;
EmitProfanity(ref rngState);
}
private void IdleState()
{
if (!ActionBlockerSystem.CanMove(SelfEntity))
{
DisabledPositiveEdge();
return;
}
if (_timeMan.CurTime < _startStateTime + IdleTimeSpan)
return;
var entWorldPos = SelfEntity.Transform.WorldPosition;
if (SelfEntity.TryGetComponent<BoundingBoxComponent>(out var bounds))
entWorldPos = bounds.WorldAABB.Center;
var rngState = GenSeed();
for (var i = 0; i < 3; i++) // you get 3 chances to find a place to walk
{
var dir = new Vector2(Random01(ref rngState) * 2 - 1, Random01(ref rngState) *2 -1);
var ray = new Ray(entWorldPos, dir, (int) CollisionGroup.Grid);
var rayResult = _physMan.IntersectRay(ray, MaxWalkDistance, SelfEntity);
if (rayResult.DidHitObject && rayResult.Distance > 1) // hit an impassable object
{
// set the new position back from the wall a bit
_walkTargetPos = entWorldPos + dir * (rayResult.Distance - 0.5f);
WalkingPositiveEdge();
return;
}
if (!rayResult.DidHitObject) // hit nothing (path clear)
{
_walkTargetPos = dir * MaxWalkDistance;
WalkingPositiveEdge();
return;
}
}
// can't find clear spot, do nothing, sleep longer
_startStateTime = _timeMan.CurTime;
}
private void WalkingPositiveEdge()
{
_startStateTime = _timeMan.CurTime;
_CurrentState = FsmState.Walking;
}
private void WalkingState()
{
var rngState = GenSeed();
if (_timeMan.CurTime > _startStateTime + WalkingTimeout) // walked too long, go idle
{
IdlePositiveEdge(ref rngState);
return;
}
var targetDiff = _walkTargetPos - SelfEntity.Transform.WorldPosition;
if (targetDiff.LengthSquared < 0.1) // close enough
{
// stop walking
if (SelfEntity.TryGetComponent<AiControllerComponent>(out var mover))
{
mover.VelocityDir = Vector2.Zero;
}
IdlePositiveEdge(ref rngState);
return;
}
// continue walking
if (SelfEntity.TryGetComponent<AiControllerComponent>(out var moverTwo))
{
moverTwo.VelocityDir = targetDiff.Normalized;
}
}
private void DisabledPositiveEdge()
{
_startStateTime = _timeMan.CurTime;
_CurrentState = FsmState.Disabled;
}
private void DisabledState()
{
if(_timeMan.CurTime < _startStateTime + DisabledTimeout)
return;
if (ActionBlockerSystem.CanMove(SelfEntity))
{
var rngState = GenSeed();
IdlePositiveEdge(ref rngState);
}
else
DisabledPositiveEdge();
}
private void EmitProfanity(ref uint rngState)
{
if(Random01(ref rngState) < 0.5f)
return;
var pick = (int) Math.Round(Random01(ref rngState) * (_normalAssistantConversation.Count - 1));
_chatMan.EntitySay(SelfEntity, _normalAssistantConversation[pick]);
}
private uint GenSeed()
{
return RotateRight((uint)_timeMan.CurTick.GetHashCode(), 11) ^ (uint)SelfEntity.Uid.GetHashCode();
}
private uint RotateRight(uint n, int s)
{
return (n << (32 - s)) | (n >> s);
}
private float Random01(ref uint state)
{
DebugTools.Assert(state != 0);
//xorshift32
state ^= state << 13;
state ^= state >> 17;
state ^= state << 5;
return state / (float)uint.MaxValue;
}
private enum FsmState
{
None,
Idle,
Walking,
Disabled
}
}
}

View File

@@ -1,11 +1,15 @@
using Content.Server.Interfaces.GameObjects.Components.Movement;
using Robust.Server.AI;
using Robust.Server.GameObjects;
using Robust.Shared.GameObjects;
using Robust.Shared.Map;
using Robust.Shared.Maths;
using Robust.Shared.Serialization;
using Robust.Shared.ViewVariables;
namespace Content.Server.GameObjects.Components.Movement
{
[RegisterComponent]
[RegisterComponent, ComponentReference(typeof(IMoverComponent))]
public class AiControllerComponent : Component, IMoverComponent
{
private string _logicName;
@@ -13,15 +17,37 @@ namespace Content.Server.GameObjects.Components.Movement
public override string Name => "AiController";
public string LogicName => _logicName;
[ViewVariables(VVAccess.ReadWrite)]
public string LogicName
{
get => _logicName;
set
{
_logicName = value;
Processor = null;
}
}
public AiLogicProcessor Processor { get; set; }
[ViewVariables(VVAccess.ReadWrite)]
public float VisionRadius
{
get => _visionRadius;
set => _visionRadius = value;
}
/// <inheritdoc />
public override void Initialize()
{
base.Initialize();
// This component requires a physics component.
if (!Owner.HasComponent<PhysicsComponent>())
Owner.AddComponent<PhysicsComponent>();
}
/// <inheritdoc />
public override void ExposeData(ObjectSerializer serializer)
{
base.ExposeData(serializer);
@@ -29,5 +55,34 @@ namespace Content.Server.GameObjects.Components.Movement
serializer.DataField(ref _logicName, "logic", null);
serializer.DataField(ref _visionRadius, "vision", 8.0f);
}
/// <summary>
/// Movement speed (m/s) that the entity walks.
/// </summary>
[ViewVariables(VVAccess.ReadWrite)]
public float WalkMoveSpeed { get; set; } = 4.0f;
/// <summary>
/// Movement speed (m/s) that the entity sprints.
/// </summary>
[ViewVariables(VVAccess.ReadWrite)]
public float SprintMoveSpeed { get; set; } = 10.0f;
/// <summary>
/// Is the entity Sprinting (running)?
/// </summary>
[ViewVariables]
public bool Sprinting { get; set; }
/// <summary>
/// Calculated linear velocity direction of the entity.
/// </summary>
[ViewVariables]
public Vector2 VelocityDir { get; set; }
public GridCoordinates LastPosition { get; set; }
[ViewVariables(VVAccess.ReadWrite)]
public float StepSoundDistance { get; set; }
}
}

View File

@@ -1,10 +1,14 @@
using System;
using System.Collections.Generic;
using Content.Server.GameObjects.Components.Movement;
using Content.Server.Interfaces.GameObjects.Components.Movement;
using Robust.Server.AI;
using Robust.Server.Interfaces.Console;
using Robust.Server.Interfaces.Player;
using Robust.Server.Interfaces.Timing;
using Robust.Shared.GameObjects;
using Robust.Shared.GameObjects.Systems;
using Robust.Shared.Interfaces.GameObjects;
using Robust.Shared.Interfaces.Reflection;
using Robust.Shared.IoC;
@@ -12,17 +16,23 @@ namespace Content.Server.GameObjects.EntitySystems
{
internal class AiSystem : EntitySystem
{
private readonly Dictionary<string, Type> _processorTypes = new Dictionary<string, Type>();
private IPauseManager _pauseManager;
#pragma warning disable 649
[Dependency] private readonly IPauseManager _pauseManager;
[Dependency] private readonly IDynamicTypeFactory _typeFactory;
[Dependency] private readonly IReflectionManager _reflectionManager;
#pragma warning restore 649
public AiSystem()
private readonly Dictionary<string, Type> _processorTypes = new Dictionary<string, Type>();
/// <inheritdoc />
public override void Initialize()
{
base.Initialize();
// register entity query
EntityQuery = new TypeEntityQuery(typeof(AiControllerComponent));
_pauseManager = IoCManager.Resolve<IPauseManager>();
var reflectionMan = IoCManager.Resolve<IReflectionManager>();
var processors = reflectionMan.GetAllChildren<AiLogicProcessor>();
var processors = _reflectionManager.GetAllChildren<AiLogicProcessor>();
foreach (var processor in processors)
{
var att = (AiLogicProcessorAttribute)Attribute.GetCustomAttribute(processor, typeof(AiLogicProcessorAttribute));
@@ -33,6 +43,7 @@ namespace Content.Server.GameObjects.EntitySystems
}
}
/// <inheritdoc />
public override void Update(float frameTime)
{
var entities = EntityManager.GetEntities(EntityQuery);
@@ -61,11 +72,45 @@ namespace Content.Server.GameObjects.EntitySystems
{
if (_processorTypes.TryGetValue(name, out var type))
{
return (AiLogicProcessor)Activator.CreateInstance(type);
return (AiLogicProcessor)_typeFactory.CreateInstance(type);
}
// processor needs to inherit AiLogicProcessor, and needs an AiLogicProcessorAttribute to define the YAML name
throw new ArgumentException($"Processor type {name} could not be found.", nameof(name));
}
private class AddAiCommand : IClientCommand
{
public string Command => "addai";
public string Description => "Add an ai component with a given processor to an entity.";
public string Help => "addai <processorId> <entityId>";
public void Execute(IConsoleShell shell, IPlayerSession player, string[] args)
{
if(args.Length != 2)
{
shell.SendText(player, "Wrong number of args.");
return;
}
var processorId = args[0];
var entId = new EntityUid(int.Parse(args[1]));
var ent = IoCManager.Resolve<IEntityManager>().GetEntity(entId);
if (ent.HasComponent<AiControllerComponent>())
{
shell.SendText(player, "Entity already has an AI component.");
return;
}
if (ent.HasComponent<IMoverComponent>())
{
ent.RemoveComponent<IMoverComponent>();
}
var comp = ent.AddComponent<AiControllerComponent>();
comp.LogicName = processorId;
shell.SendText(player, "AI component added.");
}
}
}
}

View File

@@ -23,6 +23,7 @@ using Robust.Shared.Players;
using Robust.Shared.Prototypes;
using Content.Server.GameObjects.Components.Sound;
using Content.Shared.GameObjects.Components.Inventory;
using Robust.Shared.Log;
namespace Content.Server.GameObjects.EntitySystems
{
@@ -45,7 +46,7 @@ namespace Content.Server.GameObjects.EntitySystems
/// <inheritdoc />
public override void Initialize()
{
EntityQuery = new TypeEntityQuery(typeof(PlayerInputMoverComponent));
EntityQuery = new TypeEntityQuery(typeof(IMoverComponent));
var moveUpCmdHandler = InputCmdHandler.FromDelegate(
session => HandleDirChange(session, Direction.North, true),
@@ -116,14 +117,14 @@ namespace Content.Server.GameObjects.EntitySystems
{
continue;
}
var mover = entity.GetComponent<PlayerInputMoverComponent>();
var mover = entity.GetComponent<IMoverComponent>();
var physics = entity.GetComponent<PhysicsComponent>();
UpdateKinematics(entity.Transform, mover, physics);
}
}
private void UpdateKinematics(ITransformComponent transform, PlayerInputMoverComponent mover, PhysicsComponent physics)
private void UpdateKinematics(ITransformComponent transform, IMoverComponent mover, PhysicsComponent physics)
{
if (mover.VelocityDir.LengthSquared < 0.001 || !ActionBlockerSystem.CanMove(mover.Owner))
{
@@ -234,9 +235,17 @@ namespace Content.Server.GameObjects.EntitySystems
}
// Ok well we know the position of the
var soundCollection = _prototypeManager.Index<SoundCollectionPrototype>(soundCollectionName);
var file = _footstepRandom.Pick(soundCollection.PickFiles);
_audioSystem.Play(file, coordinates);
try
{
var soundCollection = _prototypeManager.Index<SoundCollectionPrototype>(soundCollectionName);
var file = _footstepRandom.Pick(soundCollection.PickFiles);
_audioSystem.Play(file, coordinates);
}
catch (UnknownPrototypeException)
{
// Shouldn't crash over a sound
Logger.ErrorS("sound", $"Unable to find sound collection for {soundCollectionName}");
}
}
}
}

View File

@@ -1,4 +1,6 @@
using Robust.Shared.Interfaces.GameObjects;
using Robust.Shared.Interfaces.GameObjects;
using Robust.Shared.Map;
using Robust.Shared.Maths;
namespace Content.Server.Interfaces.GameObjects.Components.Movement
{
@@ -6,6 +8,28 @@ namespace Content.Server.Interfaces.GameObjects.Components.Movement
// There can only be one.
public interface IMoverComponent : IComponent
{
/// <summary>
/// Movement speed (m/s) that the entity walks.
/// </summary>
float WalkMoveSpeed { get; set; }
/// <summary>
/// Movement speed (m/s) that the entity sprints.
/// </summary>
float SprintMoveSpeed { get; set; }
/// <summary>
/// Is the entity Sprinting (running)?
/// </summary>
bool Sprinting { get; set; }
/// <summary>
/// Calculated linear velocity direction of the entity.
/// </summary>
Vector2 VelocityDir { get; }
GridCoordinates LastPosition { get; set; }
float StepSoundDistance { get; set; }
}
}

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -5,7 +5,7 @@ meta:
postmapinit: false
tilemap:
0: space
1: floor
1: floor_steel
2: floor_techmaint
3: floor_white
4: plating
@@ -99,112 +99,112 @@ entities:
pos: 1.412994,7.507263
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 9
components:
- grid: 0
pos: -7.5,0.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 10
components:
- grid: 0
pos: -7.5,-0.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 11
components:
- grid: 0
pos: -7.5,-1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 12
components:
- grid: 0
pos: -7.5,-2.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 13
components:
- grid: 0
pos: -7.5,-3.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 14
components:
- grid: 0
pos: 0.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 15
components:
- grid: 0
pos: -0.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 16
components:
- grid: 0
pos: 3.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 17
components:
- grid: 0
pos: 4.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 18
components:
- grid: 0
pos: -7.5,-10.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 19
components:
- grid: 0
pos: -7.5,-11.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 20
components:
- grid: 0
pos: -7.5,-12.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 21
components:
- grid: 0
pos: -7.5,-13.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 22
components:
- grid: 0
pos: 2.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 23
components:
- grid: 0
pos: 1.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 24
components:
- grid: 0
@@ -271,266 +271,266 @@ entities:
pos: -6.5,-11.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 31
components:
- grid: 0
pos: -7.5,-9.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 32
components:
- grid: 0
pos: -10.5,-7.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 33
components:
- grid: 0
pos: -10.5,-6.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 34
components:
- grid: 0
pos: -10.5,-5.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 35
components:
- grid: 0
pos: -10.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 36
components:
- grid: 0
pos: -10.5,-3.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 37
components:
- grid: 0
pos: -10.5,-2.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 38
components:
- grid: 0
pos: -10.5,-1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 39
components:
- grid: 0
pos: -3.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 40
components:
- grid: 0
pos: 1.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 41
components:
- grid: 0
pos: 0.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 42
components:
- grid: 0
pos: -0.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 43
components:
- grid: 0
pos: -1.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 44
components:
- grid: 0
pos: -2.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 45
components:
- grid: 0
pos: -3.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 46
components:
- grid: 0
pos: -4.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 47
components:
- grid: 0
pos: -5.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 48
components:
- grid: 0
pos: -6.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 49
components:
- grid: 0
pos: 4.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 50
components:
- grid: 0
pos: 5.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 51
components:
- grid: 0
pos: 6.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 52
components:
- grid: 0
pos: -7.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 53
components:
- grid: 0
pos: -2.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 54
components:
- grid: 0
pos: -6.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 55
components:
- grid: 0
pos: -5.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 56
components:
- grid: 0
pos: -4.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 57
components:
- grid: 0
pos: 6.5,-10.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 58
components:
- grid: 0
pos: 6.5,-11.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 59
components:
- grid: 0
pos: 6.5,-12.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 60
components:
- grid: 0
pos: 6.5,-13.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 61
components:
- grid: 0
pos: 6.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 62
components:
- grid: 0
pos: 5.5,-14.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 63
components:
- grid: 0
pos: -7.5,-8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 64
components:
- grid: 0
pos: -7.5,-7.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 65
components:
- grid: 0
pos: -8.5,-8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 66
components:
- grid: 0
pos: -9.5,-8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 67
components:
- grid: 0
pos: -10.5,-8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 68
components:
- grid: 0
@@ -551,28 +551,28 @@ entities:
pos: -8.5,-6.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 71
components:
- grid: 0
pos: 5.5,-7.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 72
components:
- grid: 0
pos: 5.5,-9.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 73
components:
- grid: 0
pos: 6.5,-9.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 74
components:
- grid: 0
@@ -595,7 +595,7 @@ entities:
type: Transform
- load: 120
type: PowerProvider
- type: wall
- type: solid_wall
uid: 77
components:
- grid: 0
@@ -637,14 +637,14 @@ entities:
pos: 2.5,-4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 83
components:
- grid: 0
pos: 6.5,-6.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 84
components:
- grid: 0
@@ -1068,7 +1068,7 @@ entities:
pos: -0.5,-10.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 143
components:
- grid: 0
@@ -1593,14 +1593,14 @@ entities:
pos: -9.5,1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 229
components:
- grid: 0
pos: -10.5,-0.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 230
components:
- grid: 0
@@ -1983,7 +1983,7 @@ entities:
type: Transform
- load: 280
type: PowerProvider
- type: wall
- type: solid_wall
uid: 277
components:
- grid: 0
@@ -2146,287 +2146,287 @@ entities:
pos: -1.94591,7.485576
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 381
components:
- grid: 0
pos: -10.5,1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 382
components:
- grid: 0
pos: -11.5,4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 383
components:
- grid: 0
pos: -10.5,4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 384
components:
- grid: 0
pos: -9.5,4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 385
components:
- grid: 0
pos: -8.5,4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 386
components:
- grid: 0
pos: -7.5,4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 387
components:
- grid: 0
pos: -8.5,1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 388
components:
- grid: 0
pos: -5.5,1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 389
components:
- grid: 0
pos: -6.5,1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 390
components:
- grid: 0
pos: -7.5,1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 391
components:
- grid: 0
pos: -0.5,1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 392
components:
- grid: 0
pos: 0.5,1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 393
components:
- grid: 0
pos: 1.5,1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 394
components:
- grid: 0
pos: 1.5,0.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 395
components:
- grid: 0
pos: 1.5,-3.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 396
components:
- grid: 0
pos: 4.5,-3.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 397
components:
- grid: 0
pos: 4.5,-2.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 398
components:
- grid: 0
pos: 4.5,-1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 399
components:
- grid: 0
pos: 4.5,-0.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 400
components:
- grid: 0
pos: 4.5,0.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 401
components:
- grid: 0
pos: 4.5,1.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 402
components:
- grid: 0
pos: 4.5,2.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 403
components:
- grid: 0
pos: 4.5,3.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 404
components:
- grid: 0
pos: 4.5,4.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 405
components:
- grid: 0
pos: 4.5,5.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 406
components:
- grid: 0
pos: 4.5,6.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 407
components:
- grid: 0
pos: 4.5,7.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 408
components:
- grid: 0
pos: 4.5,8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 409
components:
- grid: 0
pos: 1.5,8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 410
components:
- grid: 0
pos: 0.5,8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 411
components:
- grid: 0
pos: -0.5,8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 412
components:
- grid: 0
pos: -1.5,8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 413
components:
- grid: 0
pos: -2.5,8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 414
components:
- grid: 0
pos: -3.5,8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 415
components:
- grid: 0
pos: -4.5,8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 416
components:
- grid: 0
pos: -5.5,8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 417
components:
- grid: 0
pos: -6.5,8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 418
components:
- grid: 0
pos: -7.5,8.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 419
components:
- grid: 0
pos: -7.5,7.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 420
components:
- grid: 0
pos: -7.5,6.5
rot: -1.5707963267949 rad
type: Transform
- type: wall
- type: solid_wall
uid: 421
components:
- grid: 0

View File

@@ -16,6 +16,7 @@
- type: Sprite
drawdepth: WallMountedItems
texture: Buildings/TurrTop.png
directional: false
- type: AiController
logic: AimShootLife
vision: 6.0
@@ -29,6 +30,7 @@
- type: Sprite
drawdepth: WallMountedItems
texture: Buildings/TurrLamp.png
directional: false
- type: AiController
logic: AimShootLife
vision: 6.0

View File

@@ -1,18 +1,13 @@
- type: entity
id: wall
name: Wall
id: base_wall
name: BaseWall
components:
- type: Clickable
- type: Sprite
netsync: false
color: "#71797a"
drawdepth: Walls
sprite: Buildings/wall.rsi
- type: Icon
sprite: Buildings/wall.rsi
state: full
- type: BoundingBox
- type: Collidable
- type: Damageable
@@ -28,7 +23,298 @@
- type: IconSmooth
key: walls
base: solid
placement:
snap:
- Wall
- type: entity
id: brick_wall
name: Brick wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/brick.rsi
- type: Icon
sprite: Buildings/Walls/brick.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: brick
- type: entity
id: clock_wall
name: Clock wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/clock.rsi
- type: Icon
sprite: Buildings/Walls/clock.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: clock
- type: entity
id: clown_wall
name: Clown wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/clown.rsi
- type: Icon
sprite: Buildings/Walls/clown.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: clown
- type: entity
id: cult_wall
name: Cult wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/cult.rsi
- type: Icon
sprite: Buildings/Walls/cult.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: cult
- type: entity
id: debug_wall
name: Debug wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/debug.rsi
- type: Icon
sprite: Buildings/Walls/debug.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: debug
- type: entity
id: diamond_wall
name: Diamond wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/diamond.rsi
- type: Icon
sprite: Buildings/Walls/diamond.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: diamond
- type: entity
id: gold_wall
name: Gold wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/gold.rsi
- type: Icon
sprite: Buildings/Walls/gold.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: gold
- type: entity
id: ice_wall
name: Ice wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/ice.rsi
- type: Icon
sprite: Buildings/Walls/ice.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: ice
- type: entity
id: metal_wall
name: Metal wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/metal.rsi
- type: Icon
sprite: Buildings/Walls/metal.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: metal
- type: entity
id: plasma_wall
name: Plasma wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/plasma.rsi
- type: Icon
sprite: Buildings/Walls/plasma.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: plasma
- type: entity
id: plastic_wall
name: Plastic wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/plastic.rsi
- type: Icon
sprite: Buildings/Walls/plastic.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: plastic
- type: entity
id: reinforced_wall
name: Reinforced wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/reinforced.rsi
- type: Icon
sprite: Buildings/Walls/reinforced.rsi
- type: Destructible
thresholdvalue: 300
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: reinforced
# Riveting
- type: entity
id: riveted_wall
name: Riveted wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/riveted.rsi
- type: Icon
sprite: Buildings/Walls/riveted.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: riveted
- type: entity
id: sandstone_wall
name: Sandstone wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/sandstone.rsi
- type: Icon
sprite: Buildings/Walls/sandstone.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: sandstone
- type: entity
id: silver_wall
name: Silver wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/silver.rsi
- type: Icon
sprite: Buildings/Walls/silver.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: silver
- type: entity
id: solid_wall
name: Solid wall
parent: base_wall
components:
- type: Sprite
color: "#71797a"
sprite: Buildings/Walls/solid.rsi
- type: Icon
sprite: Buildings/Walls/solid.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: solid
- type: entity
id: uranium_wall
name: Uranium wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/uranium.rsi
- type: Icon
sprite: Buildings/Walls/uranium.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: uranium
- type: entity
id: wood_wall
name: Wood wall
parent: base_wall
components:
- type: Sprite
sprite: Buildings/Walls/wood.rsi
- type: Icon
sprite: Buildings/Walls/wood.rsi
- type: Destructible
thresholdvalue: 100
spawnondestroy: girder
- type: IconSmooth
key: walls. Seriously, just a wall. Nothing extraordinary here.
base: wood

View File

@@ -24,3 +24,5 @@
sprite: Clothing/belt_utility.rsi
- type: Storage
Capacity: 30

View File

@@ -53,4 +53,19 @@
state: leather
- type: Clothing
sprite: Clothing/gloves_leather.rsi
HeatResistance: 1500
HeatResistance: 1500
- type: entity
parent: GlovesBase
id: WhiteGloves
name: White Gloves
description: These look pretty fancy.
components:
- type: Sprite
sprite: Clothing/gloves_white.rsi
state: white
- type: Icon
sprite: Clothing/gloves_white.rsi
state: white
- type: Clothing
sprite: Clothing/gloves_white.rsi

View File

@@ -0,0 +1,76 @@
- type: entity
parent: Clothing
id: HatBase
abstract: true
components:
- type: Clothing
Slots: [helmet]
- type: entity
parent: HatBase
id: HatChef
name: Chef's Hat
description: It's a hat used by chefs to keep hair out of your food. Judging by the food in the mess, they don't work.
components:
- type: Sprite
sprite: Clothing/chef_hat.rsi
state: chef
- type: Icon
sprite: Clothing/chef_hat.rsi
state: chef
- type: Clothing
sprite: Clothing/chef_hat.rsi
Slots:
- helmet
- type: entity
parent: HatBase
id: HatCaptain
name: Captain's Hat
description: It's good to be king.
components:
- type: Sprite
sprite: Clothing/captain_hat.rsi
state: captain
- type: Icon
sprite: Clothing/captain_hat.rsi
state: captain
- type: Clothing
sprite: Clothing/captain_hat.rsi
Slots:
- helmet
- type: entity
parent: HatBase
id: HatHOP
name: Head of Personnel's Hat
description: Papers, please.
components:
- type: Sprite
sprite: Clothing/hop_hat.rsi
state: hop
- type: Icon
sprite: Clothing/hop_hat.rsi
state: hop
- type: Clothing
sprite: Clothing/hop_hat.rsi
Slots:
- helmet
- type: entity
parent: HatBase
id: HatBeret
name: Beret
description: A beret, an artists favorite headwear.
components:
- type: Sprite
sprite: Clothing/beret.rsi
state: beret
- type: Icon
sprite: Clothing/beret.rsi
state: beret
- type: Clothing
sprite: Clothing/beret.rsi
Slots:
- helmet

View File

@@ -47,4 +47,19 @@
sprite: Clothing/mask_clown.rsi
state: icon
- type: Clothing
sprite: Clothing/mask_clown.rsi
sprite: Clothing/mask_clown.rsi
- type: entity
parent: MasksBase
id: MaskMime
name: Mime Mask
description: The traditional mime's mask. It has an eerie facial posture.
components:
- type: Sprite
sprite: Clothing/mask_mime.rsi
state: mime
- type: Icon
sprite: Clothing/mask_mime.rsi
state: mime
- type: Clothing
sprite: Clothing/mask_mime.rsi

View File

@@ -83,3 +83,38 @@
- type: Sound
- type: FootstepModifier
footstepSoundCollection: footstep_heavy
- type: entity
parent: ShoesBase
id: ShoesBrown
name: Brown Shoes
description: A pair of brown shoes.
components:
- type: Sprite
sprite: Clothing/shoes_brown.rsi
state: brown
- type: Icon
sprite: Clothing/shoes_brown.rsi
state: brown
- type: Clothing
sprite: Clothing/shoes_brown.rsi
- type: entity
parent: ShoesBase
id: ShoesMime
name: Mime Shoes
description: Comfortable-looking shoes.
components:
- type: Sprite
sprite: Clothing/shoes_mime.rsi
state: mime
- type: Icon
sprite: Clothing/shoes_mime.rsi
state: mime
- type: Clothing
sprite: Clothing/shoes_mime.rsi

View File

@@ -41,3 +41,35 @@
- type: Clothing
sprite: Clothing/vest_hazard.rsi
- type: entity
parent: SuitBase
id: ChefApronClothing
name: Chef's Apron
description: An apron used by a high class chef.
components:
- type: Sprite
sprite: Clothing/chef_apron.rsi
state: apron
- type: Icon
sprite: Clothing/chef_apron.rsi
state: apron
- type: Clothing
sprite: Clothing/chef_apron.rsi
- type: entity
parent: SuitBase
id: BeltSuspenders
name: Suspenders
description: They suspend the illusion of the mime's play.
components:
- type: Sprite
sprite: Clothing/suspenders.rsi
state: suspenders
- type: Icon
sprite: Clothing/suspenders.rsi
state: suspenders
- type: Clothing
sprite: Clothing/suspenders.rsi

View File

@@ -108,3 +108,71 @@
- type: Clothing
sprite: Clothing/uniform_sec.rsi
- type: entity
parent: UniformBase
id: UniformChef
name: Chef's Uniform
description: Can't cook without this.
components:
- type: Sprite
sprite: Clothing/chef_uniform.rsi
state: chef
- type: Icon
sprite: Clothing/chef_uniform.rsi
state: chef
- type: Clothing
sprite: Clothing/chef_uniform.rsi
- type: entity
parent: UniformBase
id: UniformCaptain
name: Captain's Jumpsuit
description: It's a blue jumpsuit with some gold markings denoting the rank of "Captain".
components:
- type: Sprite
sprite: Clothing/captain_uniform.rsi
state: captain
- type: Icon
sprite: Clothing/captain_uniform.rsi
state: captain
- type: Clothing
sprite: Clothing/captain_uniform.rsi
- type: entity
parent: UniformBase
id: UniformHOP
name: Head of Personnel's Jumpsuit
description: It's a jumpsuit worn by someone who works in the position of "Head of Personnel".
components:
- type: Sprite
sprite: Clothing/hop_jumpsuit.rsi
state: hop
- type: Icon
sprite: Clothing/hop_jumpsuit.rsi
state: hop
- type: Clothing
sprite: Clothing/hop_jumpsuit.rsi
- type: entity
parent: UniformBase
id: UniformMime
name: Mime's Outfit
description: It's not very colourful.
components:
- type: Sprite
sprite: Clothing/mime_outfit.rsi
state: mime
- type: Icon
sprite: Clothing/mime_outfit.rsi
state: mime
- type: Clothing
sprite: Clothing/mime_outfit.rsi

View File

@@ -0,0 +1,20 @@
- type: entity
name: Butcher's Cleaver
parent: BaseItem
id: ButchCleaver
desc: A huge thing used for chopping and chopping up meat. This includes clowns and clown-by-products.
components:
- type: Sprite
sprite: Objects/items/cleaver.rsi
size: 4
state: butch
- type: Icon
sprite: Objects/items/cleaver.rsi
state: butch
- type: MeleeWeapon
- type: Item
Size: 10
sprite: Objects/items/cleaver.rsi
prefix: inhand

View File

@@ -1,3 +1,12 @@
- type: sound_collection
id: footstep_carpet
files:
- /Audio/effects/footsteps/carpet1.ogg
- /Audio/effects/footsteps/carpet2.ogg
- /Audio/effects/footsteps/carpet3.ogg
- /Audio/effects/footsteps/carpet4.ogg
- /Audio/effects/footsteps/carpet5.ogg
- type: sound_collection
id: footstep_catwalk
files:
@@ -16,6 +25,15 @@
- /Audio/effects/footsteps/floor4.ogg
- /Audio/effects/footsteps/floor5.ogg
- type: sound_collection
id: footstep_hull
files:
- /Audio/effects/footsteps/hull1.ogg
- /Audio/effects/footsteps/hull2.ogg
- /Audio/effects/footsteps/hull3.ogg
- /Audio/effects/footsteps/hull4.ogg
- /Audio/effects/footsteps/hull5.ogg
- type: sound_collection
id: footstep_plating
files:
@@ -25,6 +43,15 @@
- /Audio/effects/footsteps/plating4.ogg
- /Audio/effects/footsteps/plating5.ogg
- type: sound_collection
id: footstep_tile
files:
- /Audio/effects/footsteps/tile1.ogg
- /Audio/effects/footsteps/tile2.ogg
- /Audio/effects/footsteps/tile3.ogg
- /Audio/effects/footsteps/tile4.ogg
- /Audio/effects/footsteps/tile5.ogg
- type: sound_collection
id: footstep_clown
files:

View File

@@ -1,7 +1,17 @@
- type: tile
name: floor
display_name: Floor
texture: "floor_steel"
name: floor_carpet
display_name: Carpet
texture: "carpet"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_carpet
friction: 0.35
subfloor: plating
- type: tile
name: floor_dark
display_name: Dark floor
texture: "dark"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
@@ -9,21 +19,131 @@
subfloor: plating
- type: tile
name: floor_white
display_name: White Floor
texture: "floor_white"
name: floor_elevator_shaft
display_name: Elevator shaft
texture: "elevator_shaft"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.1
subfloor: underplating
friction: 0.35
subfloor: plating
- type: tile
name: floor_freezer
display_name: Freezer
texture: "freezer"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.35
subfloor: plating
- type: tile
name: floor_hydro
display_name: Hydro floor
texture: "hydro"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.35
subfloor: plating
- type: tile
name: floor_green_circuit
display_name: Green circuit floor
texture: "green_circuit"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.35
subfloor: plating
- type: tile
name: floor_lino
display_name: Linoleum floor
texture: "lino"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.35
subfloor: plating
- type: tile
name: floor_mono
display_name: Mono floor
texture: "mono"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.35
subfloor: plating
- type: tile
name: floor_reinforced
display_name: Reinforced floor
texture: "reinforced"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.35
subfloor: plating
- type: tile
name: floor_rock_vault
display_name: Rock vault floor
texture: "rock_vault"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.35
subfloor: plating
- type: tile
name: floor_showroom
display_name: Showroom floor
texture: "showroom"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.35
subfloor: plating
- type: tile
name: floor_steel
display_name: Steel floor
texture: "steel"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.35
subfloor: plating
- type: tile
name: floor_steel_dirty
display_name: Dirty steel floor
texture: "steel_dirty"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.35
subfloor: plating
- type: tile
name: floor_techmaint
display_name: Techmaint Floor
texture: "floor_techmaint"
texture: "tech_maint"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.5
subfloor: underplating
- type: tile
name: floor_white
display_name: White Floor
texture: "white"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_floor
friction: 0.1
subfloor: underplating

View File

@@ -0,0 +1,397 @@
# TODO: Change code to avoid the DRY
- type: tile
parent: floor_hull_base
name: floor_hull_center0
display_name: Hull Center 0
texture: "Hull/hullcenter0"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center1
display_name: Hull Center 1
texture: "Hull/hullcenter1"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center2
display_name: Hull Center 2
texture: "Hull/hullcenter2"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center3
display_name: Hull Center 3
texture: "Hull/hullcenter3"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center4
display_name: Hull Center 4
texture: "Hull/hullcenter4"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center5
display_name: Hull Center 5
texture: "Hull/hullcenter5"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center6
display_name: Hull Center 6
texture: "Hull/hullcenter6"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center7
display_name: Hull Center 7
texture: "Hull/hullcenter7"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center8
display_name: Hull Center 8
texture: "Hull/hullcenter8"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center9
display_name: Hull Center 9
texture: "Hull/hullcenter9"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center10
display_name: Hull Center 10
texture: "Hull/hullcenter10"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center11
display_name: Hull Center 11
texture: "Hull/hullcenter11"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center12
display_name: Hull Center 12
texture: "Hull/hullcenter12"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center13
display_name: Hull Center 13
texture: "Hull/hullcenter13"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center14
display_name: Hull Center 14
texture: "Hull/hullcenter14"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center15
display_name: Hull Center 15
texture: "Hull/hullcenter15"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center16
display_name: Hull Center 16
texture: "Hull/hullcenter16"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center17
display_name: Hull Center 17
texture: "Hull/hullcenter17"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center18
display_name: Hull Center 18
texture: "Hull/hullcenter18"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center19
display_name: Hull Center 19
texture: "Hull/hullcenter19"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center20
display_name: Hull Center 20
texture: "Hull/hullcenter20"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center21
display_name: Hull Center 21
texture: "Hull/hullcenter21"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center22
display_name: Hull Center 22
texture: "Hull/hullcenter22"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center23
display_name: Hull Center 23
texture: "Hull/hullcenter23"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center24
display_name: Hull Center 24
texture: "Hull/hullcenter24"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center25
display_name: Hull Center 25
texture: "Hull/hullcenter25"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center26
display_name: Hull Center 26
texture: "Hull/hullcenter26"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center27
display_name: Hull Center 27
texture: "Hull/hullcenter27"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center28
display_name: Hull Center 28
texture: "Hull/hullcenter28"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center29
display_name: Hull Center 29
texture: "Hull/hullcenter29"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center30
display_name: Hull Center 30
texture: "Hull/hullcenter30"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center31
display_name: Hull Center 31
texture: "Hull/hullcenter31"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center32
display_name: Hull Center 32
texture: "Hull/hullcenter32"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center33
display_name: Hull Center 33
texture: "Hull/hullcenter33"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center34
display_name: Hull Center 34
texture: "Hull/hullcenter34"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating
- type: tile
parent: floor_hull_base
name: floor_hull_center35
display_name: Hull Center 35
texture: "Hull/hullcenter35"
is_subfloor: false
can_crowbar: true
footstep_sounds: footstep_hull
friction: 0.35
subfloor: plating

Binary file not shown.

After

Width:  |  Height:  |  Size: 758 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 558 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 758 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 558 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 580 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 715 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 580 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 715 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 473 B

View File

@@ -0,0 +1 @@
{"version": 1, "size": {"x": 32, "y": 32}, "license": "CC-BY-SA-3.0", "copyright": "https://github.com/vgstation-coders/vgstation13/raw/99cc2ab62d65a3a7b554dc7b21ff5f57c835f973/icons/turf/walls.dmi", "states": [{"name": "brick0", "directions": 4}, {"name": "brick1", "directions": 4}, {"name": "brick2", "directions": 4}, {"name": "brick3", "directions": 4}, {"name": "brick4", "directions": 4}, {"name": "brick5", "directions": 4}, {"name": "brick6", "directions": 4}, {"name": "brick7", "directions": 4}, {"name": "full", "directions": 1}]}

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 978 B

View File

@@ -0,0 +1 @@
{"version": 1, "size": {"x": 32, "y": 32}, "license": "CC-BY-SA-3.0", "copyright": "https://github.com/vgstation-coders/vgstation13/raw/99cc2ab62d65a3a7b554dc7b21ff5f57c835f973/icons/turf/walls.dmi", "states": [{"name": "clock0", "directions": 4}, {"name": "clock1", "directions": 4}, {"name": "clock2", "directions": 4}, {"name": "clock3", "directions": 4}, {"name": "clock4", "directions": 4}, {"name": "clock5", "directions": 4}, {"name": "clock6", "directions": 4}, {"name": "clock7", "directions": 4}, {"name": "full", "directions": 1}]}

Binary file not shown.

After

Width:  |  Height:  |  Size: 674 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 441 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 674 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 441 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 469 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 653 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 469 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 653 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 424 B

View File

@@ -0,0 +1 @@
{"version": 1, "size": {"x": 32, "y": 32}, "license": "CC-BY-SA-3.0", "copyright": "https://github.com/vgstation-coders/vgstation13/raw/99cc2ab62d65a3a7b554dc7b21ff5f57c835f973/icons/turf/walls.dmi", "states": [{"name": "clown0", "directions": 4}, {"name": "clown1", "directions": 4}, {"name": "clown2", "directions": 4}, {"name": "clown3", "directions": 4}, {"name": "clown4", "directions": 4}, {"name": "clown5", "directions": 4}, {"name": "clown6", "directions": 4}, {"name": "clown7", "directions": 4}, {"name": "full", "directions": 1}]}

Binary file not shown.

After

Width:  |  Height:  |  Size: 916 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1017 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 916 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1017 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1021 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 932 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1021 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 932 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 591 B

View File

@@ -0,0 +1 @@
{"version": 1, "size": {"x": 32, "y": 32}, "license": "CC-BY-SA-3.0", "copyright": "https://github.com/vgstation-coders/vgstation13/raw/99cc2ab62d65a3a7b554dc7b21ff5f57c835f973/icons/turf/walls.dmi", "states": [{"name": "cult0", "directions": 4}, {"name": "cult1", "directions": 4}, {"name": "cult2", "directions": 4}, {"name": "cult3", "directions": 4}, {"name": "cult4", "directions": 4}, {"name": "cult5", "directions": 4}, {"name": "cult6", "directions": 4}, {"name": "cult7", "directions": 4}, {"name": "full", "directions": 1}]}

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

View File

Before

Width:  |  Height:  |  Size: 269 B

After

Width:  |  Height:  |  Size: 269 B

View File

@@ -0,0 +1,65 @@
{
"version": 1,
"license": "CC-BY-SA-3.0",
"copyright": "Taken from https://github.com/discordia-space/CEV-Eris/blob/c34c1b30abf18aa552e19294523924c39e5ea127/icons/turf/wall_masks.dmi and modified.",
"size": {
"x": 32,
"y": 32
},
"states": [
{
"name": "full",
"select": [],
"flags": {},
"directions": 1
},
{
"name": "debug0",
"select": [],
"flags": {},
"directions": 4
},
{
"name": "debug1",
"select": [],
"flags": {},
"directions": 4
},
{
"name": "debug2",
"select": [],
"flags": {},
"directions": 4
},
{
"name": "debug3",
"select": [],
"flags": {},
"directions": 4
},
{
"name": "debug4",
"select": [],
"flags": {},
"directions": 4
},
{
"name": "debug5",
"select": [],
"flags": {},
"directions": 4
},
{
"name": "debug6",
"select": [],
"flags": {},
"directions": 4
},
{
"name": "debug7",
"select": [],
"flags": {},
"directions": 4
}
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 758 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 566 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 758 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 566 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 576 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 770 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 576 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 770 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 470 B

View File

@@ -0,0 +1 @@
{"version": 1, "size": {"x": 32, "y": 32}, "license": "CC-BY-SA-3.0", "copyright": "https://github.com/vgstation-coders/vgstation13/raw/99cc2ab62d65a3a7b554dc7b21ff5f57c835f973/icons/turf/walls.dmi", "states": [{"name": "diamond0", "directions": 4}, {"name": "diamond1", "directions": 4}, {"name": "diamond2", "directions": 4}, {"name": "diamond3", "directions": 4}, {"name": "diamond4", "directions": 4}, {"name": "diamond5", "directions": 4}, {"name": "diamond6", "directions": 4}, {"name": "diamond7", "directions": 4}, {"name": "full", "directions": 1}]}

Some files were not shown because too many files have changed in this diff Show More