Can ModuleScripts's be Visible on the Server?

Hello,

So i am trying to improve my Weapon by adding a ModuleScript to Control certain functions inside them,
But i was wondering, Are ModuleScript functions Visible on the Server?

Module Script Currently:

local Settings = {
--/Services/-->
   -- TweenService = game:GetService("TweenService");
	--RunService = game:GetService("RunService");
	Debris = game:GetService("Debris");
	UserInputService = game:GetService("UserInputService");
--/Script Paths/-->
	--Server = script.Parent.Server;
	--Client = script.Parent.Client;
	--AimClient = script.Parent.Aiming;
	
--/Bools/-->		
	Shooting = false;
	IsAiming = false;
	IsActive = false;
	CanReload = false;
	
	--/Main/-->
	Player = game.Players.LocalPlayer;
	Camera = workspace.CurrentCamera;
	Lighting = game.Lighting;
	
--/Tool Paths/-->	
	Tool = script.Parent;
	--FirePart = script.Parent.Handle.Flash;
	FireEvent = script.Parent.Fire;
	Case = script.Parent.Case;
	Bullet = script.Parent.Bullet;
	
--/Weapon Settings/-->
	AmmoCapacity = 20;
	AmmoMax = 21;
	Firerate = .05;
	Damage = 5;
	DesiredHumanoid = "ZHumanoid";
	
	FireSound = "rbxassetid://1772743949";
	FireSound_Volume = 4;
	FireSound_Pitch  = 2;

	FleshHitSound = "rbxassetid://3092866899";
	FleshHitSound_Volume = 2;
	FleshHitSound_Pitch  = 1;
	
--/Animations/-->
	IdleAnimation = "rbxassetid://11229562610";
	FireAnimation = "rbxassetid://11229624726";
	WeaponFireAnimation = "rbxassetid://11203319898";
	AimingAnimation = "rbxassetid://11352093206";
	AimFireAnimation = "rbxassetid://11352321268";
	
	FlashTextures = {
		[1] = "rbxassetid://421803006";
		[2] = "rbxassetid://421803091";
		[3] = "rbxassetid://421803134";
	};
	
}

function Settings:FireEvent()
	print("fired")
	local Sound = Instance.new("Sound", Settings.Tool.Handle)
	Sound.SoundId = Settings.FireSound
	Sound:Play()
	Settings.Debris:AddItem(Sound, Sound.TimeLength)
	
	local A = Settings.Case:Clone()
	A.Parent = workspace A.VectorForce.Enabled = true
	Settings.Debris:AddItem(A.VectorForce, .03)
	Settings.Debris:AddItem(A, 1)
	
	local Flash = Settings.Tool.Handle.Flash.MuzzleEffect:Clone()
	Flash.Parent = Settings.Tool.Handle.Flash
	Flash.Texture = Settings.FlashTextures[math.random(1, #Settings.FlashTextures)]
	Flash.Enabled = true
	Settings.Debris:AddItem(Flash, 0.03)

end

function Settings:SetFiringStatus(Status: boolean)
	Settings.Shooting = Status
end

function Settings:SetAimingStatus(Status: boolean)
	Settings.IsAiming = Status
end




return Settings

Everything, that is replicated only for one player can’t be seen on the server, unlike some humanoid things. So, back to what you asked, server cant see modules that exist only on client

2 Likes

@CoffeeEnjoyerr
What should I do to make the Items visible on the Server besides Case ejection?

I don’t want my items to Slow down when I use the them on a Server Script

1 Like

Put your shared modules in ReplicatedStorage and the ones that are only accessed by the client in PlayerScripts

There is only one ModuleScript

1 Like

Alright, yeah, now uh why’d you randomly say there’s one module script, the number of module scripts doesn’t matter right now…

Sorry i forgot to edit my post, but i figured out how to do it, thanks tho

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.