Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Clickdetector to operate a RemoteEvent FireServer?

Greetings,

Is it possible to have a click detector function a FireServer()

Because need to have some animations with a Motor Desire Angle, It works on a tool but would like to have it as a button

Regards, If its even possible?

plane = script.Plane.Value

wait(3)
script.EngineThudIgnitor:Play()
script.Parent.Parent.Parent.Switch.CockpitDisplays.Display3.Main.EngineStats.MessageBpx.Startvalue1.Visible = true
script.Parent.Parent.Parent.Switch.CockpitDisplays.Display3.Main.EGT1.TrottleBox.Visible = true
script.Parent.Parent.Parent.Switch.CockpitDisplays.Display3.Main.EGT1.ValueText.Visible = true
wait(3.5)
	plane.Parent.Engine_Start1:FireClient()
end

2 comments

0

it is possible.

0

Can't fireserver from server script. Only local scripts can do that.

1 answer

it is possible to get a player from a clickdetector(ish). so with that we can(should be able to) FireServer() from a clickdetector:

local click_detector = -- your click detetcor
local remote_event = -- your remote event

click_detector.MouseClick:connect(function(player)
	remote_event:FireClient(player)
end)

6 comments

0

I need to use it as a toggle switch for the engine fans to operate as a Filter Enabled capacity.

0

cant you use bindable events?

0

ok but i didnt getwhat u meant can u elaborate

0

When a player clicks the switch on the engine, I need the Motor to be compatible for the Filtering Enable for other players to see the motion/Animations

0

but cant u do that already?

0

ok whatever. fine

This discussion is preserved as it was. New answers, comments, and votes are closed.