Remote Event isn't sending it signals

I’ve scripted a remote event to activate when a certain key is being pressed. upon the first test, I noticed that the script was not working yet there were no errors. In order to find my source of the problem, I put a print statement to tell me when the script has gone through the line of codes. I finally found the source and it was the remote. For some odd reason, the remote is not sending its signals to the server. I found this out when the print statement I had at the beginning was not printing in the output. How can I fix this?

[Local Script]

print ("P1")

local Remote = game.ReplicatedStorage.SpriteDiveRemote
--local YunoFolder = YunoFolder:WaitForChild("meshes")
print ("P3")
local UIS = game:GetService("UserInputService")
local x1 = false
print ("P4")



UIS.InputBegan:Connect(function(Input,GP)
	if GP then return end
	if Input.KeyCode == Enum.KeyCode.B and not x1 then
		x1 = true
		print "B0"
		Remote:FireServer()
		print "B00"
		wait(60)
		x1 = false
	end
end)

[Server Script]

print ("11")
local Remote = game.ReplicatedStorage.SpriteDiveRemote
local YunoFolder = game.ReplicatedFirst:WaitForChild("Yuno")
local BodyParts = YunoFolder.meshes
local TweenService = game:GetService("TweenService")

print "B1"

--Script Start
Remote.OnServerEvent:Connect(function(Plr)
	local plr = game.Players.LocalPlayer or Plr
	local Character = plr.Character or plr.CharacterAdded:Wait()
	local RightFoot = Character:WaitForChild("RightFoot")
	--Body Parts
	local UpperArm = BodyParts.URight
	local MiddleArm = BodyParts.MRight
	local Hand = BodyParts.BRight
	local Wings = BodyParts.Wings
	local Halo = BodyParts.Halo
	print "B2"
	--Body Parts Ends here
	
	
	--Meshes
	local BottomWind = BodyParts.BottomWind
	
	print "B3"
	--Meshes Ends here
	
	
	--TweenServices Start
	
	local WingSwirlInfo = TweenInfo.new(2.1,Enum.EasingStyle.Sine,Enum.EasingDirection.InOut,4,false,0)
	local BottomWindTween = TweenService:Create(BottomWind,WingSwirlInfo,{Orientation = CFrame.fromOrientation(0,360,0)})
	
	print "B4"
	
	
	
	
	
	--TweenServices ENd
	
	--scripty
print ("Dive!")
	
end)

[Game File]
SpiritDiveSupport.rbxl (70.1 KB)

Hello!
Sorry for my English, I use translator
You accidentally turned to ReplicatedFirst, although ‘Yuno’ itself is located in ReplicatedStorage. The WaitForChild function stopped the thread and warned the console that it could not find such a folder as “Infinite yield possible on’ ReplicatedFirst:WaitForChild(“Yuno”)'”.

game.ReplicatedStorage:WaitForChild("Yuno")
1 Like

To add onto what @Landlord2107 mentioned, after applying the mentioned fix,you’re also erroring because you gave a CFrame instead of a Vector3 for the Orientation, You should check that out as well

2 Likes

Thank you so much. I probably didn’t see this error because I was working on it at 2 in the morning.

1 Like

I’m still kind of new to scripting therefore I have no idea how to rotate it. Sorry about the question but how would I rotate it with Vector3?

I think you could use Orientation = Vector3.new(0,360,0), or if you want to add it with your thing, Orientation = Part + Vector3.new(0,360,0), where Part is the thing being tweened

1 Like

You are accessing an object hidden in ReplicatedStorage

local YunoFolder = game.ReplicatedStorage:WaitForChild("Yuno")
local BodyParts = YunoFolder.meshes

, and you are going to rotate it. I don’t quite understand your purpose. I noticed that this folder, is a clone of the folder located in workspace " workspace.Yuno". Maybe you mean the object which one is depicted on the stage?

If so, as you guessed, you can use TweenService here, only this time you made a small mistake.

In your example, you create a tween with erroneous values, as @EmbatTheHybrid mentioned, since you set the Vector3 parameter to CFrame.
You want to rotate the object, you can do it like this using CFrame
So with the use of the standard Orientation property.

Your tween object may look like this:

local BottomWindTween = TweenService:Create(BottomWind,WingSwirlInfo,{Orientation=BottomWind.Orientation+Vector3.new(0,360,0)})

or

local BottomWindTween = TweenService:Create(BottomWind,WingSwirlInfo,{CFrame = BottomWind.CFrame*CFrame.Angles(0,math.rad(360),0)})


Next, you should call it using the tween:Play function.()

BottomWindTween:Play()

As a result, your code should work :smiley:

	print "B3"
	--Meshes Ends here
	
	
	--TweenServices Start
	
	local WingSwirlInfo = TweenInfo.new(5,Enum.EasingStyle.Sine,Enum.EasingDirection.InOut)
	local BottomWindTween = TweenService:Create(BottomWind,WingSwirlInfo,{CFrame = BottomWind.CFrame*CFrame.Angles(math.rad(180),math.rad(360),0)})
	BottomWindTween:Play()
	print "B4"