Class Entity
- Namespace
- SharpPluginLoader.Core.Entities
- Assembly
- SharpPluginLoader.Core.dll
Represents a Monster Hunter World uCharacterModel instance.
public class Entity : Model
- Inheritance
-
Entity
- Derived
- Inherited Members
Constructors
Entity()
public Entity()
Entity(nint)
public Entity(nint instance)
Parameters
instance
nint
Properties
ActionController
The entity's action controller
public ActionController ActionController { get; }
Property Value
CollisionComponent
Gets the entity's collision component
public CollisionComponent? CollisionComponent { get; }
Property Value
Methods
CreateEffect(MtObject)
Creates the given effect on the entity
public nint CreateEffect(MtObject effect)
Parameters
effect
MtObjectThe effect to create
Returns
- nint
A handle to the created effect
Exceptions
CreateEffect(EffectProvider, uint, uint)
Creates an effect on the entity from the given epv file
public nint CreateEffect(EffectProvider epv, uint groupId, uint effectId)
Parameters
epv
EffectProviderThe EPV file to take the efx from
groupId
uintThe efx group id
effectId
uintThe efx id
Returns
- nint
A handle to the created effect
Remarks
Tip: You can load any EPV file using GetResource<T>(string, MtDti, LoadFlags)
Exceptions
CreateEffect(uint, uint)
Creates an effect on the entity
public nint CreateEffect(uint groupId, uint effectId)
Parameters
Returns
- nint
A handle to the created effect
Exceptions
CreateShell(ShellParam, Vector3, Vector3?)
Spawns the given shell on the entity
public virtual void CreateShell(ShellParam shell, Vector3 target, Vector3? origin = null)
Parameters
shell
ShellParamThe shell to spawn
target
Vector3The target position of the shell
origin
Vector3?The origin position of the shell (or null for the entity itself)
CreateShell(ShellParamList, uint, Vector3, Vector3?)
Spawns a shell on the entity from the given shll file
public virtual void CreateShell(ShellParamList shll, uint index, Vector3 target, Vector3? origin = null)
Parameters
shll
ShellParamListThe shll file to take the shell from
index
uintThe index of the shell in the entities shell list (shll)
target
Vector3The position the shell should travel towards
origin
Vector3?The origin of the shell (or null for the entity itself)
Remarks
Tip: You can load any shll file using GetResource<T>(string, MtDti, LoadFlags)
CreateShell(int, int)
Spawns a shell on the entity
public virtual void CreateShell(int shllIndex, int shlpIndex)
Parameters
shllIndex
intThe index of the shll in the entities shll list
shlpIndex
intThe index of the shlp in the shll
CreateShell(int, int, Vector3, Vector3?)
Spawns a shell on the entity
public virtual void CreateShell(int shllIndex, int shlpIndex, Vector3 target, Vector3? origin = null)
Parameters
shllIndex
intThe index of the shll in the entities shll list
shlpIndex
intThe index of the shlp in the shll
target
Vector3The position the shell should travel towards
origin
Vector3?The origin of the shell (or null for the entity itself)
CreateShell(uint, Vector3, Vector3?)
Spawns a shell on the entity
public virtual void CreateShell(uint index, Vector3 target, Vector3? origin = null)
Parameters
index
uintThe index of the shell in the entities shell list (shll)
target
Vector3The position the shell should travel towards
origin
Vector3?The origin of the shell (or null for the entity itself)
RegisterShll(ShellParamList, int, bool)
Registers a shll file on the entity
public bool RegisterShll(ShellParamList shll, int index = -1, bool force = false)
Parameters
shll
ShellParamListThe shll to register
index
intThe index at which to register, must be less than 8. Passing -1 for this parameter will register the shll at the first free index.
force
boolWhether to force the registration or not (only works when an index is specified)
Returns
- bool
True if the shll was successfully registered
RegisterShll(string, int)
Registers a shll file on the entity
public bool RegisterShll(string path, int index = -1)
Parameters
path
stringThe path to the shll file
index
intThe index at which to register, must be less than 8. Passing -1 for this parameter will register the shll at the first free index.
Returns
- bool
True if the shll was successfully registered