local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local Market = game:GetService("MarketplaceService")
local Remote = ReplicatedStorage.Device
local Remote2 = ReplicatedStorage.AFK

local EB = 33666390
local Divisions = {
    {"FE", 33666551},
    {"PE", 33666546},
    {"BAC", 33672084},
    {"CIE", 33672101},
    {"PQDT", 33672131},
}

local GamePass = {
    [203985180] = "πŸ‘‘",
    [203987469] = "🌟"
}

local PatenteComEmoji = {
    ["[CMDT] Comandante"] = "🌟    πŸ‘‘    πŸ”°",
    ["[S-CMDT] Sub-Comandante"] = "🌟    πŸ‘‘    πŸ”°",
}

local devsComEmoji = {
    1575677613, --// sn0wlyz
}

local emojiForDevs = "πŸ› οΈ    🌟    πŸ‘‘"

Players.PlayerAdded:Connect(function(player)
    player.CharacterAdded:Connect(function(character)
        local Nametag = script.Nametag:Clone()
        Nametag.Jogador.Text = player.Name
        Nametag.Jogador.TextColor3 = player.TeamColor.Color
        if player:IsInGroup(EB) then
            Nametag.Patente.Text = player:GetRoleInGroup(EB)
        else
            Nametag.Patente.Text = "Civil"
        end

        for _, x in pairs(Divisions) do
            if player:IsInGroup(x[2]) then
                Nametag.Division.Text = player:GetRoleInGroup(x[2])
            end
        end

        local Device = Remote:InvokeClient(player)
        if Device then
            Nametag.Emoji.Text = Device
        end

        if player:GetRankInGroup(EB) >= 9 and PatenteComEmoji[player:GetRoleInGroup(EB)] == nil then
            Nametag.Emoji.Text = Nametag.Emoji.Text .. "πŸ”°    "
        end

        for i, x in pairs(PatenteComEmoji) do
            if player:GetRoleInGroup(EB) == i then
                Nametag.Emoji.Text = Nametag.Emoji.Text .. "    " .. x
            end
        end

        for i, x in pairs(GamePass) do
            if Market:UserOwnsGamePassAsync(player.UserId, i) then
                Nametag.Emoji.Text = Nametag.Emoji.Text .. "    " .. x
            end
        end

        for _, devId in pairs(devsComEmoji) do
            if player.UserId == devId then
                Nametag.Emoji.Text = Nametag.Emoji.Text ..  "πŸ› οΈ    🌟    πŸ‘‘"
                break -- Exit loop once emoji is added
            end
        end

        --[[for _, label in pairs(Nametag:GetChildren()) do
            if label:IsA("TextLabel") then
                label.TextColor3 = player.TeamColor.Color
            end
        end]]--

        Nametag.Adornee = character:WaitForChild("Head")
        Nametag.Parent = character
    end)
end)

Remote2.OnServerEvent:Connect(function(plr, tipo)
    local NameTag = plr.Character:FindFirstChild("Nametag")
    if plr and NameTag then
        if tipo == true then
            NameTag.Jogador.Text = "AFK | " .. plr.Name
        else
            NameTag.Jogador.Text = plr.Name
        end
    end
end)

Raw hospeado por, Katiausha. Última vez escrito: Janeiro 27 de 2024 às 7:59:03 | Neocities 😻