Powerlang Docs
  • Welcome!
  • Beginner's Guide
    • Syntax
    • Directives
    • Environment
    • Special types
    • Functions
    • Tables
    • Loops
    • Conditions
    • Events
    • Libraries
    • Comments and Flags
  • Creating a Game
    • Project Introduction: Potato Rush
    • Creating the main game loop
    • Creating potatoes
    • Keeping track of score
  • Libraries
    • Special Types
      • BrickColor
      • CFrame
      • Color3
      • Instance
      • NumberRange
      • UDim2
      • Vector2
      • Vector3
    • Services
      • DataStore
      • Debris
      • Mouse
      • Pathfinding
      • PhysicsService
      • Players
      • Ray
      • TweenService
    • compiler
    • math
    • os
    • string
    • table
    • retrostudio
  • Advanced Information
    • Instance Functions
    • Global Functions
    • Multithreading
    • Compiler Library
Powered by GitBook
On this page
  1. Libraries
  2. Services

Pathfinding

The Pathfinding service allows you to trace a path (start to end) for a humanoid character to walk.

Function

Description

ComputePath(StartPosition: Vector3, EndPosition: Vector3): {Vector3}

Computes a path from a starting position to an ending position using Roblox's pathfinding service. Requires 2 arguments: StartPosition (of type Vector3) representing the starting point and EndPosition (of type Vector3) representing the destination. Returns a table of Vector3s representing the computed path.

PreviousMouseNextPhysicsService

Last updated 7 months ago