public virtual void FromBytes(BinaryReader reader, IClassRegistryAPI instancer) { Code = reader.ReadString(); MinQuantity = reader.ReadInt32(); MaxQuantity = reader.ReadInt32(); int q = reader.ReadInt32(); ValidStacks = new CookingRecipeStack[q]; for (int i = 0; i < q; i++) { ValidStacks[i] = new CookingRecipeStack(); ValidStacks[i].FromBytes(reader, instancer); } }
public new CookingRecipeStack Clone() { CookingRecipeStack stack = new CookingRecipeStack() { Code = Code.Clone(), ResolvedItemstack = ResolvedItemstack?.Clone(), StackSize = StackSize, Type = Type, TextureMapping = (string[])TextureMapping?.Clone(), CookedStack = CookedStack?.Clone() }; if (Attributes != null) { stack.Attributes = Attributes.Clone(); } stack.ShapeElement = ShapeElement; return(stack); }