/** Main serializer function. * Serializes all graphs to a byte array * A similar function exists in the AstarEditor.cs script to save additional info */ public byte[] SerializeGraphs(Pathfinding.Serialize.SerializeSettings settings, out uint checksum) { Pathfinding.Serialize.AstarSerializer sr = new Pathfinding.Serialize.AstarSerializer(this, settings); sr.OpenSerialize(); SerializeGraphsPart(sr); byte[] bytes = sr.CloseSerialize(); checksum = sr.GetChecksum(); return(bytes); }
/** Main serializer function. * Serializes all graphs to a byte array * A similar function exists in the AstarEditor.cs script to save additional info */ public byte[] SerializeGraphs(Pathfinding.Serialize.SerializeSettings settings, out uint checksum) { Pathfinding.Serialize.AstarSerializer sr = new Pathfinding.Serialize.AstarSerializer(this, settings); sr.OpenSerialize(); SerializeGraphsPart(sr); byte[] bytes = sr.CloseSerialize(); checksum = sr.GetChecksum(); #if DEBUG Debug.Log("Got a whole bunch of data, " + bytes.Length + " bytes"); #endif return(bytes); }
/** Main serializer function. */ public byte[] SerializeGraphs(Pathfinding.Serialize.SerializeSettings settings) { uint checksum; return(SerializeGraphs(settings, out checksum)); }
public void SaveCacheData(Pathfinding.Serialize.SerializeSettings settings) { data_cachedStartup = SerializeGraphs(settings); cacheStartup = true; }