MOVETYPE
Description
Enumerations used by Entity:SetMoveType and Entity:GetMoveType.
Values
MOVETYPE_NONE | 0 | Don't move |
MOVETYPE_ISOMETRIC | 1 | For players, in TF2 commander view, etc |
MOVETYPE_WALK | 2 | Player only, moving on the ground |
MOVETYPE_STEP | 3 | Monster/NPC movement |
MOVETYPE_FLY | 4 | Fly, no gravity |
MOVETYPE_FLYGRAVITY | 5 | Fly, with gravity |
MOVETYPE_VPHYSICS | 6 | Physics movetype |
MOVETYPE_PUSH | 7 | Doesn't collide with the world, but does push and crush entities. This is what is used by the engine for elevators, trains, doors, moving water, etc. In order to work properly, the entity needs to have specific Save Values/Internal Variables set which tell it how long it should be moving for. Note: This same process can be done for both position and angle. 1. You'll need to Get an existing Save Value called Once the duration of the move has elapsed, the entity will stop moving. If you have done your calculations correctly, it should stop exactly at the desired destination. MOVETYPE_PUSH entities only move during Entity:Think so if you want smooth movement, you need to set Entity:NextThink to CurTime, which instructs the entity to execute Entity:Think as quickly as possible. |
MOVETYPE_NOCLIP | 8 | Noclip |
MOVETYPE_LADDER | 9 | For players, when moving on a ladder |
MOVETYPE_OBSERVER | 10 | Spectator movetype. DO NOT use this to make player spectate |
MOVETYPE_CUSTOM | 11 | Custom movetype, can be applied to the player to prevent the default movement code from running, while still calling the related hooks |