Skip to main content

Enums

Instead of passing numbers to methods or comparing numbers in Events callbacks, you can use the following Enums to do so. Examples:

-- Using Enums to figure out which StanceMode the Character is
Character.Subscribe("StanceModeChanged", function(character, old_stance, new_stance)
if (new_stance == StanceMode.Standing) then
Console.Log("I'm Standing!")
else if (new_stance == StanceMode.Crouching) then
Console.Log("I'm Crouching!")
end
end)

-- Using Enums to pass a Light Type to the constructor
local my_light = Light(Vector(-5, 0, 50), Rotator(), Color.RED, LightType.Point)

-- Using Enums to set the Character View Mode
character:SetViewMode(ViewMode.FPS)
info

The functions which use the Enums are still receiving numbers as parameters (as always), using Enums is just a facilitator.

All Enums

🧑‍💻API Source
The methods, properties and events descriptions from this page are defined in our GitHub API Repository!

AimMode

Used by Characters to change the Aiming Mode while holding Weapons
LabelValueDescription
AimMode.None0
AimMode.ADS1
AimMode.ZoomedZoom2
AimMode.Zoomed3
AimMode.ZoomedFar4

AnimationSlotType

LabelValueDescription
AnimationSlotType.FullBody0
AnimationSlotType.UpperBody1

AssetType

LabelValueDescription
AssetType.Map2
AssetType.StaticMesh4
AssetType.SkeletalMesh8
AssetType.Sound16
AssetType.Animation32
AssetType.Particle64
AssetType.Material128
AssetType.Blueprint256

AttachmentRule

LabelValueDescription
AttachmentRule.KeepRelative0
AttachmentRule.KeepWorld1
AttachmentRule.SnapToTarget2

AttenuationFunction

LabelValueDescription
AttenuationFunction.Linear0
AttenuationFunction.Logarithmic1
AttenuationFunction.Inverse2
AttenuationFunction.LogReverse3
AttenuationFunction.NaturalSound4

BlendMode

LabelValueDescription
BlendMode.Opaque0
BlendMode.Masked1
BlendMode.Translucent2
BlendMode.Additive3
BlendMode.Modulate4
BlendMode.MaskedDistanceField5
BlendMode.MaskedDistanceFieldShadowed6
BlendMode.TranslucentDistanceField7
BlendMode.TranslucentDistanceFieldShadowed8
BlendMode.AlphaComposite9
BlendMode.AlphaHoldout10
BlendMode.AlphaBlend11
BlendMode.TranslucentAlphaOnly12
BlendMode.TranslucentAlphaOnlyWriteAlpha13

CameraMode

LabelValueDescription
CameraMode.FPSTPS0
CameraMode.FPSOnly1
CameraMode.TPSOnly2

CCDMode

LabelValueDescription
CCDMode.Auto0Automatically enables/disables depending on the Object size
CCDMode.Disabled1Disables CCD
CCDMode.Enabled2Enables CCD

CollisionChannel

💡TIP
This Enum supports Bitwise Operations!
LabelValueDescription
CollisionChannel.WorldStatic1 << 0WorldStatic Object Types
CollisionChannel.WorldDynamic1 << 1WorldDynamic Object Types
CollisionChannel.Pawn1 << 2Capsules (usually from Characters)
CollisionChannel.PhysicsBody1 << 5Pickables and Props Meshes
CollisionChannel.Mesh1 << 17Character Mesh
CollisionChannel.Water1 << 19Water Body
CollisionChannel.Foliage1 << 20Foliage Meshes
CollisionChannel.Vehicle1 << 22Vehicles Meshes

CollisionType

LabelValueDescription
CollisionType.Normal0Blocks All
CollisionType.StaticOnly1Only Blocks Static objects
CollisionType.NoCollision2Doesn't Block anything
CollisionType.IgnoreOnlyPawn3Blocks everything but Pawns (Characters)
CollisionType.Auto4Automatically selects - usually will be Normal. On Props it will switch between Normal and IgnoreOnlyPawn depending on the Prop size

CursorType

