I have experience when working with filtering enabled, in this case I've just created a new place and am relying on a RemoteFunction. However, nothing seems to be happening, no errors, no prints to the output, nothing. I have included my relevant place hierarchy.
Could this be a bug, am I doing something wrong?
Workspace > ReplicatedStorage > RemoteEvents > Dupe [RemoteFunction] > Script
Players > Player > PlayerGui > ScreenGui > LocalScript
and my code:
-- Server script
local sp = script.Parent
function sp.OnServerInvoke(player, argument)
print("Remote function invoked")
print(argument[1].Name)
print(argument[2].Name)
local new = argument[1]:Clone()
new.Parent = argument[2]
return new
end
-- Localscript (context only)
if key == "x" then
if plane.Engine:findFirstChild("FlyScript") then
game.ReplicatedStorage.RemoteEvents.DestroyInstance:FireServer(plane.Engine)
plane.Engine.BodyVelocity.maxForce = Vector3.new(0,0,0)
plane.Engine.BodyGyro.maxTorque = Vector3.new(0,0,0)
game.ReplicatedStorage.RemoteEvents.EditProperty:FireServer(plane.Engine.On, "Value", false)
else
print("doesn't exist should clone")
FS = game.ReplicatedStorage.RemoteEvents.Dupe:InvokeServer({script.FlyScript, plane.Engine})
game.ReplicatedStorage.RemoteEvents.EditProperty:FireServer(FS, "Disabled", false)
plane.Engine.BodyVelocity.maxForce = Vector3.new(2000000000,2000000000,2000000000)
plane.Engine.BodyGyro.maxTorque = Vector3.new(0,9000,0)
game.ReplicatedStorage.RemoteEvents.EditProperty:FireServer(plane.Engine.On, "Value", true)
end
end
I appreciate your time and efforts.
