Mqozz
(Mqozz)
#1
I would like to get the character straight from ReplicatedStorage, the script is working perfectly, Thanks to everyone who responds to this thread!
Vid.wmv (357.8 KB)
local l__ViewportFrame__1 = script.Parent.Parent.MainFrame:WaitForChild(objects.Name).ViewportFrame
local v2 = Instance.new("Camera");
v2.FieldOfView = 70;
l__ViewportFrame__1.CurrentCamera = v2;
l__ViewportFrame__1.Visible = true;
local u1 = nil;
local function u2(p1)
local v3, v4 = p1:GetBoundingBox();
local v5 = (v3 - v3.p):inverse();
local v6 = v5 * v4;
local v7 = Vector3.new(math.abs(v6.x), math.abs(v6.y), math.abs(v6.z));
local v8 = math.max(v7.x, v7.y, v7.z);
local v9 = math.tan(math.rad(v2.FieldOfView / 2));
if v8 == v7.x then
local v10 = math.sqrt(v7.y * v7.y + v7.z * v7.z) / 2;
elseif v8 == v7.y then
v10 = math.sqrt(v7.x * v7.x + v7.z * v7.z) / 2;
else
v10 = math.sqrt(v7.x * v7.x + v7.y * v7.y) / 2;
end;
local l__RenderStepped__11 = game:GetService("RunService").RenderStepped;
local u3 = 0;
local u4 = v3 * v5;
local u5 = v8 / 2 / v9 + v10;
return l__RenderStepped__11:Connect(function(p2)
u3 = u3 + 1 * p2 * 60;
v2.CFrame = u4 * CFrame.fromEulerAnglesYXZ(0, math.rad(u3), 0) * CFrame.new(0, 0, u5 + -0.5);
end);
end;
local function u6(p3)
if u1 then
u1:Disconnect();
end;
u1 = u2(p3);
end;
script.Parent:GetPropertyChangedSignal("Visible"):Connect(function()
if script.Parent.Visible then
u6(l__ViewportFrame__1.DivisionModel);
return;
end;
u1:Disconnect();
end);
u6(l__ViewportFrame__1:WaitForChild(objects.Name));
end)
end
end
cjhatter
(can)
#2
Is there an issue with what you’re making that you need help with or are you just posting a community resource?
1 Like
Koiyukki
(Koyukki)
#3
I have no idea what your are talking about, could you explain further?
1 Like
Mqozz
(Mqozz)
#4
local Characters = game.ReplicatedStorage.RealPlayers:WaitForChild(objects.Name)
I would like to get the characters straight from (ReplicatedStorage)
local l__ViewportFrame__1 = script.Parent:WaitForChild("ViewportFrame");
local v2 = Instance.new("Camera");
v2.FieldOfView = 70;
l__ViewportFrame__1.CurrentCamera = v2;
l__ViewportFrame__1.Visible = true;
local u1 = nil;
local function u2(p1)
local v3, v4 = p1:GetBoundingBox();
local v5 = (v3 - v3.p):inverse();
local v6 = v5 * v4;
local v7 = Vector3.new(math.abs(v6.x), math.abs(v6.y), math.abs(v6.z));
local v8 = math.max(v7.x, v7.y, v7.z);
local v9 = math.tan(math.rad(v2.FieldOfView / 2));
if v8 == v7.x then
local v10 = math.sqrt(v7.y * v7.y + v7.z * v7.z) / 2;
elseif v8 == v7.y then
v10 = math.sqrt(v7.x * v7.x + v7.z * v7.z) / 2;
else
v10 = math.sqrt(v7.x * v7.x + v7.y * v7.y) / 2;
end;
local l__RenderStepped__11 = game:GetService("RunService").RenderStepped;
local u3 = 0;
local u4 = v3 * v5;
local u5 = v8 / 2 / v9 + v10;
return l__RenderStepped__11:Connect(function(p2)
u3 = u3 + 1 * p2 * 60;
v2.CFrame = u4 * CFrame.fromEulerAnglesYXZ(0, math.rad(u3), 0) * CFrame.new(0, 0, u5 + -0.5);
end);
end;
local function u6(p3)
if u1 then
u1:Disconnect();
end;
u1 = u2(p3);
end;
script.Parent:GetPropertyChangedSignal("Visible"):Connect(function()
if script.Parent.Visible then
u6(l__ViewportFrame__1.DivisionModel);
return;
end;
u1:Disconnect();
end);
u6(l__ViewportFrame__1.DivisionModel);
Mqozz
(Mqozz)
#5
local Characters = game.ReplicatedStorage.RealPlayers:WaitForChild(objects.Name)
I would like to get the characters straight from (ReplicatedStorage)
I would like to change the model path to (ReplicatedStorage)
local l__ViewportFrame__1 = script.Parent:WaitForChild("ViewportFrame");
local v2 = Instance.new("Camera");
v2.FieldOfView = 70;
l__ViewportFrame__1.CurrentCamera = v2;
l__ViewportFrame__1.Visible = true;
local u1 = nil;
local function u2(p1)
local v3, v4 = p1:GetBoundingBox();
local v5 = (v3 - v3.p):inverse();
local v6 = v5 * v4;
local v7 = Vector3.new(math.abs(v6.x), math.abs(v6.y), math.abs(v6.z));
local v8 = math.max(v7.x, v7.y, v7.z);
local v9 = math.tan(math.rad(v2.FieldOfView / 2));
if v8 == v7.x then
local v10 = math.sqrt(v7.y * v7.y + v7.z * v7.z) / 2;
elseif v8 == v7.y then
v10 = math.sqrt(v7.x * v7.x + v7.z * v7.z) / 2;
else
v10 = math.sqrt(v7.x * v7.x + v7.y * v7.y) / 2;
end;
local l__RenderStepped__11 = game:GetService("RunService").RenderStepped;
local u3 = 0;
local u4 = v3 * v5;
local u5 = v8 / 2 / v9 + v10;
return l__RenderStepped__11:Connect(function(p2)
u3 = u3 + 1 * p2 * 60;
v2.CFrame = u4 * CFrame.fromEulerAnglesYXZ(0, math.rad(u3), 0) * CFrame.new(0, 0, u5 + -0.5);
end);
end;
local function u6(p3)
if u1 then
u1:Disconnect();
end;
u1 = u2(p3);
end;
script.Parent:GetPropertyChangedSignal("Visible"):Connect(function()
if script.Parent.Visible then
u6(l__ViewportFrame__1.DivisionModel);
return;
end;
u1:Disconnect();
end);
u6(l__ViewportFrame__1.DivisionModel);
This is the wrong category. Please put it in #resources:community-tutorials
Mqozz
(Mqozz)
#7
It’s not a tutorial, I’d like to get the characters directly from (ReplicatedStorage) because I’m not getting
Did you try doing
game.RepliactedStorage.YourFolderHere.Character -- YOUR CHARACTER GOES HERE
Mqozz
(Mqozz)
#9
I did it, the problem is that I don’t know where to put it