Beispiel #1
0
    public static HatFlair ConstructFlair(Transform parent, SaveHatFlairEntry entry)
    {
        HatFlair newFlair = (HatFlair)Instantiate(globalHatFlairPrefab, parent, false);

        newFlair.transform.localPosition = entry.position.V3;
        newFlair.transform.localRotation = entry.rotation.Q;
        newFlair.transform.SetParent(null);
        newFlair.flairIcon  = entry.icon;
        newFlair.FlairId    = entry.id;
        newFlair.flairSize  = entry.size;
        newFlair.flairShiny = entry.shiny ? 1 : 0;
        return(newFlair);
    }
Beispiel #2
0
 public bool Matches(SaveHatFlairEntry entry)
 {
     return(flairId.Equals(entry.id));
 }