#how do i make the minimap accurately show where the player is standing on the PlayerPoint

1 messages · Page 1 of 1 (latest)

thorny burrow
#

local RunService = game:GetService("RunService")
local Players = game:GetService("Players")

local Player = Players.LocalPlayer
local Character = Player.Character or Player.CharacterAdded:Wait()
local HumanoidRootPart = Character:WaitForChild("HumanoidRootPart")

local LobbyFolder = game.Workspace:FindFirstChild("Lobby")
local MapFolder = game.Workspace:FindFirstChild("Map")
local MapFrame = script.Parent.MinimapFrame
local playerpoint = MapFrame.PlayerPoint

local Camera = Instance.new("Camera")
Camera.CameraType = Enum.CameraType.Scriptable
Camera.FieldOfView = 3
MapFrame.CurrentCamera = Camera

if MapFolder then

local TeamASpawns = game.Workspace:WaitForChild("TeamASpawns")
local TeamBSpawns = game.Workspace:WaitForChild("TeamBSpawns")
local Lobby = game.Workspace:WaitForChild("Lobby")

local folders = {MapFolder, TeamASpawns, TeamBSpawns, Lobby}

for _, folder in ipairs(folders) do
    for _, object in ipairs(folder:GetDescendants()) do

        if object:IsA("BasePart") then
            local Clone = object:Clone()
            Clone.Parent = MapFrame
        end

    end
end

end

RunService.RenderStepped:Connect(function()
if HumanoidRootPart then
Camera.CFrame = CFrame.new(HumanoidRootPart.Position + Vector3.new(0, 3000, 0), HumanoidRootPart.Position)
end
end)

buoyant perch
thorny burrow
#

it didnt work

#

@buoyant perch

buoyant perch
thorny burrow
#

not accurate

#

the white dot is me

#

@buoyant perch

buoyant perch
#

so make it accurate?

#

wait wait wait

thorny burrow
#

how?

buoyant perch
#

don't tell me

thorny burrow
#

thats the whole question i had

#

the script has no errors

buoyant perch
thorny burrow
#

no

#

u didnt change anything

#

what am i supposed to do im asking u

buoyant perch
thorny burrow
#

yea i know

#

is it the Vector3.new(0, 3000, 0)

#

?

#

am i supposed to change that

#

its confusing

buoyant perch
#

like

#

it should always be at the center

#

you probably don't even need to move it, just put it in the center lol

thorny burrow
#

yea whats the center 😭

#

xyz

#

idk it

buoyant perch
#

oh for guis?

#

thats easy

thorny burrow
#

yea

buoyant perch
#

anchor=0.5,0.5 position=fromscale(0.5,0.5)

thorny burrow
#

alr thanks

thorny burrow
#

wait u understood me wrong

buoyant perch
#

it basically moves the 'center' of the frame to the % of 0~1

#

instead of just being topleft at 0,0

thorny burrow
#

the position of the white dot (which is the player) is supposed to be accurate at the place the player is standing

buoyant perch
thorny burrow
#

yea

buoyant perch
#

you're moving the camera directly over the player, so the player is always at the center, ya?

thorny burrow
#

yea

buoyant perch
#

so just put a dot at the center and stop overthinking it?

thorny burrow
#

hm lemme try

#

now it isnt displaying the map

buoyant perch
#

for other players though, you're asking about translating world vector3 coordinate into a local vector2 coordinate relative to the viewportframe's camera

buoyant perch
thorny burrow
#

alr

buoyant perch
#

but essentially, you would need to translate the relative coordinate from the camera into 2d vector, and then put that relative to the viewportframe

#

you obv need to know how to code to make this

#

and need to know some geometry math like working with vec3's and vec2's

thorny burrow
#

i do know i just find this hard to do for some reason

#

yeaa

buoyant perch
#

and how to translate between different coordinate frames

#

its just math

thorny burrow
#

alright bro thanks it worked

#

i changed the vec

buoyant perch
buoyant perch
thorny burrow
#

yea i have the local script inside the minimap

acoustic sedgeBOT
#

studio** You are now Level 12! **studio

grave mountain
thorny burrow
#

whats codify

grave mountain
#

it basically turns an instance into lines of code

buoyant perch
#

wtf

#

actual scam

grave mountain
#

i dont remember it being $13

buoyant perch
#

uh hang on thats probably local currency

grave mountain
#

i think they changed that

buoyant perch
#

USD$9

grave mountain
#

no its also $13 for me

buoyant perch
#

either case who tf is paying $10 to do this

grave mountain
#

dude what

#

i swear it was free

#

like

#

2 - 3 years ago maybe idk

#

might be hallucinating but whatever idrk

buoyant perch
#

actual scam

grave mountain
#

is this even the real one

thorny burrow
#

id'e rather do that shi my self

#

not hard