Roblox Tutorial - How to make an AFK system

  Рет қаралды 6,540

Cookie Tech

Cookie Tech

11 ай бұрын

Hello and welcome to another cookie tech video!
In today's video, I'm going to show you on how you can make a cool afk system that will automatically add forcefields and make the player a forcefield materials.
Roblox Source Code: forums.thecookie.dev/t/afk-sy...
Link to the Discord to give suggestions: / discord
Would you like to chat about Roblox, Roblox development, scripting support or have any other epic things about development/Roblox?
Join here: forums.thecookie.dev/
Join this channel to get access to perks:
www.youtube.com/@CookieTechRB...
Please consider liking and subscribing!
Thanks for watching & I hope you learnt something new!

Пікірлер: 32
@ScriptiqueOfficial
@ScriptiqueOfficial 11 ай бұрын
I wss there for the Stream! Thank you s much for helping everyone become a better scripter! Unbeleivably, underrated. 👍🏻
@cookietechrblx
@cookietechrblx 11 ай бұрын
Any time!
@TristyMP4
@TristyMP4 11 ай бұрын
This was a good stream! Great work cookie!
@noodles675
@noodles675 11 ай бұрын
Hi! You're an amazing KZfaqr. Keep up the great work!
@JinSeKuv_kanal
@JinSeKuv_kanal 11 ай бұрын
Thanks for the tutorial! This help me alot with my game! Good job, Cookie
@xerouns
@xerouns 3 ай бұрын
It would be interesting to see a countdown of how much a player is worth in the AFK
@flowieringrblx
@flowieringrblx 11 ай бұрын
Could you do a tutorial on how to make a cafe ordering system where the staff member will put the customers name then select the items the customer wants then it will send the order to a surface gui on a part
@HyperDevv
@HyperDevv 3 ай бұрын
just a question? why do you use remotefunctions and not hjust in one script
@DuckiiRoblox
@DuckiiRoblox 11 ай бұрын
can u make a new ranking commands tutorial bc my ranking bot isn't working.
@zlzhez6667
@zlzhez6667 Ай бұрын
it doesnt work for me and i inserted each scripts to where they need to be
@imbryanyt456
@imbryanyt456 5 ай бұрын
ty
@scoke07
@scoke07 10 ай бұрын
huge W bro
@SomeKidOnCrack
@SomeKidOnCrack 6 ай бұрын
cookie please when ever i click ID nothing happends😥
@EinRandomHobbyloserTyp
@EinRandomHobbyloserTyp 8 ай бұрын
how does this work with out this rank lock ???
@hvgriid
@hvgriid 8 ай бұрын
is there a way to remove the blue sphere forcefield when you go afk and only have the orange invisible person?
@danielscommisions
@danielscommisions 7 ай бұрын
sorry i was late, remove the part where it says forcefield
@thoseawesomeguys420
@thoseawesomeguys420 11 ай бұрын
8:41 You forgot to put the card!
@cookietechrblx
@cookietechrblx 11 ай бұрын
Yowzers! Thanks for getting that for me; should be sorted now!
@dagobert-roblox7757
@dagobert-roblox7757 11 ай бұрын
👍
@RyomenJKSukuna
@RyomenJKSukuna 11 ай бұрын
Cookie Hello.
@Jonslau
@Jonslau 11 ай бұрын
I was the guy who made him use a group.
@RyomenJKSukuna
@RyomenJKSukuna 11 ай бұрын
Is that your voice?
@shaheem4796
@shaheem4796 11 ай бұрын
No shit
@cookietechrblx
@cookietechrblx 11 ай бұрын
Yep, lol
@shaheem4796
@shaheem4796 11 ай бұрын
Babie
@40kq
@40kq 11 ай бұрын
I just decided to watch because I am bored. You're overcomplicating your code.
@cookietechrblx
@cookietechrblx 11 ай бұрын
How come? I would love to hear your suggestions on what I should change, however, I think this code is pretty sleek, simple for beginners & has a lot of customization, you don't need a rank lock or to set the players material, you can just have a simple force field! But I would love to include everybody's ideas into my design, but as mentioned in the video, you don't have to add these.
@user-vn9on3jn1e
@user-vn9on3jn1e 4 ай бұрын
how would u change the color of the holographic thing@@cookietechrblx
@notekio
@notekio 2 ай бұрын
@@user-vn9on3jn1e Changing the players SkinTone
@scytherplayz1255
@scytherplayz1255 11 ай бұрын
For some reason the plastic material thing wont work what's wrong? AfkManager: local ImputService = game:GetService("UserInputService") local ReplicatedStorage = game:GetService("ReplicatedStorage") local FocusedEvent = ReplicatedStorage:WaitForChild("Focused") local UnFocusedEvent = ReplicatedStorage:WaitForChild("Unfocused") local function CreateForceField(Player) local ForceField = Instance.new("ForceField") ForceField.Visible = true ForceField.Parent = Player.Character for _,v in Player.Character:GetDescendants() do if v:IsA("MeshPart") then v.Material = Enum.Material.ForceField end end end local function RemoveForceField(Player) Player.Character.ForceField:destroy() for _,v in Player.Character:GetDescendants() do if v:IsA("MeshPart") then v.Material = Enum.Material.Plastic end end end FocusedEvent.OnServerEvent:Connect(function(player) RemoveForceField(player) end) UnFocusedEvent.OnServerEvent:Connect(function(player) CreateForceField(player) end)
@Pcspyder
@Pcspyder 11 ай бұрын
I am having an issue with the script too, and to double-check I used the one on the link to compare. Mine still isn't working yet
@notekio
@notekio 2 ай бұрын
I actually found a fix for this, I'm not sure if its because you are using R6 or not, but here is the code. local inputService = game:GetService("UserInputService") local ReplicatedStorage = game:GetService("ReplicatedStorage") local FocusedEvent = ReplicatedStorage:WaitForChild("Focused") local UnFocusedEvent = ReplicatedStorage:WaitForChild("Unfocused") local function GoAFK(Player) for _,v in Player.Character:GetDescendants() do -- IF THE PLAYER IS R15 if Player.Character.Humanoid.RigType == Enum.HumanoidRigType.R15 then if v:IsA("MeshPart") then v.Material = Enum.Material.ForceField end end -- IF THE PLAYER IS R6 if Player.Character.Humanoid.RigType == Enum.HumanoidRigType.R6 then if v:IsA("Part") then v.Material = Enum.Material.ForceField end end if Player.DisplayName.lower(Player.DisplayName) == Player.Name.lower(Player.Name) then Player.Character.Head.playerName.display.Text = "@" .. Player.Name .. " [AFK]" else Player.Character.Head.playerName.display.Text = Player.DisplayName .. " ( @" .. Player.Name .. " ) " .. " [AFK]" end end end local function ImBack(Player) for _,v in Player.Character:GetDescendants() do -- IF THE PLAYER IS R15 if Player.Character.Humanoid.RigType == Enum.HumanoidRigType.R15 then if v:IsA("MeshPart") then v.Material = Enum.Material.Plastic end end -- IF THE PLAYER IS R6 if Player.Character.Humanoid.RigType == Enum.HumanoidRigType.R6 then if v:IsA("Part") then v.Material = Enum.Material.Plastic end end if Player.DisplayName.lower(Player.DisplayName) == Player.Name.lower(Player.Name) then Player.Character.Head.playerName.display.Text = "@" .. Player.Name else Player.Character.Head.playerName.display.Text = Player.DisplayName .. "( @" .. Player.Name .. " )" end end end FocusedEvent.OnServerEvent:Connect(function(player) ImBack(player) end) UnFocusedEvent.OnServerEvent:Connect(function(player) GoAFK(player) end)
How many visits will immersive ads get me on Roblox?
25:47
Cookie Tech
Рет қаралды 311 М.
I tried Discord Bot Makers...
14:19
FaceDev
Рет қаралды 106 М.
Alex hid in the closet #shorts
00:14
Mihdens
Рет қаралды 10 МЛН
Llegó al techo 😱
00:37
Juan De Dios Pantoja
Рет қаралды 43 МЛН
Gym belt !! 😂😂  @kauermtt
00:10
Tibo InShape
Рет қаралды 12 МЛН
Can I Make a VIRAL Roblox Game in 1 Hour?
15:16
Temprist
Рет қаралды 4,6 МЛН
How to Make a Popular Roblox Game
21:08
MonzterDEV
Рет қаралды 6 М.
Why I Hate Roblox Abilities
11:52
ByteBlox
Рет қаралды 358 М.
Investigation: How Roblox Is Exploiting Young Game Developers
22:44
People Make Games
Рет қаралды 2,4 МЛН
What Is The Best AI For Roblox Studio Scripting?
10:42
RoDev
Рет қаралды 417 М.
I Made a Roblox Simulator Game in 7 Days!
7:40
Maze Sunshine
Рет қаралды 220 М.
I coded your HORRIBLE Minecraft ideas
15:11
Element X
Рет қаралды 386 М.
The ENTIRE Guide to ROBLOX Commissions
25:36
Itz_FloppyFish
Рет қаралды 17 М.
Going AFK in Roblox until I’m donated 500k
8:58
Flamingo
Рет қаралды 7 МЛН
КОНЕЦ АЛЬЯНСА | Сюжет skibidi toilet 76 (part 2)
10:13