Well, I’m trying to pause my character’s animation every time the module is activated, but it just won’t pause. I used a module for this, because I had to call other scripts (remote events would be more useful if they could be called between server scripts). Well, every time I call the module and it has the bool set to true, the animation is played. However, whenever the bool is false, the animation is not played.
local Players = game:GetService("Players")
local TweenService = game:GetService("TweenService")
local ServerStorage = game:GetService("ServerStorage")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local ServerScriptService = game:GetService("ServerScriptService")
local MaterialSystem = workspace:WaitForChild("MaterialSystem")
local Material = {}
function Material:FireModule(plr, take, strings)
local char = workspace:FindFirstChild(plr.Name)
local PlayerGui = plr.PlayerGui
local MenuDeMapa = PlayerGui.MenuDeMapa
local GloboDeTexto = MenuDeMapa.GloboDeInfo
local EquipTools = MenuDeMapa.Slots.EquipTools
local tweenInfo = TweenInfo.new(0.4)
local UnTweenPosition = TweenService:Create(GloboDeTexto, tweenInfo, {Position = UDim2.new(1.12, 0, 0.5, 0)})
local TweenPosition = TweenService:Create(GloboDeTexto, tweenInfo, {Position = UDim2.new(0.88, 0, 0.5, 0)})
if char then
local System = char.Sistemas
local Humanoid = char.Humanoid
local animloader = Humanoid:LoadAnimation(System.carry)
Humanoid:UnequipTools()
if take == true then
animloader:Play()
else
animloader:Stop()
end
System.Taken.Value = take
System.TakenSelect.Value = strings
end
end
return Material