:ApplyDescription() not working on ViewportFrame

So im trying to create a system that will display a set of photos of people on the ride.

Heres the code:

local Trigger = workspace.RidePhotos.MegafobiaRide.RidePhotosServer.Megafobia_RidePhotos.Trigger.Value
local StartScreen = workspace.RidePhotos.MegafobiaRide.RidePhotosServer.Megafobia_RidePhotos.StartScreen.Value
local RidePhotoGUI = workspace.RidePhotos.MegafobiaRide.RidePhotosServer.Megafobia_RidePhotos.RidePhotoGUI.Value
local RidePhotoEvent = workspace.RidePhotos.MegafobiaRide.RidePhotosServer.Megafobia_RidePhotos.RidePhotoEvent.Value
local Tills = workspace.RidePhotos.MegafobiaRide.RidePhotosServer.Megafobia_RidePhotos.Tills.Value
local TillGUI1 = game.StarterGui.MegafobiaTillGUI
local Screens = workspace.RidePhotos.MegafobiaRide.RidePhotosServer.Megafobia_RidePhotos.Screens.Value
local ScreenDisplaying = workspace.RidePhotos.MegafobiaRide.RidePhotosServer.Megafobia_RidePhotos.ScreenDisplayingPhoto.Value
local Players = game:GetService("Players")

NumberOfScreens = 16

