
Local Script stored in tool in starterpack as “Client”Īs I showed in my original response, you need to check that the CanAttack value is set to false in the Blade.Touched event in order to make sure the player is currently attacking. Serverscript stored in ServerScriptService as “SwordServer” RemoteEvent named damage is in ReplicatedStorage Local CanAttack = true :Connect(function(player, hit) There are probably some other things you can check for as well, but those two should suffice for your average hacker. The user is within a certain amount of studs of the character they’re attacking (probably something around 30 studs to account for any latency).

#ROBLOX WAR SIMULATOR SCRIPT CODE#
Your code is already FE compatible, but I assume you mean for the fix of the idle damage to be FE enabled so I’ll answer with that assumption in mind.Ĭurrently, you are running the attack animation on the client, as well as the cooldown for the attack, but the onTouched function is on the server. How could I fix the idle damage bug and make it filtering enabled compatible?

Local Animation = :LoadAnimation(Attack_Animations) UserInputService.InputBegan:Connect(function(InputObject) Local Attack_Animations = script.Parent:WaitForChild("Animations")

Local UserInputService = game:GetService("UserInputService") If CanAttack = true and hit.Parent:FindFirstChild("Humanoid")~= nil then Local CanAttack = true blade.Touched:Connect(function(hit) I have everything inside of a tool and any help would be greatly appreciated. I am just really confused and have no clue as to where to go from here.
#ROBLOX WAR SIMULATOR SCRIPT HOW TO#
I have no idea on how to do this, and also my sword seems like it works on both client and server side without bugs. I figured out my sword wasn’t completely finished yet, because I haven’t set it so that it doesn’t constantly deal idle damage. I am not asking for scripts, just advice on how to approach doing the above things, such as what to use and where. (Current code below.) Third, I am unaware of how to make my sword FilteringEnabled compatible, and I also would like to be able to award the player with cash for every kill he gets. Are there any advantages to using ServerScriptService? Second, I began to work on the script and I do not know how to check if what the tool touched was a player. First off, I have received advice to put my server script into ServerScriptService, however it seems it would be more convenient to place it as a child of the tool. I have created a local script that runs animations perfectly fine, and now I am on to the server side scripting.

Also, don’t forget to check out our guides on Rell coin codes, eye, mask codes, item spawn list, bloodlines tier list, and most importantly, the Shindo Life private server location codes.I am currently working on a sword, and unfortunately for me I’m a bit of a “noob” at scripting. If this article helped you out, find out how to play Roblox unblocked at school. Gamer:Button(“Infinite Spins”, function() Gamer:Button(“~ Press Right Shift To Hide GUI ~”) Local Gamer = library:CreateSection(“Shindo Life”) Local library = loadstring(game:HttpGet(“”))() Use and replace these codes in your script to get the Bloodlines you want:
