Markings tweaks (#8394)
* fixes issue with indexing into colors on multi-sprite markings * should rebuild the dummy upon character profile switch in client * markings, when selected, should now default to the current character's skin color * whoops, missed one * adds a type serializer into marking points * that has to be a list serializer, oops
This commit is contained in:
@@ -555,6 +555,7 @@ namespace Content.Client.Preferences.UI
|
||||
|
||||
var color = Color.FromHsv(new Vector4(hue / 360, sat / 100, val / 100, 1.0f));
|
||||
|
||||
CMarkings.CurrentSkinColor = color;
|
||||
Profile = Profile.WithCharacterAppearance(Profile.Appearance.WithSkinColor(color));
|
||||
break;
|
||||
}
|
||||
@@ -567,6 +568,8 @@ namespace Content.Client.Preferences.UI
|
||||
}
|
||||
|
||||
var color = new Color(_rgbSkinColorSelector.Color.R, _rgbSkinColorSelector.Color.G, _rgbSkinColorSelector.Color.B);
|
||||
|
||||
CMarkings.CurrentSkinColor = color;
|
||||
Profile = Profile.WithCharacterAppearance(Profile.Appearance.WithSkinColor(color));
|
||||
break;
|
||||
}
|
||||
@@ -584,6 +587,7 @@ namespace Content.Client.Preferences.UI
|
||||
newColor.Y = .1f;
|
||||
color = Color.FromHsv(newColor);
|
||||
|
||||
CMarkings.CurrentSkinColor = color;
|
||||
Profile = Profile.WithCharacterAppearance(Profile.Appearance.WithSkinColor(color));
|
||||
break;
|
||||
}
|
||||
@@ -834,7 +838,7 @@ namespace Content.Client.Preferences.UI
|
||||
return;
|
||||
}
|
||||
|
||||
CMarkings.SetData(Profile.Appearance.Markings, Profile.Species);
|
||||
CMarkings.SetData(Profile.Appearance.Markings, Profile.Species, Profile.Appearance.SkinColor);
|
||||
}
|
||||
|
||||
private void UpdateSpecies()
|
||||
@@ -945,7 +949,7 @@ namespace Content.Client.Preferences.UI
|
||||
UpdateAntagPreferences();
|
||||
UpdateMarkings();
|
||||
|
||||
_needUpdatePreview = true;
|
||||
NeedsDummyRebuild = true;
|
||||
|
||||
_preferenceUnavailableButton.SelectId((int) Profile.PreferenceUnavailable);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user