I’m trying to make a tool where when activated, a remote event is triggered that creates a part in front of the player to serve as the attack hitbox, but I can’t get the tool to work.
game.ReplicatedStorage.TestEvent:FireServer()
This line works in a local script in response to a key press, but in the tool it causes an error saying FireServer can only be called from the client, and FireClient() causes an error saying Argument 1 missing or nil.
I’m also worried that FireClient() won’t trigger the event since the event response script is in response to a server event:
What would I type for that? The tools parent or just the name of the function causes an error saying FireClient: player argument must be a Player object
You cannot call FireServer from a Server Script, only from a LocalScript. If it mentions that FireServer can only be called from the client, you’re not calling it from a LocalScript.