Hey there, I’m having an error in the output that appears just now.
exception while signaling: Model:GetPrimaryCFrame() failed because no PrimaryPart has been set, or the PrimaryPart no longer exists. Please set Model.PrimaryPart before using this.
This has never happened to me before, and before you ask more, I did check the whole game for scripts that uses the function, and there’s no script. Also, I checked for viruses and used ScriptContext. No error was printed and there weren’t any viruses. You can’t trace back the script that is causing the error either, there was only a red text and non-clickable.
Edit: This error starts appearing when I started joining the game.
For your first issue, make sure you set your PrimaryPart of your model, whether you do it in script or through studio’s Properties, you need to make sure you have a PrimaryPart set for your model before calling GetPrimaryPartCFrame()
For the second issue, it seems to me that the script isn’t waiting for Ocean to load in. Make sure you use WaitForChild() so instances can load into the workspace.
If you can click it while you are testing, you could try adding something like “print(script.Parent, script.Name)” to find out which script is printing this error.
Also is the model that you are trying to get the primary CFrame from a model you made or a character model from a player? Also like @CapnFry mentioned, maybe the model didn’t exist yet so using WaitForChild() should solve it, you are meant to use :GetPrimaryCFrame() on a model if you didn’t realize yet, you probably knew that but just saying.
Thanks for the suggestion. I just tried adding :WaitForChild() and it no longer shows the error, but the CFrame issue is still there.
As for the first issue, every model in my game has a PrimaryPart already. Don’t understand why it is showing that error.
As I mentioned, there wasn’t any script in my game that was using this function. Printing wouldn’t work either (ScriptContext) so I think maybe this issue isn’t script-made (is that even possible?).
That isn’t possible so it has to be an error in a script you made, maybe you (accidentaly) removed a primarypart/model but you forgot to remove the script that tries to get the primary part cframe of the removed model?
Most scripts are in ServerScriptService; there are some in models, but I checked every of them and there were none of them that were trying to get the PrimaryPart’s CFrame.
There aren’t any script that was trying to grab the PrimaryPart’s CFrame.
Also, I did try the print and there weren’t any errors. But the error shows when I begin joining the game, so maybe it’s an Engine Bug?
I don’t see how the first statement you said creates a problem for finding the Primary Part’s CFrame, but could you show me the error please? I highly doubt it is an Engine Bug.
It’s because I mentioned upon, I said I was having that error but I don’t know the cause of that problem. I can’t trace back, it almost seems like there was no script causing the error.