Jump to content
Undergoing maintenance, you may experience connectivity issues & degraded performance temporarily. ×

SimplifiedCode

Members
  • Content Count

    25
  • Joined

  • Last visited

  • Days Won

    1

Posts posted by SimplifiedCode


  1. Hello! I'm SimplifiedCode! back at it again with another tutorial. Today we will be doing basic UI scripting with Filtering Enabled! Let's get started!

    First, let's make a basic UI in StarterGui:

    1.PNG.467677b3df6925c589851a324da6c8ff.PNG

    We put our GUI's in StarterGui because we want the player to get it every time they join!

    Now inside the Button, let's make a "Local script":

    2.PNG.d81eb94c74a96bf9958fbf5885fcefd8.PNG

    In this script, write:

    script.Parent.MouseButton1Click:connect(function()
    
    script.Parent.Parent.Visible = false
    
    end)

    This tells the button that whenever someone clicks on it, it goes away.

    What happens if we reset? We get it again! That is because every time you die, your Guis refresh. That's why you reset when something is broken in a game. To fix this, we can do:

    script.Parent.MouseButton1Click:connect(function()
    
    script.Parent.Parent.Parent.ResetOnSpawn = false
    
    script.Parent.Parent.Visible = false
    
    end)

    This tells the Gui to not reset on spawn or when you rest, and it disables when you click on it.

    That concludes this basic tutorial, sorry for being so short, I'll edit this if you have any ideas that you have to add to this. Thanks!

    You can get the Gui and scripts from this tutorial here

     


  2. Contact Information

    discord - @Simp#6820 < perferred

    twitter - @SimplifiedRBLX

    roblox - SimplifiedCode

     

    What you're selling

    Scripting Services (Won't make a game with you, more likely to make a script for it like a round based script.) 

     

    Price

     Depends on script, we can talk in DMs about an exact price


  3. Hello! I realized that remote events are hard for some people, and I wanted to clear the air that remote events are pretty easy!

    What are remote events? Games with Filtering Enabled, don't have access to a lot of things on the client side, so we have to use remote events to tell the server when to do something, like change a name of a text button!

    If you want more information, try checking out ROBLOX's article here

    First, let's create a remote event in replicated storage: 

    1.PNG.9031cdd04f3a9c7f4149738bbc219347.PNG

    Now, let's create a local script, and put it in StarterGui:

    2.PNG.73ba01f0db7ae6ebc928e0fb484b19d4.PNG

    In this script, you would usually put things before it, like loading client information, but we will keep it simple.

    print("OurEvent is about to fire!")
    game.ReplicatedStorage.OurEvent:FireServer()
    print("OurEvent has has fired!")

    What this does is when we say "game.ReplicatedStorage.OurEvent:FireServer()" we say "Hey, we would like our RemoteEvent to run that's in replicated storage."

    Let's create another script, but this time, a regular script in ServerScriptService:

    3.PNG.31e019c69bdaf9bcf65039cf34b01f9b.PNG

    Now, in this script, ask the server to tell us when we fired our event.

    game.ReplicatedStorage.OurEvent.OnServerEvent:connect(function()
    -- put code to do after the event has fired
    end)

    I hope this improved your knowledge on RemoteEvents, these are the very basics, but I hope you learned something new!

    • Upvote 4
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.