Game not working ingame

Hello! I need help. I’m attempting to make an RPG game similar to Block Tales. However, I’ve come across a problem while developing. When I test in studio, it runs perfectly fine. However, in the roblox player, it just doesn’t work. There are no errors or anything, and it’s like the scripts just…don’t exist! 80% of the game’s code runs on localscripts (mainly dialog and the camera), but I’m not sure if that contributes to the problem or not…

2 Likes

Have you published changes? Alt + P is the simple keybind, and in File

I have, actually. Multiple times, but that doesn’t seem to be the problem…

are your localscripts parented in a container that localscripts can run in?

Are you running in TeamCreate or Local File?

if they can run in PlayerScripts, then yea

I’m running in TeamCreate, why?

Sometimes commits are enabled, I’m pretty sure in the View tab you can show it.

Commits are off, so idk what it could be

if you can show a random localscript in playerscripts. maybe you use game.Loaded:Wait() or something or waitforchild(name, math.huge)

don’t gotta show all but maybe the part of top of a script

Here’s one of the few that aren’t working. This is the camerascript.
local plr = game.Players.LocalPlayer
local cam = workspace.CurrentCamera
local ogpos

–erm

plr.CharacterAdded:Wait()
plr.Character:WaitForChild(“Head”)

cam.CameraSubject = plr.Character.Head
cam.CameraType = Enum.CameraType.Attach
cam.FieldOfView = 80

game:GetService(“RunService”).RenderStepped:Connect(function()
if plr.Character:FindFirstChild(“vars”) and plr.Character.vars.StopCam.Value == false then
cam.CameraSubject = plr.Character.Head
cam.CameraType = Enum.CameraType.Attach
cam.FieldOfView = 80
cam.CFrame = CFrame.new(plr.Character.HumanoidRootPart.Position + Vector3.new(0, 3, 0)) * CFrame.new(0, 0, 15)
ogpos = cam.CFrame
elseif plr.Character:FindFirstChild(“vars”) and plr.Character.vars.StopCam.Value == true and plr.Character.vars.overridecam.Value == false then
cam.CameraType = Enum.CameraType.Scriptable
if ogpos then
cam.CFrame = ogpos
end
end
end)

And this is in StarterPlayer, not StarterCharacter?

plr.CharacterAdded:Wait should be

player.Character or player.CharacterAdded:Wait since the character could already be loaded in

local character = player.Character or player.CharacterAdded:Wait()

it’s in StarterPlayer. Like I said, it’s only working in Studio.

As gm mentioned, studio is running Roblox in a container, while on launcher, its a whole separate process.

its working now! Thanks you two ^^

1 Like