Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to make/code/create a flying enemy/NPC? [closed]

Asked by 3 years ago
Edited 3 years ago

I want to have a flying NPC which can go up or down depending if the terrain is higher than up (the NPC levitates up) or if they are attacking ground NPCs (could just levitate) or other flying NPCs (below or higher than the NPC). The thing is, I dunno where to start, I tried using BodyVelocity and BodyPosition, it did not work out well as I expected. Would I use Cframe or would I use a modified version of pathfinding (using Y value) to get the NPC to fly.

EDIT: THIS QUESTION IS 10 DAYS OLD YET IT IS MODERATED BRUH

0
Raycast from the NPC to the ground and use BodyPosition to move it to the designated Y value which is just the Y co-ordinate of the ground + the amount you want to hover. radiant_Light203 1166 — 3y
0
I am not familiar with raycasting tho. I would just have to learn it. L0RD_Bloxx -5 — 3y

Closed as Not Constructive by IAmNotTheReal_MePipe, User#32819, Cynical_Innovation, and Leamir

This question has been closed because it is not constructive to others or the asker. Most commonly, questions that are requests with no attempt from the asker to solve their problem will fall into this category.

Why was this question closed?