Skip to content

Entities ​

Group entities · 9 exports · from forks/gamexueren/scripthook.h (framework 1.0-beta7-wildm1, SH_API_VERSION 2)

Enumeration by kind, via the net identity component.

ExportSummary
ShPlaceEntityPlace any entity through the engine's set transform.
ShPlaceEntityRotFull orientation in radians, which ShPlaceEntity cannot express: roll puts a car on its roof.
ShGetEntityTransformIts inverse: where a thing is and how it is turned, so a caller can rotate relative to that.
ShQueueTransformApplied on the frame path rather than right now.
ShFindEntitiesFills out with entities within radius of the player, nearest first.
ShGetEntityKindKind of one entity.
ShKindNameThe readable name of a kind.
ShGetComponentsFills out with the entity's components, returning how many were written.
ShFindComponentThe component of a given class, or 0.

ShPlaceEntity ​

c
SH_API int  ShPlaceEntity(uint64_t entity, const ShVec3 *pos,
                          const ShVec3 *orient);

Place any entity through the engine's set transform. Children follow, which is how vehicles carry riders.

scripthook.h, line 671

ShPlaceEntityRot ​

c
SH_API int  ShPlaceEntityRot(uint64_t entity, const ShVec3 *pos,
                             float yaw, float pitch, float roll);

Full orientation in radians, which ShPlaceEntity cannot express: roll puts a car on its roof.

scripthook.h, line 677

ShGetEntityTransform ​

c
SH_API int  ShGetEntityTransform(uint64_t entity, ShVec3 *pos,
                                 float *yaw, float *pitch,
                                 float *roll);

Its inverse: where a thing is and how it is turned, so a caller can rotate relative to that.

scripthook.h, line 683

ShQueueTransform ​

c
SH_API int  ShQueueTransform(uint64_t entity, const ShVec3 *pos,
                             float yaw, float pitch, float roll);

Applied on the frame path rather than right now. Set transform wants a game thread's scratch allocator.

scripthook.h, line 690

ShFindEntities ​

c
SH_API int  ShFindEntities(int kind, float radius, uint32_t flags,
                           ShEntity *out, int max);

Fills out with entities within radius of the player, nearest first. Returns how many were written.

scripthook.h, line 726

ShGetEntityKind ​

c
SH_API int  ShGetEntityKind(uint64_t entity);

Kind of one entity.

scripthook.h, line 730

ShKindName ​

c
SH_API const char *ShKindName(int kind);

The readable name of a kind.

scripthook.h, line 732

ShGetComponents ​

c
SH_API int ShGetComponents(uint64_t entity, ShComponent *out,
                           int max);

Fills out with the entity's components, returning how many were written. A vehicle carries about fifty.

scripthook.h, line 747

ShFindComponent ​

c
SH_API uint64_t ShFindComponent(uint64_t entity,
                                uint32_t classHash);

The component of a given class, or 0.

scripthook.h, line 751

WildM is an independent community project. It is not affiliated with or endorsed by Ubisoft. Ghost Recon Wildlands is a trademark of Ubisoft Entertainment.