Skip to main content

IOExtensions.ReadIntNullable

Declaration#

public static Nullable<Int32> ReadIntNullable(Stream fs)

Parameters#

NameDescription
fsStream to use

Description#

Read an integer from a stream

Usage#

Example
using NullSave.GDTK;using System.IO;using UnityEngine;
public class ExampleObject : MonoBehaviour{
    private void Start()    {            MemoryStream ms = new MemoryStream();            ms.WriteIntNullable(42);
            ms.Seek(0, SeekOrigin.Begin);            Debug.Log("Result: " + ms.ReadIntNullable());    }
}