<region type="DungeonRegion" priority="50" name="Stuff">
<rect x="5202" y="0" width="55" height="65" />
<go x="5250" y="17" z="0" />
<music name="Serpents" />
</region>
public sealed class PlayMusic : Packet
{
public static readonly Packet InvalidInstance = SetStatic(new PlayMusic(MusicName.Invalid));
private static readonly Packet[] m_Instances = new Packet[60];
public static Packet GetInstance(MusicName name)
{
if (name == MusicName.Invalid)
{
return InvalidInstance;
}
int v = (int)name;
Packet p;
if (v >= 0 && v < m_Instances.Length)
{
p = m_Instances[v];
if (p == null)
{
m_Instances[v] = p = SetStatic(new PlayMusic(name));
}
}
else
{
p = new PlayMusic(name);
}
return p;
}
public PlayMusic(MusicName name)
: base(0x6D, 3)
{
m_Stream.Write((short)name);
}
}
We use essential cookies to make this site work, and optional cookies to enhance your experience.