LabelValueDescription
CursorType.None0
CursorType.Default1
CursorType.TextEditBeam2
CursorType.ResizeLeftRight3
CursorType.ResizeUpDown4
CursorType.ResizeSouthEast5
CursorType.ResizeSouthWest6
CursorType.CardinalCross7
CursorType.Crosshairs8
CursorType.Hand9
CursorType.GrabHand10
CursorType.GrabHandClosed11
CursorType.SlashedCircle12
CursorType.EyeDropper13

ConstraintMotion

LabelValueDescription
ConstraintMotion.Free0
ConstraintMotion.Limited1
ConstraintMotion.Locked2

DamageType

LabelValueDescription
DamageType.Shot0
DamageType.Explosion1
DamageType.Punch2
DamageType.Fall3
DamageType.RunOverProp4
DamageType.RunOverVehicle5
DamageType.Melee6
DamageType.Unknown7

DatabaseEngine

LabelValueDescription
DatabaseEngine.SQLite0
DatabaseEngine.MySQL1
DatabaseEngine.PostgreSQL2

FallingMode

LabelValueDescription
FallingMode.None0
FallingMode.Jumping1
FallingMode.Climbing2
FallingMode.Vaulting3
FallingMode.Falling4
FallingMode.HighFalling5
FallingMode.Parachuting6
FallingMode.SkyDiving7

FontType

LabelValueDescription
FontType.Roboto0
FontType.GothicA11
FontType.PoiretOne2
FontType.Oswald3
FontType.RobotoMono4
FontType.OpenSans5

GaitMode

LabelValueDescription
GaitMode.None0
GaitMode.Walking1
GaitMode.Sprinting2

GrabMode

LabelValueDescription
GrabMode.Disabled0Disables grabbing
GrabMode.Auto1Automatically enables/disables depending on the Prop size
GrabMode.Enabled2Enables grabbing

HighlightMode

LabelValueDescription
HighlightMode.Always0
HighlightMode.OnlyHidden1
HighlightMode.OnlyVisible2

HandlingMode

LabelValueDescription
HandlingMode.SingleHandedWeapon0
HandlingMode.DoubleHandedWeapon1
HandlingMode.SingleHandedMelee2
HandlingMode.DoubleHandedMelee3
HandlingMode.Throwable4
HandlingMode.Torch5
HandlingMode.Barrel6
HandlingMode.Box7

ImageFormat

LabelValueDescription
ImageFormat.JPEG0
ImageFormat.PNG1
ImageFormat.BMP2

InputEvent

LabelValueDescription
InputEvent.Pressed0
InputEvent.Released1

KeyModifier

💡TIP
This Enum supports Bitwise Operations!
LabelValueDescription
KeyModifier.None0
KeyModifier.LeftShiftDown1 << 0
KeyModifier.RightShiftDown1 << 1
KeyModifier.LeftControlDown1 << 2
KeyModifier.RightControlDown1 << 3
KeyModifier.LeftAltDown1 << 4
KeyModifier.RightAltDown1 << 5
KeyModifier.LeftCommandDown1 << 6
KeyModifier.RightCommandDown1 << 7
KeyModifier.CapsLocked1 << 8

LightProfile

LabelValueDescription
LightProfile.None0
LightProfile.Arrow_Star1
LightProfile.Arrow_Up2
LightProfile.Beam_013
LightProfile.Beam_024
LightProfile.Beam_035
LightProfile.Beam_046
LightProfile.Beam_057
LightProfile.Beam_068
LightProfile.Beam_079
LightProfile.Beam_0810
LightProfile.Beam_LED_0111
LightProfile.Beam_LED_0212
LightProfile.Beam_LED_0313
LightProfile.Beam_LED_0414
LightProfile.Beam_LED_0515
LightProfile.Beam_LED_0616
LightProfile.Beam_LED_0717
LightProfile.Bow18
LightProfile.Capped_0119
LightProfile.Capped_0220
LightProfile.Shattered_0121
LightProfile.Shattered_0222
LightProfile.Shattered_0323
LightProfile.Shattered_0424
LightProfile.Shattered_0525
LightProfile.SpotLight_0126
LightProfile.SpotLight_0227
LightProfile.SpotLight_0328
LightProfile.SpotLight_0429
LightProfile.Spreadout_0130
LightProfile.Spreadout_0231
LightProfile.Spreadout_0332
LightProfile.Spreadout_0433
LightProfile.Star_Bow34
LightProfile.Star_Burst_0135
LightProfile.Star_Burst_0236
LightProfile.Star_Burst_0337
LightProfile.Star_Burst_0438
LightProfile.Star_Burst_0539
LightProfile.Star_Burst_0640
LightProfile.Star_Burst_0741
LightProfile.Star_Burst_0842
LightProfile.Star_X_0143
LightProfile.Star_X_0244
LightProfile.Wall_Boomerang45
LightProfile.Wall_Inverted_V46
LightProfile.Wall_Star_T47
LightProfile.Wing_648
LightProfile.Wing_V_0149
LightProfile.Wing_V_0250