RidePhotoEvent.OnClientEvent:Connect(function()
	RidePhotoGUI.PhotoNumber.Value+=1
	local PhotoClone1 = script.Parent.MegafobiaRidePhoto:Clone()
	PhotoClone1.Parent=Players.LocalPlayer.PlayerGui
	PhotoClone1.Adornee=Screens["1"].Screen
	print("Photo is on screen")
	PhotoClone1.PhotoNumberText.Text=tostring(PhotoClone1.PhotoNumber.Value)
	wait()
	PhotoClone1.ViewportFrame.ZIndex+=1
	PhotoClone1.ImageLabel1.ZIndex+=1
	PhotoClone1.ImageLabel2.ZIndex+=1
	PhotoClone1.PhotoNumberText.ZIndex+=1
	
	workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar1.Seat:GetPropertyChangedSignal("Occupant"):Connect(function()
		if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar1.Seat.Occupant~=nil then
			local P1S1PlayerAppearance = Players:GetHumanoidDescriptionFromUserId(game.Players[workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar1.Seat.Occupant.Name].UserId)
			local P1S1Dummy = PhotoClone1.ViewportFrame.Seat1.Humanoid:ApplyDescription(P1S1PlayerAppearance)
			print("Player is in seat so viewportframe dummy not destroyed:S1C1")
		end
	end)
	workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar2.Seat:GetPropertyChangedSignal("Occupant"):Connect(function()
		if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar2.Seat.Occupant~=nil then
			local P1S2PlayerAppearance = Players:GetHumanoidDescriptionFromUserId(game.Players[workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar2.Seat.Occupant.Name].UserId)
			local P1S2Dummy = PhotoClone1.ViewportFrame.Seat2.Humanoid:ApplyDescription(P1S2PlayerAppearance)
			print("Player is in seat so viewportframe dummy not destroyed:S2C1")
		end
	end)
	workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar3.Seat:GetPropertyChangedSignal("Occupant"):Connect(function()
		if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar3.Seat.Occupant~=nil then
			local P1S3PlayerAppearance = Players:GetHumanoidDescriptionFromUserId(game.Players[workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar3.Seat.Occupant.Name].UserId)
			local P1S3Dummy = PhotoClone1.ViewportFrame.Seat3.Humanoid:ApplyDescription(P1S3PlayerAppearance)
			print("Player is in seat so viewportframe dummy not destroyed:S3C1")
		end
	end)
	workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar4.Seat:GetPropertyChangedSignal("Occupant"):Connect(function()
		if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar4.Seat.Occupant~=nil then
			local P1S4PlayerAppearance = Players:GetHumanoidDescriptionFromUserId(game.Players[workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar4.Seat.Occupant.Name].UserId)
			local P1S4Dummy = PhotoClone1.ViewportFrame.Seat4.Humanoid:ApplyDescription(P1S4PlayerAppearance)
			print("Player is in seat so viewportframe dummy not destroyed:S4C1")
		end
	end)
	
	if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar1.Seat.Occupant==nil then
		PhotoClone1.ViewportFrame.Seat1:Destroy()
		print("Player is NOT in seat so viewportframe dummy destroyed:S1C1")
	end
	if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar2.Seat.Occupant==nil then
		PhotoClone1.ViewportFrame.Seat2:Destroy()
		print("Player is NOT in seat so viewportframe dummy destroyed:S2C1")
	end
	if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar3.Seat.Occupant==nil then
		PhotoClone1.ViewportFrame.Seat3:Destroy()
		print("Player is NOT in seat so viewportframe dummy destroyed:S3C1")
	end
	if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car1.Base.Bar4.Seat.Occupant==nil then
		PhotoClone1.ViewportFrame.Seat4:Destroy()
		print("Player is NOT in seat so viewportframe dummy destroyed:S4C1")
	end
	-----------------------------------------------------------------
	RidePhotoGUI.PhotoNumber.Value+=1
	local PhotoClone2 = script.Parent.MegafobiaRidePhoto:Clone()
	PhotoClone2.Parent=Players.LocalPlayer.PlayerGui
	PhotoClone2.Adornee=Screens["2"].Screen
	print("Photo is on screen")
	PhotoClone2.PhotoNumberText.Text=tostring(PhotoClone2.PhotoNumber.Value)
	wait()
	PhotoClone2.ViewportFrame.ZIndex+=1
	PhotoClone2.ImageLabel1.ZIndex+=1
	PhotoClone2.ImageLabel2.ZIndex+=1
	PhotoClone2.PhotoNumberText.ZIndex+=1
	
	workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar1.Seat:GetPropertyChangedSignal("Occupant"):Connect(function()
		if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar1.Seat.Occupant~=nil then
			local P2S1PlayerAppearance = Players:GetHumanoidDescriptionFromUserId(game.Players[workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar1.Seat.Occupant.Parent.Name].UserId)
			local P2S1Dummy = PhotoClone1.ViewportFrame.Seat1.Humanoid:ApplyDescription(P2S1PlayerAppearance)
			print("Player is in seat so viewportframe dummy not destroyed:S1C2")
		end
	end)
	workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar2.Seat:GetPropertyChangedSignal("Occupant"):Connect(function()
		if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar2.Seat.Occupant~=nil then
			local P2S2PlayerAppearance = Players:GetHumanoidDescriptionFromUserId(game.Players[workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar2.Seat.Occupant.Parent.Name].UserId)
			local P2S2Dummy = PhotoClone1.ViewportFrame.Seat2.Humanoid:ApplyDescription(P2S2PlayerAppearance)
			print("Player is in seat so viewportframe dummy not destroyed:S2C2")
		end
	end)
	workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar3.Seat:GetPropertyChangedSignal("Occupant"):Connect(function()
		if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar3.Seat.Occupant~=nil then
			local P2S3PlayerAppearance = Players:GetHumanoidDescriptionFromUserId(game.Players[workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar3.Seat.Occupant.Parent.Name].UserId)
			local P2S3Dummy = PhotoClone1.ViewportFrame.Seat3.Humanoid:ApplyDescription(P2S3PlayerAppearance)
			print("Player is in seat so viewportframe dummy not destroyed:S3C2")
		end
	end)
	workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar4.Seat:GetPropertyChangedSignal("Occupant"):Connect(function()
		if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar4.Seat.Occupant~=nil then
			local P2S4PlayerAppearance = Players:GetHumanoidDescriptionFromUserId(game.Players[workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar4.Seat.Occupant.Parent.Name].UserId)
			local P2S4Dummy = PhotoClone1.ViewportFrame.Seat4.Humanoid:ApplyDescription(P2S4PlayerAppearance)
			print("Player is in seat so viewportframe dummy not destroyed:S4C2")
		end
	end)
	
	if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar1.Seat.Occupant==nil then
		PhotoClone2.ViewportFrame.Seat1:Destroy()
		print("Player is NOT in seat so viewportframe dummy destroyed:S1C2")
	end
	if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar2.Seat.Occupant==nil then
		PhotoClone2.ViewportFrame.Seat2:Destroy()
		print("Player is NOT in seat so viewportframe dummy destroyed:S2C2")
	end
	if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar3.Seat.Occupant==nil then
		PhotoClone2.ViewportFrame.Seat3:Destroy()
		print("Player is NOT in seat so viewportframe dummy destroyed:S3C2")
	end
	if workspace.RideSystems.Megafobia.Trains[Trigger.TrainDetected.Value].Car2.Base.Bar4.Seat.Occupant==nil then
		PhotoClone2.ViewportFrame.Seat4:Destroy()
		print("Player is NOT in seat so viewportframe dummy destroyed:S4C2")
	end

	-----------------------------------------------------------------
	

end)

The Seat:GetPropertyChangedSignal(“Occupant”):Connect(function() line is the line that starts the applying description code but as seen in the photo here
image

It doesn’t actually apply the description

Notes:
It runs through StarterPlayerScripts in a folder and is run on the client using a remote event fired by a server script. using :FireAllClients()

Help would be greatly appreciated :slight_smile:

Thanks,
Tom

Is this because I have used it on a client?

I’m pretty sure it can’t be used on the client sadly. I have seen this issue before in my game.

Why are you creating a variable while applying the description? Not sure if this is what’s causing the problem

You can use ApplyDescription on the client as long as the Humanoid isn’t an Instance from the server. (example: cloning a model on the client and applying the description works.)

I’m not sure if it’s documented though.

i got rid of the variable part and it still didn’t work.

Yes. I’m copying from a client script which runs on a client event. The server script acts as a trigger to fire the event.

SOLVED:

using get property changed signal wasn’t needed and caused the lines to not run.
still have another issue where no accessories are being displayed on the viewport dummies