Seeding reorg
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
using MessagePack;
|
||||
using SVSim.Database.Models;
|
||||
using SVSim.Database.Models.Config;
|
||||
using System.Text.Json.Serialization;
|
||||
|
||||
namespace SVSim.EmulatedEntrypoint.Models.Dtos;
|
||||
@@ -17,14 +17,14 @@ public class DefaultSettings
|
||||
[Key("default_mypage_id")]
|
||||
public int DefaultMyPageBackground { get; set; }
|
||||
|
||||
public DefaultSettings(GameConfiguration config)
|
||||
public DefaultSettings(DefaultLoadoutConfig loadout)
|
||||
{
|
||||
this.DefaultMyPageBackground = config.Config.DefaultLoadout.MyPageBackgroundId;
|
||||
this.DefaultDegreeId = config.Config.DefaultLoadout.DegreeId;
|
||||
this.DefaultEmblemId = config.Config.DefaultLoadout.EmblemId;
|
||||
this.DefaultMyPageBackground = loadout.MyPageBackgroundId;
|
||||
this.DefaultDegreeId = loadout.DegreeId;
|
||||
this.DefaultEmblemId = loadout.EmblemId;
|
||||
}
|
||||
|
||||
public DefaultSettings()
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -27,8 +27,8 @@ public class UserLeaderSkin
|
||||
{
|
||||
this.Id = leaderSkin.Id;
|
||||
this.Name = leaderSkin.Name;
|
||||
// Class is nullable 窶・BaseDataSeeder maps CSV class_chara_id=0 to null. Fall back to
|
||||
// the FK column (also nullable) and finally 0 for class-agnostic skins.
|
||||
// Class is nullable — class-agnostic skins (CSV class_chara_id=0) come in as null. Fall
|
||||
// back to the FK column (also nullable) and finally 0.
|
||||
this.ClassId = leaderSkin.Class?.Id ?? leaderSkin.ClassId ?? 0;
|
||||
this.EmoteId = leaderSkin.EmoteId;
|
||||
this.IsOwned = isOwned;
|
||||
|
||||
Reference in New Issue
Block a user