Created
June 7, 2015 07:52
-
-
Save LordNed/5e686e84356b811843e9 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class EntrySubOption : INotifyPropertyChanged | |
{ | |
/* Actual Layout of Struct on Disk: */ | |
// 0x2C/44 bytes long | |
// 0x00 - string Name | |
// 0x21 - string MapName | |
// 0x29 - byte RoomNumber | |
// 0x2A - byte SpawnPointId | |
// 0x2B byte LoadedLayerId | |
public string Name | |
{ | |
get { return m_name; } | |
set { m_name = value; OnPropertyChanged("Name"); } | |
} | |
public string MapName | |
{ | |
get { return m_mapName; } | |
set { m_mapName = value; OnPropertyChanged("MapName"); } | |
} | |
public byte RoomNumber | |
{ | |
get { return m_roomNumber; } | |
set { m_roomNumber = value; OnPropertyChanged("RoomNumber"); } | |
} | |
public byte SpawnPointId | |
{ | |
get { return m_spawnPointId; } | |
set { m_spawnPointId = value; OnPropertyChanged("SpawnPointId"); } | |
} | |
// Speculation, untested by Gamma is confident. I agree that it makes sense to have it. | |
public byte LoadedLayerId | |
{ | |
get { return m_loadedLayerId; } | |
set { m_loadedLayerId = value; OnPropertyChanged("LoadedLayerId"); } | |
} | |
private string m_name; | |
private string m_mapName; | |
private byte m_roomNumber; | |
private byte m_spawnPointId; | |
private byte m_loadedLayerId; | |
public event PropertyChangedEventHandler PropertyChanged; | |
protected void OnPropertyChanged(string propertyName) | |
{ | |
if (PropertyChanged != null) | |
PropertyChanged(this, new PropertyChangedEventArgs(propertyName)); | |
} | |
public void Load(EndianBinaryReader stream) | |
{ | |
// ... | |
} | |
public void Save(EndianBinaryWriter stream) | |
{ | |
// ... | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment