Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How do I add a ForceField to a character every time it spawns?

How do you Create a ForceField that will stay on your character for the rest of the time you spent in the game? I've been trying to figure this out for weeks.

-Liftin

3 answers

✓ Accepted answer

You simply create a new ForceField object in the character model.

This should do the trick:

game.Players.PlayerAdded:connect(function(player)
	player.CharacterAdded:connect(function(character)
		Instance.new("ForceField", character)
	end)
end)

Just apply a ForceField to the character model and it should do! So just have a script that detects when the character respawns and then add a forcefield... :)

Game:GetService"Players".PlayerAdded:connect(function(Player) 
	Player.CharacterAdded:connect(function(Character)
		Instance.new("ForceField",Character)
	end)
end)

wow 9 seconds.... really....

2 comments

1

Hah.

0

kay time to post somewhat productive questions for reputation

Do you mean just every time or forever because you can just click the force field enable on the spawn properties. Much easier than a script.

This discussion is preserved as it was. New answers, comments, and votes are closed.