How to make a proximity prompt activate a cutscene

Title says it all. I’m trying to make a proximity prompt activate a cutscene. Can’t get anything to work.

1 Like

You have to use a remote event and fire it to the player who triggers the prompt

1 Like

How would I do that? I think I did it wrong last time.

Could you send a screenshot of your script ?

1 Like

Script in the proximity promt

script.Parent.Triggered:Connect(function(Player)
	script.Parent.Parent.Parent.Parent.Value.Value = true
	game.ReplicatedStorage.HouseBuyCutscene.next:FireClient(Player)
	print("true")
end)

Local Script in ServerScriptService

game.ReplicatedStorage.HouseBuyCutscene.next.OnClientEvent:Connect(function(player)
	local camera = game.ReplicatedStorage.HouseBuyCutscene.Camera:Clone()
	camera.Parent = player.PlayerScripts
	local Cutscene = game.ReplicatedStorage.HouseBuyCutscene.Animation:Clone()
	Cutscene.Parent = player.PlayerScripts
end)

When you receive the event on local side you don’t get a player variable, you have to change “player” to “game.Players.LocalPlayer” this should work, if not have you looked into the output ?

1 Like

Like this?

game.ReplicatedStorage.HouseBuyCutscene.next.OnClientEvent:Connect(function(player)
	local camera = game.ReplicatedStorage.HouseBuyCutscene.Camera:Clone()
	camera.Parent = game.Players.LocalPlayer.PlayerScripts
	local Cutscene = game.ReplicatedStorage.HouseBuyCutscene.Animation:Clone()
	Cutscene.Parent = game.Players.LocalPlayer.PlayerScripts
end)
1 Like

You can use a remote function to fire a function for all clients and make cutscenes with waypoints and CurrentCamera manipulation. You can also slide in some dialogue for the fancy of it.

1 Like

Still cant get it to work. (charlimit)