DNA basics (#14724)
* DNA component * Commit numba 2 * Added DNA into Station Records Computer * commit numba 3 * commit numba 4 * Vomit also contain DNA component now * fixed DNA field not clearing after scanning another item * commit numba 10 Drinking leaves DNA on an object. Breaking glasses, bottles and beakers leave DNA and leave fingerprints/fibers with 40% chance on glass shards. + lotta fixes * 11 * 12 * 14 * Added DNA guide entry * FIX
This commit is contained in:
@@ -74,8 +74,9 @@ public sealed class StationRecordsSystem : EntitySystem
|
||||
}
|
||||
|
||||
TryComp<FingerprintComponent>(player, out var fingerprintComponent);
|
||||
TryComp<DnaComponent>(player, out var dnaComponent);
|
||||
|
||||
CreateGeneralRecord(station, idUid.Value, profile.Name, profile.Age, profile.Species, profile.Gender, jobId, fingerprintComponent?.Fingerprint, profile, records);
|
||||
CreateGeneralRecord(station, idUid.Value, profile.Name, profile.Age, profile.Species, profile.Gender, jobId, fingerprintComponent?.Fingerprint, dnaComponent?.DNA, profile, records);
|
||||
}
|
||||
|
||||
|
||||
@@ -97,13 +98,16 @@ public sealed class StationRecordsSystem : EntitySystem
|
||||
/// this call will cause an exception. Ensure that a general record starts out with a job
|
||||
/// that is currently a valid job prototype.
|
||||
/// </param>
|
||||
/// <param name="mobFingerprint">Fingerprint of the character.</param>
|
||||
/// <param name="dna">DNA of the character.</param>
|
||||
///
|
||||
/// <param name="profile">
|
||||
/// Profile for the related player. This is so that other systems can get further information
|
||||
/// about the player character.
|
||||
/// Optional - other systems should anticipate this.
|
||||
/// </param>
|
||||
/// <param name="records">Station records component.</param>
|
||||
public void CreateGeneralRecord(EntityUid station, EntityUid? idUid, string name, int age, string species, Gender gender, string jobId, string? mobFingerprint, HumanoidCharacterProfile? profile = null,
|
||||
public void CreateGeneralRecord(EntityUid station, EntityUid? idUid, string name, int age, string species, Gender gender, string jobId, string? mobFingerprint, string? dna, HumanoidCharacterProfile? profile = null,
|
||||
StationRecordsComponent? records = null)
|
||||
{
|
||||
if (!Resolve(station, ref records))
|
||||
@@ -126,7 +130,8 @@ public sealed class StationRecordsSystem : EntitySystem
|
||||
Species = species,
|
||||
Gender = gender,
|
||||
DisplayPriority = jobPrototype.Weight,
|
||||
Fingerprint = mobFingerprint
|
||||
Fingerprint = mobFingerprint,
|
||||
DNA = dna
|
||||
};
|
||||
|
||||
var key = AddRecord(station, records);
|
||||
|
||||
Reference in New Issue
Block a user