ISSUE: HTTP 404 Error | Requested asset was not found

Introduction
Hello everyone! I was trying to make an Open Sourced Map Testing, like Flood Escape 2: Community Maps (FE2:CM), where you could load maps via IDs (When whitelisted).

Problem
When I tried to load a current existing map, it said HTTP 404: Requested Asset was not found on console. I was having a hard time understanding it.

Evidences and Resources
Here are some resources and evidences that might help you!

image
Image: StarterGUI library

Script: InputScript

local TextInput = script.Parent -- Gets TextInput
local ID = script.Parent.Parent.InsertButton.ID -- Gets ID

TextInput.InputEnded:Connect(function(Ended) -- If user done typing
	if Ended then -- If user done typing
		
		ID.Value = TextInput.Text -- Change text
	end
end)

Script: InsertScript

-- Variables --
local InsertService = game:GetService("InsertService") -- Gets InsertService
local Button = script.Parent -- Gets button
local ID = script.Parent.ID.Value

-- Function --
Button.MouseButton1Click:Connect(function() -- If Clicked
	
	local Map = InsertService:LoadAsset(ID) -- Insert map
	Map.Parent = workspace -- Put it in workspace
end)

Hope this will help you work on solving my issue! Thanks!

You’re immediately getting the value of ID and putting it in a variable, you need to reference the property when it has to be retrieved

-- Variables --
local InsertService = game:GetService("InsertService") -- Gets InsertService
local Button = script.Parent -- Gets button
local ID = script.Parent.ID

-- Function --
Button.MouseButton1Click:Connect(function() -- If Clicked
	
	local Map = InsertService:LoadAsset(ID.Value) -- Insert map
	Map.Parent = workspace -- Put it in workspace
end)

Actually looking closely, it seems like this still wouldn’t work well because the vaue changes locally, meaning the ID will still be the same for the server as it can’t detect the ID changing, not sure if also making the InputScript server sided would help, but I think a better course of action would just be to use a RemoteEvent that is fired when something needs to be inserted

2 Likes

Hello Embat,

Thank you so much for answering my question! I had a bit of trouble sorting some script out, but it finally worked! Have a great day!

1 Like