IsPointWithinColshape

From RAGE Multiplayer Wiki
Revision as of 18:26, 28 November 2019 by Xabi (talk | contribs) (Created page with "Checks whether a point is into the given colshape. {{CSharpContainer| {{#tag:syntaxhighlight|ColShape {{Template:CSharp_Serverside_namespace}}ColShape.IsPointWithinColshape(...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Checks whether a point is into the given colshape.


C# Syntax

ColShape NAPI.ColShape.IsPointWithinColshape(ColShape colShape, Vector3 point);

Parameters

  • colShape: parameter input should be in ColShape type
  • point: parameter input should be in Vector3 type


Example

[Command("incolshape")]
public void InColshapeCommand(Client player)
{
    ColShape cylinder = NAPI.ColShape.CreateCylinderColShape(new Vector3(), 10.0f, 5.0f);
    bool pointInside = NAPI.ColShape.IsPointWithinColshape(cylinder, player.Position);
}