I am creating a Football (Soccer) game in Roblox and i am not a very good scripter so i need some help e.g how to script a gui to trigger when someone scores a goal or when someone is offside and scores a goal it triggers a foul, etc.
Look for a basketball hoop in free models, where if you shoot the basketball in the hoop it says "Swish", take out a phew scripts in it, and put them into the goal. Otherwise, you're going to need to make this yourself, because this isn't a requesting site. It's a helpful site, don't get me wrong, but you can't request scripts here.
I'm not sure about the fouls.. but with just getting any goal you could put an invisible non-CanCollide[able] brick inside the goal, and make that if the ball touches the brick then a message/GUI would pop up. I think that might work, not too sure. Apologies if that wasn't very helpful xD
@infallivelemon Good Idea! Make sure that part covers the whole inside of the goal. Put this script inside of it. A script for it would be like:
01 | local toucherpart = script.Parent |
02 | toucherpart.Touched:connect( function (Part) |
03 | if Part.Name = FootBall then |
04 | local f = Instance.new( "Message" ) |
05 | f.Text = "Goal!" |
06 | f.Parent = Workspace |
07 | wait( 5 ) |
08 | f:remove() |
09 | end |
10 | end ) |
Hope this helped! PM me @Mowblow on roblox for more help!