Struct PapyrusType
- Namespace
- SkyrimForge.Papyrus
- Assembly
- SkyrimForge.Game.dll
A type in a native function's signature, as the script declares it.
A scalar is one of the fixed kinds. An object declares a form type, from which the Papyrus VM resolves the script class at registration.
public readonly struct PapyrusType
- Inherited Members
Properties
Bool
The type of a bool parameter or return value.
public static PapyrusType Bool { get; }
Property Value
Float
The type of a float parameter or return value.
public static PapyrusType Float { get; }
Property Value
Int
The type of an int parameter or return value.
public static PapyrusType Int { get; }
Property Value
None
The return type of a function declaring none. Papyrus has no None parameter.
public static PapyrusType None { get; }
Property Value
String
The type of a string parameter or return value.
public static PapyrusType String { get; }
Property Value
Methods
Form(FormType)
Builds the type for a form of objectType,
such as ObjectReference for Reference or Actor for ActorCharacter.
public static PapyrusType Form(FormType objectType)
Parameters
objectTypeFormType
Returns
FromType<T>()
Gets the Papyrus type of T, which is int, float, bool, string, a form view, or an array of one of those.
A nullable type maps to the type it wraps.
public static PapyrusType FromType<T>()
Returns
Type Parameters
T
Exceptions
- TypeInitializationException
Papyrus has no such type, wrapping the NotSupportedException that names it.
MakeArrayType(PapyrusType)
Builds the type for an array of elementType, such as Int[] or Form[].
public static PapyrusType MakeArrayType(PapyrusType elementType)
Parameters
elementTypePapyrusType
Returns
Exceptions
- NotSupportedException
Papyrus has no array of
elementType. Arrays of arrays and arrays of None do not exist.