LogType

LabelValueDescription
LogType.Display0
LogType.Warning1
LogType.Error2
LogType.Debug3
LogType.Verbose4
LogType.Scripting5
LogType.ScriptingWarn6
LogType.ScriptingError7
LogType.Chat8
LogType.WebUI9
LogType.Success10
LogType.Fatal11

LightType

LabelValueDescription
LightType.Point0
LightType.Spot1
LightType.React2

NativeWidget

LabelValueDescription
NativeWidget.Border0
NativeWidget.Button1
NativeWidget.CheckBox2
NativeWidget.Image3
NativeWidget.ProgressBar4
NativeWidget.RichTextBlock5
NativeWidget.Slider6
NativeWidget.Text7
NativeWidget.ComboBox8
NativeWidget.EditableText9
NativeWidget.EditableTextMultiLine10
NativeWidget.SpinBox11
NativeWidget.TextBox12
NativeWidget.TextBoxMultiLine13
NativeWidget.CanvasPanel14
NativeWidget.GridPanel15
NativeWidget.HorizontalBox16
NativeWidget.Overlay17
NativeWidget.ScaleBox18
NativeWidget.ScrollBox19
NativeWidget.SizeBox20
NativeWidget.UniformGridPanel21
NativeWidget.VerticalBox22
NativeWidget.WrapBox23
NativeWidget.BackgroundBlur24

PackageType

LabelValueDescription
PackageType.Script0
PackageType.GameMode1
PackageType.LoadingScreen2
PackageType.Map4

SkyMode

LabelValueDescription
SkyMode.VolumetricClouds0Uses a 3D Volumetric Cloud layer
SkyMode.StaticClouds1Designed to mimic the look of the volumetric clouds but as a static cloud texture. Much lower performance cost than volumetric clouds.
SkyMode.DynamicClouds2D2Uses simple 2D dynamic clouds
SkyMode.NoClouds3Disables all forms of dynamic clouds
SkyMode.VolumetricAurora4Trades clouds for a full 3D volumetric aurora, much more convincing than the 2D effect.
SkyMode.Space5Turns off all sky color, atmospheric scattering, clouds, etc. Specifically for environments which are set in outer space with no planet/ground beneath the camera.

SoundType

LabelValueDescription
SoundType.SFX0
SoundType.Music1
SoundType.UI2

SoundLoopMode

LabelValueDescription
SoundLoopMode.Default0Default value defined in the asset
SoundLoopMode.Forever1Overrides it to make it loop forever
SoundLoopMode.Never2Overrides it to make it play once

StanceMode

LabelValueDescription
StanceMode.None0
StanceMode.Standing1
StanceMode.Crouching2
StanceMode.Proning3

SteeringType

LabelValueDescription
SteeringType.SingleAngle0Both wheels steer by the same amount
SteeringType.AngleRatio1Outer wheels on corner steer less than the inner ones by set ratio
SteeringType.Ackermann2Ackermann steering principle is applied

SurfaceType

LabelValueDescription
SurfaceType.Default0
SurfaceType.Carpet1
SurfaceType.Concrete2
SurfaceType.Grass3
SurfaceType.Gravel4
SurfaceType.Ground5
SurfaceType.MetalLight6
SurfaceType.Plastic7
SurfaceType.Sand8
SurfaceType.Snow9
SurfaceType.Water10
SurfaceType.WoodLight11
SurfaceType.Flesh12
SurfaceType.MetalHeavy13
SurfaceType.WoodHeavy14
SurfaceType.Ice15
SurfaceType.Mud16
SurfaceType.Rock17
SurfaceType.Thump18
SurfaceType.Glass19
SurfaceType.Rubber20
SurfaceType.Air21

