Terraria v1.4.4.9
Terraria source code documentation
All Classes Namespaces Files Functions Variables Enumerations Enumerator Properties Events Macros
TraceLoggingEventHandleTable.cs
Go to the documentation of this file.
2
4
5internal sealed class TraceLoggingEventHandleTable
6{
8
9 internal IntPtr this[int eventID]
10 {
11 get
12 {
13 IntPtr result = IntPtr.Zero;
15 if (eventID >= 0 && eventID < array.Length)
16 {
17 result = array[eventID];
18 }
19 return result;
20 }
21 }
22
24 {
25 m_innerTable = new IntPtr[10];
26 }
27
28 internal void SetEventHandle(int eventID, IntPtr eventHandle)
29 {
30 if (eventID >= m_innerTable.Length)
31 {
32 int num = m_innerTable.Length * 2;
33 if (num <= eventID)
34 {
35 num = eventID + 1;
36 }
37 IntPtr[] array = new IntPtr[num];
40 }
41 m_innerTable[eventID] = eventHandle;
42 }
43}
static unsafe void Copy(Array sourceArray, Array destinationArray, int length)
Definition Array.cs:624
static bool Read(ref bool location)
Definition Volatile.cs:67
static void Write(ref bool location, bool value)
Definition Volatile.cs:74
static readonly IntPtr Zero
Definition IntPtr.cs:18