Press button to give the ui another player

  1. What do you want to achieve? I want to make press ground crew button to give another player the ui.

  2. What is the issue? doesnt give ui to other player also not saying success.
    https://gyazo.com/ed7866dd95d5f5d6c76103b61a9ccbc5

  3. What solutions have you tried so far? There were no solutions.

mouse.Button1Down:Connect(function()
	local target = mouse.Target
	if target.Parent:FindFirstChild("Humanoid") and target.Parent ~= game.Workspace then
		Username_Frame.Text = target.Parent.Name
		GC.MouseButton1Click:Connect(function()
			target.Parent.AssignedFrame.Visible = true
			Username_Frame.Text = "Success!"
			wait(2)
			Username_Frame.Text = "USERNAME"
		end)
	end
end)

Can you give us the exact workspace ?

What do you mean workspace? Like how it works? Or picture of UI?

The thing you just posted. So i could see if you got the placement right or something.


Here you go.

1 Like

What is “GC”? in your scrip have it

GC

local player = game.Players.LocalPlayer

local AssignFrame = script.Parent.AssignFrame

local AssignedFrame = script.Parent.Assigned

local Username_Frame = script.Parent.AssignFrame.Username

local mouse = player:GetMouse()

--Department Button

local GC = AssignFrame.GC

local CC = AssignFrame.CC

local CPT = AssignFrame.Captain

local FO = AssignFrame.FO

local Supervsor = AssignFrame.Supervisor

local CoHost = AssignFrame["Co-Host"]

it a job name for our company.

Oh it’s ground crew nvm im just dumb.

Can you get the Humanoid exactly ?

Hm. but how. I only know like touch player.

If you found the Humanoid for real, you want to use print so that if it can get the Humanoid then it will print something.

And does the target have the “AssignedFrame” ? Because the “Target.Parent” is refering to the player char then you put “AssignedFrame”

Target.Parent is for the name.

Yes. Player will get assignedframe when they got role.

The Name ? i see that the Target.Parent is the character because your trying to find the Humanoid out of it.

Ohhh yes. I am using that. And then I press button and give them a role.

So what your trying to say is that it is a character. And if you will give the frame can you show the script that gives the player the Frame ?

image

No like the script that gives the assigned Frame, this show the part where you get it and not give it.