еще приколы
This commit is contained in:
@@ -42,7 +42,7 @@ public sealed class HumanoidAppearanceSystem : SharedHumanoidAppearanceSystem
|
|||||||
component.BaseLayers.Clear();
|
component.BaseLayers.Clear();
|
||||||
|
|
||||||
// add default species layers
|
// add default species layers
|
||||||
var bodyTypeProto = _prototypeManager.Index<BodyTypePrototype>(component.BodyType);
|
var bodyTypeProto = _prototypeManager.Index(component.BodyType);
|
||||||
foreach (var (key, id) in bodyTypeProto.Sprites)
|
foreach (var (key, id) in bodyTypeProto.Sprites)
|
||||||
{
|
{
|
||||||
oldLayers.Remove(key);
|
oldLayers.Remove(key);
|
||||||
|
|||||||
@@ -42,7 +42,7 @@ namespace Content.Client.Options.UI.Tabs
|
|||||||
var id = 0;
|
var id = 0;
|
||||||
foreach (var layout in Enum.GetValues(typeof(ScreenType)))
|
foreach (var layout in Enum.GetValues(typeof(ScreenType)))
|
||||||
{
|
{
|
||||||
var name = Loc.GetString($"ui-options-hud-type-{layout!.ToString()!.ToLower()}");
|
var name = layout.ToString()!;
|
||||||
HudLayoutOption.AddItem(name, id);
|
HudLayoutOption.AddItem(name, id);
|
||||||
if (name == hudLayout)
|
if (name == hudLayout)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -947,7 +947,7 @@ namespace Content.Client.Preferences.UI
|
|||||||
}
|
}
|
||||||
|
|
||||||
// If current body type is not valid.
|
// If current body type is not valid.
|
||||||
if (!_bodyTypesList.Select(proto => proto.ID).Contains(Profile.BodyType))
|
if (!_bodyTypesList.Select(proto => proto.ID).Contains(Profile.BodyType.Id))
|
||||||
{
|
{
|
||||||
// Then replace it with a first valid body type.
|
// Then replace it with a first valid body type.
|
||||||
SetBodyType(_bodyTypesList.First().ID);
|
SetBodyType(_bodyTypesList.First().ID);
|
||||||
|
|||||||
@@ -10,7 +10,6 @@ namespace Content.Server.Humanoid;
|
|||||||
public sealed partial class HumanoidAppearanceSystem : SharedHumanoidAppearanceSystem
|
public sealed partial class HumanoidAppearanceSystem : SharedHumanoidAppearanceSystem
|
||||||
{
|
{
|
||||||
[Dependency] private readonly MarkingManager _markingManager = default!;
|
[Dependency] private readonly MarkingManager _markingManager = default!;
|
||||||
[Dependency] private readonly IPrototypeManager _prototypeManager = default!;
|
|
||||||
|
|
||||||
public override void Initialize()
|
public override void Initialize()
|
||||||
{
|
{
|
||||||
@@ -60,32 +59,6 @@ public sealed partial class HumanoidAppearanceSystem : SharedHumanoidAppearanceS
|
|||||||
Dirty(target, targetHumanoid);
|
Dirty(target, targetHumanoid);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Set a humanoid mob's body yupe. This will change their base sprites.
|
|
||||||
/// </summary>
|
|
||||||
/// <param name="uid">The humanoid mob's UID.</param>
|
|
||||||
/// <param name="bodyType">The body type to set the mob to. Will return if the body type prototype was invalid.</param>
|
|
||||||
/// <param name="sync">Whether to immediately synchronize this to the humanoid mob, or not.</param>
|
|
||||||
/// <param name="humanoid">Humanoid component of the entity</param>
|
|
||||||
public void SetBodyType(
|
|
||||||
EntityUid uid,
|
|
||||||
string bodyType,
|
|
||||||
bool sync = true,
|
|
||||||
HumanoidAppearanceComponent? humanoid = null)
|
|
||||||
{
|
|
||||||
if (!Resolve(uid, ref humanoid) || !_prototypeManager.TryIndex<BodyTypePrototype>(bodyType, out _))
|
|
||||||
{
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
humanoid.BodyType = bodyType;
|
|
||||||
|
|
||||||
if (sync)
|
|
||||||
{
|
|
||||||
Dirty(uid, humanoid);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Removes a marking from a humanoid by ID.
|
/// Removes a marking from a humanoid by ID.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -73,8 +73,8 @@ public sealed partial class HumanoidAppearanceComponent : Component
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Current body type.
|
/// Current body type.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[DataField("bodyType", customTypeSerializer: typeof(PrototypeIdSerializer<BodyTypePrototype>)), AutoNetworkedField]
|
[DataField("bodyType"), AutoNetworkedField]
|
||||||
public string BodyType = SharedHumanoidAppearanceSystem.DefaultBodyType;
|
public ProtoId<BodyTypePrototype> BodyType = SharedHumanoidAppearanceSystem.DefaultBodyType;
|
||||||
|
|
||||||
[DataField, AutoNetworkedField]
|
[DataField, AutoNetworkedField]
|
||||||
public Color EyeColor = Color.Brown;
|
public Color EyeColor = Color.Brown;
|
||||||
@@ -101,7 +101,9 @@ public readonly partial struct CustomBaseLayerInfo
|
|||||||
{
|
{
|
||||||
public CustomBaseLayerInfo(string? id, Color? color = null)
|
public CustomBaseLayerInfo(string? id, Color? color = null)
|
||||||
{
|
{
|
||||||
DebugTools.Assert(id == null || IoCManager.Resolve<IPrototypeManager>().HasIndex<HumanoidSpeciesSpriteLayer>(id));
|
DebugTools.Assert(
|
||||||
|
id == null || IoCManager.Resolve<IPrototypeManager>().HasIndex<HumanoidSpeciesSpriteLayer>(id));
|
||||||
|
|
||||||
Id = id;
|
Id = id;
|
||||||
Color = color;
|
Color = color;
|
||||||
}
|
}
|
||||||
@@ -117,4 +119,4 @@ public readonly partial struct CustomBaseLayerInfo
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
[DataField]
|
[DataField]
|
||||||
public Color? Color { get; init; }
|
public Color? Color { get; init; }
|
||||||
}
|
}
|
||||||
@@ -218,6 +218,32 @@ public abstract class SharedHumanoidAppearanceSystem : EntitySystem
|
|||||||
Dirty(uid, humanoid);
|
Dirty(uid, humanoid);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Set a humanoid mob's body yupe. This will change their base sprites.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="uid">The humanoid mob's UID.</param>
|
||||||
|
/// <param name="bodyType">The body type to set the mob to. Will return if the body type prototype was invalid.</param>
|
||||||
|
/// <param name="sync">Whether to immediately synchronize this to the humanoid mob, or not.</param>
|
||||||
|
/// <param name="humanoid">Humanoid component of the entity</param>
|
||||||
|
public void SetBodyType(
|
||||||
|
EntityUid uid,
|
||||||
|
ProtoId<BodyTypePrototype> bodyType,
|
||||||
|
bool sync = true,
|
||||||
|
HumanoidAppearanceComponent? humanoid = null)
|
||||||
|
{
|
||||||
|
if (!Resolve(uid, ref humanoid) || !_proto.TryIndex(bodyType, out _))
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
humanoid.BodyType = bodyType;
|
||||||
|
|
||||||
|
if (sync)
|
||||||
|
{
|
||||||
|
Dirty(uid, humanoid);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Sets the base layer ID of this humanoid mob. A humanoid mob's 'base layer' is
|
/// Sets the base layer ID of this humanoid mob. A humanoid mob's 'base layer' is
|
||||||
/// the skin sprite that is applied to the mob's sprite upon appearance refresh.
|
/// the skin sprite that is applied to the mob's sprite upon appearance refresh.
|
||||||
@@ -327,6 +353,7 @@ public abstract class SharedHumanoidAppearanceSystem : EntitySystem
|
|||||||
humanoid.EyeColor = profile.Appearance.EyeColor;
|
humanoid.EyeColor = profile.Appearance.EyeColor;
|
||||||
|
|
||||||
SetSkinColor(uid, profile.Appearance.SkinColor, false);
|
SetSkinColor(uid, profile.Appearance.SkinColor, false);
|
||||||
|
SetBodyType(uid, profile.BodyType, false);
|
||||||
|
|
||||||
humanoid.MarkingSet.Clear();
|
humanoid.MarkingSet.Clear();
|
||||||
|
|
||||||
|
|||||||
@@ -41,7 +41,7 @@ namespace Content.Shared.Preferences
|
|||||||
Sex sex,
|
Sex sex,
|
||||||
string voice,
|
string voice,
|
||||||
Gender gender,
|
Gender gender,
|
||||||
string bodyType,
|
ProtoId<BodyTypePrototype> bodyType,
|
||||||
HumanoidCharacterAppearance appearance,
|
HumanoidCharacterAppearance appearance,
|
||||||
ClothingPreference clothing,
|
ClothingPreference clothing,
|
||||||
BackpackPreference backpack,
|
BackpackPreference backpack,
|
||||||
@@ -270,7 +270,7 @@ namespace Content.Shared.Preferences
|
|||||||
public Gender Gender { get; private set; }
|
public Gender Gender { get; private set; }
|
||||||
|
|
||||||
[DataField]
|
[DataField]
|
||||||
public string BodyType { get; private set; }
|
public ProtoId<BodyTypePrototype> BodyType { get; private set; }
|
||||||
|
|
||||||
public ICharacterAppearance CharacterAppearance => Appearance;
|
public ICharacterAppearance CharacterAppearance => Appearance;
|
||||||
|
|
||||||
|
|||||||
@@ -260,9 +260,6 @@ ui-options-net-pvs-leave-tooltip = This limits the rate at which the client will
|
|||||||
stuttering when walking around, but could occasionally
|
stuttering when walking around, but could occasionally
|
||||||
lead to mispredicts and other issues.
|
lead to mispredicts and other issues.
|
||||||
|
|
||||||
ui-options-hud-type-default = Default
|
|
||||||
ui-options-hud-type-separated = Separated
|
|
||||||
|
|
||||||
## Toggle window console command
|
## Toggle window console command
|
||||||
cmd-options-desc = Opens options menu, optionally with a specific tab selected.
|
cmd-options-desc = Opens options menu, optionally with a specific tab selected.
|
||||||
cmd-options-help = Usage: options [tab]
|
cmd-options-help = Usage: options [tab]
|
||||||
|
|||||||
@@ -265,9 +265,6 @@ ui-options-net-pvs-leave-tooltip =
|
|||||||
уменьшить "захлебывания" при ходьбе, но иногда может
|
уменьшить "захлебывания" при ходьбе, но иногда может
|
||||||
привести к неправильным предугадываниям и другим проблемам.
|
привести к неправильным предугадываниям и другим проблемам.
|
||||||
|
|
||||||
ui-options-hud-type-default = Компактный
|
|
||||||
ui-options-hud-type-separated = Обычный
|
|
||||||
|
|
||||||
## Toggle window console command
|
## Toggle window console command
|
||||||
cmd-options-desc = Открывает меню опций, опционально с конкретно выбранной вкладкой.
|
cmd-options-desc = Открывает меню опций, опционально с конкретно выбранной вкладкой.
|
||||||
cmd-options-help = Использование: options [tab]
|
cmd-options-help = Использование: options [tab]
|
||||||
|
|||||||
186176
Resources/Maps/White/WhiteBox.yml
Normal file
186176
Resources/Maps/White/WhiteBox.yml
Normal file
File diff suppressed because it is too large
Load Diff
@@ -3,7 +3,6 @@
|
|||||||
maps:
|
maps:
|
||||||
- Atlas
|
- Atlas
|
||||||
- Bagel
|
- Bagel
|
||||||
- Box
|
|
||||||
- Cluster
|
- Cluster
|
||||||
- Core
|
- Core
|
||||||
- Fland
|
- Fland
|
||||||
@@ -13,5 +12,8 @@
|
|||||||
- Origin
|
- Origin
|
||||||
- Saltern
|
- Saltern
|
||||||
- Packed
|
- Packed
|
||||||
- Reach
|
- WonderBox
|
||||||
|
- Scoupidia
|
||||||
|
- Triumph
|
||||||
|
- WhiteBox
|
||||||
#- Train <- return after station anchoring PR is finished and merged
|
#- Train <- return after station anchoring PR is finished and merged
|
||||||
|
|||||||
59
Resources/Prototypes/Maps/WhiteBox.yml
Normal file
59
Resources/Prototypes/Maps/WhiteBox.yml
Normal file
@@ -0,0 +1,59 @@
|
|||||||
|
- type: gameMap
|
||||||
|
id: WhiteBox
|
||||||
|
mapName: 'Box Station'
|
||||||
|
mapPath: /Maps/White/Whitebox.yml
|
||||||
|
minPlayers: 0
|
||||||
|
stations:
|
||||||
|
Boxstation:
|
||||||
|
stationProto: StandardNanotrasenStation
|
||||||
|
components:
|
||||||
|
- type: StationNameSetup
|
||||||
|
mapNameTemplate: '{0} Box Station {1}'
|
||||||
|
nameGenerator:
|
||||||
|
!type:NanotrasenNameGenerator
|
||||||
|
prefixCreator: 'TG'
|
||||||
|
- type: StationEmergencyShuttle
|
||||||
|
emergencyShuttlePath: /Maps/Shuttles/emergency_box.yml
|
||||||
|
- type: StationJobs
|
||||||
|
overflowJobs:
|
||||||
|
- Passenger
|
||||||
|
availableJobs:
|
||||||
|
CargoTechnician: [ 3, 3 ]
|
||||||
|
Passenger: [ -1, -1 ]
|
||||||
|
Bartender: [ 2, 2 ]
|
||||||
|
Botanist: [ 3, 3 ]
|
||||||
|
Chef: [ 2, 2 ]
|
||||||
|
Clown: [ 1, 1 ]
|
||||||
|
Janitor: [ 3, 3 ]
|
||||||
|
Mime: [ 1, 1 ]
|
||||||
|
Captain: [ 1, 1 ]
|
||||||
|
HeadOfPersonnel: [ 1, 1 ]
|
||||||
|
ChiefEngineer: [ 1, 1 ]
|
||||||
|
StationEngineer: [ 4, 4 ]
|
||||||
|
ChiefMedicalOfficer: [ 1, 1 ]
|
||||||
|
MedicalDoctor: [ 4, 4 ]
|
||||||
|
Chemist: [ 3, 3 ]
|
||||||
|
ResearchDirector: [ 1, 1 ]
|
||||||
|
Scientist: [ 5, 5 ]
|
||||||
|
HeadOfSecurity: [ 1, 1 ]
|
||||||
|
SecurityOfficer: [ 6, 6 ]
|
||||||
|
Chaplain: [ 2, 2 ]
|
||||||
|
Warden: [ 1, 1 ]
|
||||||
|
Librarian: [ 2, 2 ]
|
||||||
|
Lawyer: [ 2, 2 ]
|
||||||
|
Quartermaster: [ 1, 1 ]
|
||||||
|
SalvageSpecialist: [ 3, 3 ]
|
||||||
|
Musician: [ 2, 2 ]
|
||||||
|
AtmosphericTechnician: [ 3, 3 ]
|
||||||
|
TechnicalAssistant: [ 4, 4 ]
|
||||||
|
MedicalIntern: [ 4, 4 ]
|
||||||
|
ServiceWorker: [ 4, 4 ]
|
||||||
|
SecurityCadet: [ 4, 4 ]
|
||||||
|
Detective: [ 1, 1 ]
|
||||||
|
ResearchAssistant: [ 4, 4 ]
|
||||||
|
Paramedic: [ 2, 2 ]
|
||||||
|
SeniorOfficer: [ 1, 1 ]
|
||||||
|
SeniorResearcher: [ 1, 1 ]
|
||||||
|
SeniorPhysician: [ 1, 1 ]
|
||||||
|
SeniorEngineer: [ 1, 1 ]
|
||||||
|
SeniorSalvageSpecialist: [ 1, 1 ]
|
||||||
Reference in New Issue
Block a user