Getting player information from a group and trying to apply the info

I’m trying to get player information from a group and trying to apply the info into a surface GUI but it’s not working, Here is the code:

game.ReplicatedStorage.RemoteEvent.OnServerEvent:Connect(function(plr,name,age,rank,another)

	local headshot = Enum.ThumbnailType.HeadShot
	local headshotSize = Enum.ThumbnailSize.Size100x100

	game.StarterPack.key.Handle.SurfaceGui.name.username.Text = name
	game.StarterPack.key.Handle.SurfaceGui.rank.grouprank.Text = rank
	game.StarterPack.key.Handle.SurfaceGui.age.accountage.Text = age

	game.StarterPack.key.Handle.SurfaceGui.headshot.Image = another:GetUserThumbnailAsync(plr.UserId, headshot, headshotSize)


end)

What is showing:

https://gyazo.com/2062e8b7c7cadc6abeab6520f79bcd93

First off we would need more information such as the client sided script that firing the remote. It most likely that the arguments you are sending to the server are “nil” or “N/A”. However, I don’t see why you need the client to send any information to the server. You can just get all the information on the server using the following :

Player.Name; -- The players name
Player:GetRoleInGroup(GroupID); -- Gets the rank name
Player.AccountAge; -- The players account age in days

game.ReplicatedStorage.RemoteEvent.OnServerEvent:Connect(function(plr,name,age,rank,another)

	local headshot = Enum.ThumbnailType.HeadShot
	local headshotSize = Enum.ThumbnailSize.Size100x100

	game.StarterPack.key.Handle.SurfaceGui.name.username.Text = plr.Name;
	game.StarterPack.key.Handle.SurfaceGui.rank.grouprank.Text = plr:GetRoleInGroup(GroupId); -- Put your group id here
	game.StarterPack.key.Handle.SurfaceGui.age.accountage.Text = plr.AccountAge; 

	game.StarterPack.key.Handle.SurfaceGui.headshot.Image = another:GetUserThumbnailAsync(plr.UserId, headshot, headshotSize)


end)

Make sure to put your group id where it says

It’s still now working. I tried the code. same thing

Can you screenshot the output?

Also make sure you have set the group ID since all I put was “GroupId”

No output, I did put the groupid

Your main problem is that you are changing objects in the StarterPack. When the player joins, everything in the starter pack gets cloned into the player’s backpack. You are trying to change the objects in starter pack, which will not do anything because nobody has the objects in starter pack. You need to be changing the objects in the player’s backpack. Thats where the all of the player’s tool go.