Argument 1 missing or nil?

Hello, I am trying to apply the humanoid’s description from an ID to the server but something went wrong. I got an error ‘Argument 1 missing or nil’, but I do not know what could be causing this. Here’s the portions of the scripts related to the problem:

local targetHumanoidDescription = players:GetHumanoidDescriptionFromUserId(UserInfo.Id)
event:FireServer(dummyHumanoid,targetHumanoidDescription)
event.OnServerEvent:Connect(function(plr,dummyHumanoid,desc)
	dummyHumanoid:ApplyDescriptionReset(desc,Enum.AssetTypeVerification.Default)
end)

Anyways, help is appreciated

Is the dummyHumanoid exists on the server-side?

I have it defined on the client, but its already there without any scripts.

So the reason that it is not working is that dummyHumanoid that you sent is not existed on server-side. Also even the dummy is existed on client and you sent it to the server. The server cannot see it unless the dummy is generated directly by the server itself.

What do you mean that the dummy is generated directly by the server itself?

Using Script to create that dummy. How do you put that dummy in the game? Are you using LocalScript or Script?

I created that dummy without a script tho?

Oh, so you simply put it inside the workspace manually.

Nevermind, I found the solution…
I just sent the ID to the server and then got the description and applied it
Thank you for the help

1 Like

Then, there is an alternative for this. You can try sending the name of the dummy instead of the whole model and let the server look that up itself.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.