SwimmingMode

LabelValueDescription
SwimmingMode.None0
SwimmingMode.Surface1
SwimmingMode.Underwater2

TextRenderAlignCamera

LabelValueDescription
TextRenderAlignCamera.Unaligned0
TextRenderAlignCamera.AlignCameraRotation1
TextRenderAlignCamera.FaceCamera2

TextRenderBevelType

LabelValueDescription
TextRenderBevelType.Linear0
TextRenderBevelType.HalfCircle1
TextRenderBevelType.Convex2
TextRenderBevelType.Concave3
TextRenderBevelType.OneStep4
TextRenderBevelType.TwoSteps5
TextRenderBevelType.Engraved6

TextRenderHorizontalAlignment

LabelValueDescription
TextRenderHorizontalAlignment.Left0
TextRenderHorizontalAlignment.Center1
TextRenderHorizontalAlignment.Right2

TextRenderVerticalAlignment

LabelValueDescription
TextRenderVerticalAlignment.Top0
TextRenderVerticalAlignment.Center1
TextRenderVerticalAlignment.Bottom2
TextRenderVerticalAlignment.QuadTop3

TriggerType

LabelValueDescription
TriggerType.Sphere0
TriggerType.Box1

TraceMode

💡TIP
This Enum supports Bitwise Operations!
LabelValueDescription
TraceMode.DrawDebug1 << 0Whether to draw a 3D line representing the ray
TraceMode.TraceComplex1 << 1Whether should trace against complex collision
TraceMode.ReturnPhysicalMaterial1 << 2Whether want to include the physical material in the results (adds SurfaceType to result)
TraceMode.ReturnEntity1 << 3Whether want to return the Entity hit (adds Entity to result)
TraceMode.ReturnNames1 << 4Whether should return names (adds ActorName, ComponentName and BoneName to result)
TraceMode.ReturnUV1 << 5Whether want to trace and return UV information (adds UV to result)

ViewMode

LabelValueDescription
ViewMode.FPS0
ViewMode.TPS11
ViewMode.TPS22
ViewMode.TPS33
ViewMode.TopDown4

VOIPSetting

LabelValueDescription
VOIPSetting.Local03D Sound
VOIPSetting.Global12D Sound
VOIPSetting.Muted2

WeatherType

LabelValueDescription
WeatherType.ClearSkies1
WeatherType.Cloudy2
WeatherType.Foggy3
WeatherType.Overcast4
WeatherType.PartlyCloudy5
WeatherType.Rain6
WeatherType.RainLight7
WeatherType.RainThunderstorm8
WeatherType.SandDustCalm9
WeatherType.SandDustStorm10
WeatherType.Snow11
WeatherType.SnowBlizzard12
WeatherType.SnowLight13

WebUIModifier

💡TIP
This Enum supports Bitwise Operations!
LabelValueDescription
WebUIModifier.None0
WebUIModifier.CapsLockOn1 << 0
WebUIModifier.ShiftDown1 << 1
WebUIModifier.ControlDown1 << 2
WebUIModifier.AltDown1 << 3
WebUIModifier.LeftMouseButton1 << 4
WebUIModifier.MiddleMouseButton1 << 5
WebUIModifier.RightMouseButton1 << 6
WebUIModifier.CommandDown1 << 7
WebUIModifier.NumLockOn1 << 8
WebUIModifier.IsKeyPad1 << 9
WebUIModifier.IsLeft1 << 10
WebUIModifier.IsRight1 << 11
WebUIModifier.AltgrDown1 << 12
WebUIModifier.IsRepeat1 << 13

WebUIKeyType

LabelValueDescription
WebUIKeyType.Down0
WebUIKeyType.Up1
WebUIKeyType.Char2

WebUIMouseType

LabelValueDescription
WebUIMouseType.Left0
WebUIMouseType.Right1
WebUIMouseType.Middle2

WidgetVisibility

LabelValueDescription
WidgetVisibility.Hidden0
WidgetVisibility.Visible1
WidgetVisibility.VisibleNotHitTestable2