#I Cant Make it
51 messages · Page 1 of 1 (latest)
does everyone have to see it or just the player?
heres a basic code for making it appear behind the player
everyone have to see it
like a chasing scene
alright
i made everything like animation model
is your monster one part/a mesh, or is it a multiple part model?
Multiple Part Model
If its a monster/creature it has a humanoidrootpart, right?
Yea
ok
heres how you can make anything appear behind the player
—local script
local Player = game.Players.LocalPlayer
local Character = Player.Character or Player.CharacterAdded:Wait() — basically either references the character or waits for it to load since characteradded returns the character
local HRP = Character:WaitForChild(“HumanoidRootPart”)
local Monster = workspace:WaitForChild(“MonsterName”) — path to your monster and also i will for the sake of simplicity assume your monster is one part. ChNge the path to your monster as needed
local MonsterHRP = Monster:WaitForChild(“HumanoidRootPart”)
— im not sure what you use to signal the monster to move but heres how it should look (code for monster being behind player)
MonsterHRP.Position = HRP.Position - Vector3.New(x, y, z) — this is dependsnt on the monster being rigged and following the humanoidrootpart, also, take into consideration this changes only the position not the cframe, meaning orientation stays the same as previous. i suggest tweaking the cframe instead as this is just a basic code.
the - line should be used to calculate behind trhe player, and again, i suggest using cframe as this is a very basic vector3 system
im just trying to make a block when a playerit monster will appear
just put this line: MonsterHRP.Position = HRP.Position - Vector3.New(x, y, z) into the Part.Touched event
use the Part.Touched event to check then
and also be sure to check if its the player touching it
using Part.Touched:Connect(function(Hit)
if Hit.Parent:FindFirstChild(“Humanoid”) then
MonsterHRP.Position = HRP.Position - Vector3.New(x, y, z)
end
end)
be sure to include the variables and happy coding
thanks
welcome
@olive ledge
im still trying to use the code
if you have time
can you help me with it on studio
im a little busy right now, i'll see
okay imma wait : )
@olive ledge are you still busy?
I got off pc
but im still here to help
Alright
heres a rundown of how to use my script
well its kind hard to explain but easy to execute
look it wont make sense unless i either spoon feed u
or you know something about scripting
from what i understand is that you’re really new to scripting and know 0 for now
yeah you're right
i suggest learning the basics, but just the basics, and then starting to apply your own knowledge
use chatgpt to help explain topics or thinfs you’d like to know
but not for script creation
i got your script but i dont know how to change the setting's of that
it's the problem
its good you understoos