Terraria
v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
◆
CreateIntSet()
[1/2]
int[] Terraria.ID.SetFactory.CreateIntSet
(
int
defaultState
,
params
int[]
inputs
)
inline
Definition at line
116
of file
SetFactory.cs
.
117
{
118
if
(
inputs
.Length % 2 != 0)
119
{
120
throw
new
Exception
(
"You have a bad length for inputs on CreateArraySet"
);
121
}
122
int
[]
intBuffer
=
GetIntBuffer
();
123
for
(
int
i = 0;
i
<
intBuffer
.Length;
i
++)
124
{
125
intBuffer
[
i
] =
defaultState
;
126
}
127
for
(
int
j
= 0;
j
<
inputs
.Length;
j
+= 2)
128
{
129
intBuffer
[
inputs
[
j
]] =
inputs
[
j
+ 1];
130
}
131
return
intBuffer
;
132
}
System.Collections.Generic.Dictionary
Definition
Dictionary.cs:14
System.Exception
Definition
Exception.cs:15
Terraria.ID.SetFactory.GetIntBuffer
int[] GetIntBuffer()
Definition
SetFactory.cs:41
System.Text.RegularExpressions.ExceptionArgument.i
@ i
References
Terraria.ID.SetFactory.GetIntBuffer()
.
Terraria
ID
SetFactory
Generated by
1.10.0