Hello, I'm trying to morph into a model tool made of meshes I created in Blender, and I need some help fixing problems I've run into. I'm trying to morph myself into the tool by equipping it. I still want to be able to freely move around and jump and stuff, I just want to be the tool. I'm having several problems with this. First, it doesn't even morph; when I equip the tool, it just appears where the model last was, not in my hand nor as my character. The tool has RequireHandle set to false, and when it's true and I name a part "Handle" it still doesn't work. I've also tried morphing using a proximity prompt, which kind of works. Three problems with that: 1) I morphed into the model, but whenever I do the camera stays fixed where my old character was. I've tried setting the camera subject to the new model's HumanoidRootPart in the script but that didn't work. 2) The red outline that shows up when you die appears when I morphed. 3) The morph would only work for a few seconds before disabling, changing my character back, and putting me in a spawn location. I don't know what to do. I'm using a regular script in the tool and using PlayHere to test. This is my code:
local tool = script.Parent local morph = tool:FindFirstChildOfClass("Model") tool.Equipped:Connect(function(player) print("Works") local oldchar = player.Character local newchar = morph newchar:SetPrimaryPartCFrame(oldchar.PrimaryPart.CFrame) player.Character = newchar newchar.Parent = workspace end)
The print statement does work, and the only error I'm getting is: Character is not a valid member of Mouse "Instance"
I don't know what that error means. I never mentioned the mouse or used Instance.new in my code. Please, could someone help? I'm stuck.
Hi Try this code and see if it works, player is probably referring to mouse,
-- Put in a local script local tool = script.Parent local morph = tool:FindFirstChildOfClass("Model") tool.Equipped:Connect(function(player) print("Works") local oldchar = game.Players.LocalPlayer.Character local newchar = morph newchar:SetPrimaryPartCFrame(oldchar.PrimaryPart.CFrame) newchar.Parent = workspace oldchar.Character = newchar end)