Derotate Saltern (#12503)
Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
This commit is contained in:
@@ -82,7 +82,7 @@ namespace Content.IntegrationTests.Tests
|
||||
/// Loads the default map, runs it for 5 ticks, then assert that it did not change.
|
||||
/// </summary>
|
||||
[Test]
|
||||
public async Task LoadSaveTicksSaveSaltern()
|
||||
public async Task LoadSaveTicksSaveBagel()
|
||||
{
|
||||
await using var pairTracker = await PoolManager.GetServerClient(new PoolSettings{NoClient = true});
|
||||
var server = pairTracker.Pair.Server;
|
||||
@@ -97,7 +97,7 @@ namespace Content.IntegrationTests.Tests
|
||||
mapId = mapManager.CreateMap();
|
||||
mapManager.AddUninitializedMap(mapId);
|
||||
mapManager.SetMapPaused(mapId, true);
|
||||
mapLoader.LoadMap(mapId, "Maps/saltern.yml");
|
||||
mapLoader.LoadMap(mapId, "Maps/bagel.yml");
|
||||
mapLoader.SaveMap(mapId, "load save ticks save 1.yml");
|
||||
});
|
||||
|
||||
|
||||
@@ -28,6 +28,7 @@ namespace Content.Server.Physics.Controllers
|
||||
[Dependency] private readonly GravitySystem _gravity = default!;
|
||||
[Dependency] private readonly RecyclerSystem _recycler = default!;
|
||||
[Dependency] private readonly SignalLinkerSystem _signalSystem = default!;
|
||||
[Dependency] private readonly SharedBroadphaseSystem _broadphase = default!;
|
||||
[Dependency] private readonly SharedPhysicsSystem _physics = default!;
|
||||
[Dependency] private readonly SharedAppearanceSystem _appearance = default!;
|
||||
|
||||
@@ -60,7 +61,7 @@ namespace Content.Server.Physics.Controllers
|
||||
{
|
||||
var otherUid = args.OtherFixture.Body.Owner;
|
||||
|
||||
if (args.OtherFixture.Body.BodyType == BodyType.Static)
|
||||
if (args.OtherFixture.Body.BodyType == BodyType.Static || component.State == ConveyorState.Off)
|
||||
return;
|
||||
|
||||
component.Intersecting.Add(otherUid);
|
||||
@@ -99,23 +100,31 @@ namespace Content.Server.Physics.Controllers
|
||||
private void OnSignalReceived(EntityUid uid, ConveyorComponent component, SignalReceivedEvent args)
|
||||
{
|
||||
if (args.Port == component.OffPort)
|
||||
SetState(component, ConveyorState.Off);
|
||||
SetState(uid, ConveyorState.Off, component);
|
||||
else if (args.Port == component.ForwardPort)
|
||||
{
|
||||
AwakenEntities(component);
|
||||
SetState(component, ConveyorState.Forward);
|
||||
SetState(uid, ConveyorState.Forward, component);
|
||||
}
|
||||
else if (args.Port == component.ReversePort)
|
||||
{
|
||||
AwakenEntities(component);
|
||||
SetState(component, ConveyorState.Reverse);
|
||||
SetState(uid, ConveyorState.Reverse, component);
|
||||
}
|
||||
}
|
||||
|
||||
private void SetState(ConveyorComponent component, ConveyorState state)
|
||||
private void SetState(EntityUid uid, ConveyorState state, ConveyorComponent? component = null)
|
||||
{
|
||||
if (!Resolve(uid, ref component))
|
||||
return;
|
||||
|
||||
component.State = state;
|
||||
|
||||
if (TryComp<PhysicsComponent>(uid, out var physics))
|
||||
{
|
||||
_broadphase.RegenerateContacts(physics);
|
||||
}
|
||||
|
||||
if (TryComp<RecyclerComponent>(component.Owner, out var recycler))
|
||||
{
|
||||
if (component.State != ConveyorState.Off)
|
||||
|
||||
@@ -52106,9 +52106,6 @@ entities:
|
||||
- pos: 48.5,-39.5
|
||||
parent: 60
|
||||
type: Transform
|
||||
- SecondsUntilStateChange: -37148.992
|
||||
state: Opening
|
||||
type: Door
|
||||
- uid: 3729
|
||||
type: PoweredSmallLight
|
||||
components:
|
||||
@@ -123765,9 +123762,6 @@ entities:
|
||||
- pos: 31.5,-19.5
|
||||
parent: 60
|
||||
type: Transform
|
||||
- SecondsUntilStateChange: -30661.895
|
||||
state: Closing
|
||||
type: Door
|
||||
- uid: 14524
|
||||
type: ReinforcedWindow
|
||||
components:
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -9,4 +9,3 @@
|
||||
- Marathon
|
||||
- Omega
|
||||
- Pillar
|
||||
- Saltern
|
||||
|
||||
@@ -1,48 +0,0 @@
|
||||
- type: gameMap
|
||||
id: Saltern
|
||||
mapName: 'Saltern'
|
||||
mapPath: /Maps/saltern.yml
|
||||
minPlayers: 0
|
||||
maxPlayers: 35
|
||||
fallback: true
|
||||
stations:
|
||||
Saltern:
|
||||
mapNameTemplate: '{0} Saltern {1}'
|
||||
nameGenerator:
|
||||
!type:NanotrasenNameGenerator
|
||||
prefixCreator: '14'
|
||||
overflowJobs:
|
||||
- Passenger
|
||||
availableJobs:
|
||||
CargoTechnician: [ 2, 2 ]
|
||||
Passenger: [ -1, -1 ]
|
||||
Bartender: [ 1, 1 ]
|
||||
Botanist: [ 2, 2 ]
|
||||
Chef: [ 1, 1 ]
|
||||
Clown: [ 1, 1 ]
|
||||
Janitor: [ 1, 1 ]
|
||||
Mime: [ 1, 1 ]
|
||||
Captain: [ 1, 1 ]
|
||||
HeadOfPersonnel: [ 1, 1 ]
|
||||
ChiefEngineer: [ 1, 1 ]
|
||||
StationEngineer: [ 3, 3 ]
|
||||
AtmosphericTechnician: [ 2, 2 ]
|
||||
ChiefMedicalOfficer: [ 1, 1 ]
|
||||
MedicalDoctor: [ 2, 2 ]
|
||||
Chemist: [ 2, 2 ]
|
||||
ResearchDirector: [ 1, 1 ]
|
||||
Scientist: [ 3, 3 ]
|
||||
HeadOfSecurity: [ 1, 1 ]
|
||||
SecurityOfficer: [ 3, 3 ]
|
||||
Chaplain: [ 1, 1 ]
|
||||
Librarian: [ 1, 1 ]
|
||||
Musician: [ 1, 1 ]
|
||||
Lawyer: [ 1, 1 ]
|
||||
SalvageSpecialist: [ 1, 2 ]
|
||||
Quartermaster: [ 1, 1 ]
|
||||
TechnicalAssistant: [ 2, 2 ]
|
||||
MedicalIntern: [ 2, 2 ]
|
||||
ServiceWorker: [ 2, 2 ]
|
||||
SecurityCadet: [ 2, 2 ]
|
||||
Detective: [ 1, 1 ]
|
||||
Warden: [ 1, 1 ]
|
||||
Reference in New Issue
Block a user