Functions - Roblox Scripting Tutorial

แชร์
ฝัง
  • เผยแพร่เมื่อ 16 พ.ย. 2024

ความคิดเห็น • 879

  • @AlvinBlox
    @AlvinBlox  3 ปีที่แล้ว +521

    Thanks for the support on this series so far everyone :)

    • @SiddharthKSampada
      @SiddharthKSampada 3 ปีที่แล้ว +5

      First!

    • @SiddharthKSampada
      @SiddharthKSampada 3 ปีที่แล้ว +12

      And also Alvin your tutorials help me soo much
      Keep making great tutorials like this which helps me and my fellow scripters a lot.
      TY

    • @windindustries4486
      @windindustries4486 3 ปีที่แล้ว +1

      :)

    • @zerodevsz5505
      @zerodevsz5505 3 ปีที่แล้ว

      First

    • @I_am_thing
      @I_am_thing 3 ปีที่แล้ว +1

      Can u friend me on discord Alvin I have a question I_Am_thing#2266

  • @darien-
    @darien- 3 ปีที่แล้ว +198

    I love this guy so much, He's been doing the same series for 3 times now. From the time his voice was so small to a full grown teenager. I have to admit, I'm not an OG fan but I'm still glad I found his channel. Because of him, I made almost 3k robux from 3 seperate games that I made with a help from Alvin's videos.
    I pretty much quitted being a developer and forgotten all the scripting stuff. But this guy burst in with the tutorials. This can help me on making robux again. If you haven't subscribed, what are you doing in your life man.
    Alvin movin mad with the tutorials fam 🔥🔥

    • @Real_cheese3
      @Real_cheese3 3 ปีที่แล้ว

      @CROWN I R i know right ):

    • @hehehehe9104
      @hehehehe9104 3 ปีที่แล้ว

      @@Real_cheese3 ):

    • @aiky12rsa89
      @aiky12rsa89 3 ปีที่แล้ว

      amen

    • @firetiger1315
      @firetiger1315 3 ปีที่แล้ว +1

      It shows hes committed, he updates his tutorial every few years as roblox studios changes

    • @sausage-gobbler5392
      @sausage-gobbler5392 2 ปีที่แล้ว

      I love your channel

  • @nicolaifeldthaus4649
    @nicolaifeldthaus4649 3 ปีที่แล้ว +670

    Yo Alvin, have you ever stopped to think how many people you’ve helped? Thanks alot

    • @priz6751
      @priz6751 3 ปีที่แล้ว +2

      First

    • @be8090
      @be8090 3 ปีที่แล้ว +2

      Yes

    • @Djjskd
      @Djjskd 3 ปีที่แล้ว +16

      Im making a game for my friend birthday and I used free models but I thought what If. I made my own script so I'm starting

    • @thompie6877
      @thompie6877 3 ปีที่แล้ว +1

      First reply

    • @godlygamer2466
      @godlygamer2466 3 ปีที่แล้ว +2

      @@thompie6877 no u aint

  • @saadusmani78
    @saadusmani78 3 ปีที่แล้ว +96

    I want to say thanks to you. I have an interest in working at a space company in the future. And honestly, even though i am not coding much on roblox nowadays, i still have interest in roblox studio, and without it, i probably wouldnt have gotten interested in software engineering. And since u were my 90% source for learning roblox scripting basics, i really want to say thanks.
    Edit: You have literally affected many people's future, just by making videos.

    • @kestrells
      @kestrells 2 ปีที่แล้ว +1

      @Salxs Roblox scripting is considered 'easy' and is a good introductory way to get into scripting a step up from scratch

    • @spoopygmd
      @spoopygmd 2 ปีที่แล้ว +1

      @@kestrells it depends what you are making

    • @hieu216tdq8
      @hieu216tdq8 2 ปีที่แล้ว

      @@kestrells yep

  • @thedripduck8688
    @thedripduck8688 3 ปีที่แล้ว +19

    i love seeing him progress from a kid and still being so helpful

  • @eronkarlvictorino7401
    @eronkarlvictorino7401 3 ปีที่แล้ว +34

    i love this series it gets better everytime

  • @ultra3806
    @ultra3806 3 ปีที่แล้ว +17

    thanks for these honestly, I have a year of lua experience now because of your 2020 series

  • @duckyslay346
    @duckyslay346 3 ปีที่แล้ว +7

    this is so helpful!! i am an "old" roblox dev and moved to JavaScript and forgot how to script with roblox.... This series is so helpful!! Thank you bro

  • @detrimentaldoge5464
    @detrimentaldoge5464 3 ปีที่แล้ว +5

    I’ve grown an interest in making a roblox game, and this is getting me really excited. The function part looks really cool, and I already understand it thanks to some experimenting in scratch.

  • @reolizations5331
    @reolizations5331 3 ปีที่แล้ว +107

    Ahh yes that time of year :)
    Could we also possibly get an advanced animation video in the future too? Like custom rigs, making a spell appear out of nowhere, those kind of fundamentals?

    • @mantis3069
      @mantis3069 3 ปีที่แล้ว

      That would be nice

    • @slenderslayer464
      @slenderslayer464 3 ปีที่แล้ว

      2021 Tutorial didnt ended, maybe he can

    • @curtistrinh5654
      @curtistrinh5654 3 ปีที่แล้ว

      I know how to do custom rigs and anaimations

  • @namesroger2120
    @namesroger2120 3 ปีที่แล้ว +8

    These tutorials help me so much, because Alvin explains them so well, and explains the way the code behaves, meanwhile I just resume the stuff on my book, which helps a ton, thank you Alvin. And don't stop making these, you make for a great teacher.

  • @adventureboy444
    @adventureboy444 3 ปีที่แล้ว +94

    Yay another tutorial. I am looking forward for it.

  • @bloxquiiity3861
    @bloxquiiity3861 3 ปีที่แล้ว +55

    I would like to add one somewhat helpful tip to this tutorial! You can simplify the script even more rather than leaving the argument every time with changeTransparency(game.Workspace.AlvinBlox, 0.5) or whatever.
    We can shorten it using Local and naming the part something simple as it follows :
    local Subject = game.Workspace.AlvinBlox
    function changeTransparency(part, newTransparency)
    part.Transparency = newTransparency
    end
    changeTransparency(Subject, 0.5)
    wait(2)
    changeTransparency(Subject, 0.75)
    Hope someone finds this useful! I just thought of it while also trying to pick on learning scripting again watching these awesome tutorials!

    • @wimpyoul4623
      @wimpyoul4623 3 ปีที่แล้ว

      Thanks a lot! 😀

    • @elomelosky
      @elomelosky 3 ปีที่แล้ว

      TY

    • @seeroktic
      @seeroktic 3 ปีที่แล้ว +2

      Yes, it's simpler, but he most likely didn't do this as he hasn't touched on variables in this series yet.

    • @shikiraunderworld6762
      @shikiraunderworld6762 2 ปีที่แล้ว

      Thanks, when i did alvins way it didnt work.........

    • @sahedulhasan8453
      @sahedulhasan8453 2 ปีที่แล้ว

      ​@Varil Celan Worked for me though, you should probably check thoroughly for any mistakes. Something like this happened to me once, I overlooked the mistake and then finally after 10 minutes I noticed it.

  • @meimark4879
    @meimark4879 3 ปีที่แล้ว +5

    Hey Alvin, I was just passing by and saw this video, even though I know lua, i still wanted to check it out, its so nice you help others achieve their dreams

  • @ArmiRoblox
    @ArmiRoblox 3 ปีที่แล้ว

    I've wanted to make my own game since 2015 and I keep giving up and trying again but the videos all are hard to understand 6 years later I started watching you and you've helped a lot thank you so much AlvinBlox! you're the best.

  • @ClassyMen1919
    @ClassyMen1919 3 ปีที่แล้ว +5

    This is the only tutorial series where I actually can learn and understand what's happening.

    • @nj5916
      @nj5916 3 ปีที่แล้ว

      right

    • @yeah_hell
      @yeah_hell 2 ปีที่แล้ว

      @@nj5916 left

    • @sahedulhasan8453
      @sahedulhasan8453 2 ปีที่แล้ว

      @@yeah_hell up

    • @Sky23232
      @Sky23232 2 ปีที่แล้ว

      @@sahedulhasan8453 down

  • @OptimalCaptain12344
    @OptimalCaptain12344 ปีที่แล้ว +1

    You're helping so much people with these videos on scripting including me. I would not be where I am without you.

  • @Typhooone
    @Typhooone 2 ปีที่แล้ว +4

    Hello Alvin! using your coding and the stuff ive learned i made a simple command to say "hello World!" then make a blocks texture pebble, wait 5 seconds then make it clear! thank you for posting these videos!

  • @anxryy2469
    @anxryy2469 3 ปีที่แล้ว +4

    You explain everything very smoothly and make sure it’s easy to understand. Thank you, I am learning how to script at a fast rate.

  • @smallsynth
    @smallsynth 2 ปีที่แล้ว +1

    these are suprisingly easy to follow, yet so useful. im not an easy learner at all, sometimes it takes me months to learn stuff in school, but this? thank you so much.

  • @pokeben4593
    @pokeben4593 ปีที่แล้ว +1

    this guy is so good at teaching roblox code

  • @ThatGuyOnTheInternet1
    @ThatGuyOnTheInternet1 2 ปีที่แล้ว

    Alvin, without you in our world, roblox studio wouldn't be a thing

  • @mrbriggs390
    @mrbriggs390 3 ปีที่แล้ว +1

    The vids in this series are literally the only scripting lesson vids I actually understand 😅 so yah Tysm for the awesome vids keep it up ☺️

  • @melonsmusicstudio5698
    @melonsmusicstudio5698 3 ปีที่แล้ว

    Alvin blox, you basicly inspired me to watch ur vids and learn scripting in roblox, which ya’ helped me with along the way. Thank you.

  • @shyam8197
    @shyam8197 3 ปีที่แล้ว

    i have watched millions of scripting tutorial but never understood
    but i understand only u
    u are the best

  • @RainyPlaysRoblox
    @RainyPlaysRoblox 3 ปีที่แล้ว +1

    Hi I’m a python developer and I didn’t know roblox Studio and python code is so similar they are both easy for beginners thanks man I really enjoy watching ur videos and in the same time I learn it’s a win win dude appreciate it

  • @cattowrr
    @cattowrr 3 ปีที่แล้ว

    i like how this is a series that is probably gonna keep on going for years on years

  • @orangebiscuit9560
    @orangebiscuit9560 3 ปีที่แล้ว

    I didnt know how parameters worked this cleared all my doubts Thank you so muuch

  • @xcale4310
    @xcale4310 2 ปีที่แล้ว

    Yet again, helped so much! This is the script i came up with (the part is Xcale)
    print("Script began")
    function changeTransparency(part,newTransparency)
    part.Transparency = newTransparency
    end
    print("Lines 2-4 executed")
    changeTransparency(game.Workspace.Xcale,0.5)
    print("Executed line 6")
    wait(2)
    print("Executed line 8")
    changeTransparency(game.Workspace.Xcale,0)
    print("Executed line 10")
    wait(2)
    print("Executed line 12")
    changeTransparency(game.Workspace.Xcale,1)
    print("Script ran successfully")

  • @JeramayaGaming
    @JeramayaGaming ปีที่แล้ว

    I did some other tutorials and this one is the one that explains everything the best.

  • @yes_people7139
    @yes_people7139 3 ปีที่แล้ว +1

    Thank you so much, honestly, I have had game ideas for years and just never understood what to do, but, now I'm getting there little by little because of these videos!

  • @beerusfn671
    @beerusfn671 3 ปีที่แล้ว +1

    i get so excited whenever u come out with a new tutorial

  • @DatOneGamerOfficial
    @DatOneGamerOfficial 2 ปีที่แล้ว

    watching your series is the only way i learned how to script
    thanks man

  • @robloxian4life445
    @robloxian4life445 2 ปีที่แล้ว +1

    thank you so much i wanna be a game dev when i become older and im working really hard to learn how to script and your videos help me alot thanks :)

  • @akiraum9782
    @akiraum9782 3 ปีที่แล้ว +1

    Just learned what debugging was. Thank you Alvin.

  • @cookiethedog1436
    @cookiethedog1436 2 ปีที่แล้ว

    I sometimes have good ideas for games but i have no experience you are saving my life

  • @KameronGT
    @KameronGT 2 ปีที่แล้ว

    Alvin your the goat man. I didn't understand any of this until I watched you. Thank you so much

  • @thatonegalazy2350
    @thatonegalazy2350 3 ปีที่แล้ว +1

    Alvin your the best I haven’t fully found out how to script but your the only youtuber who’s actually teached me for once

  • @proxigoat.
    @proxigoat. 2 ปีที่แล้ว

    this dude changed my life forever

  • @yeectc
    @yeectc 2 ปีที่แล้ว

    I really love how you put so much information into 10 minute videos!

  • @Crazy-wu8oj
    @Crazy-wu8oj 3 ปีที่แล้ว

    these series are going to help a ton because im trying to work on a game alone not knowing how to code or build things, but now im learning how to code and im taking notes on a note book to make sure i remember it. thank you for this! :)

  • @hoanghanguyen1410
    @hoanghanguyen1410 3 ปีที่แล้ว

    You are young but a great teacher. Kudos

  • @nic-guy-7
    @nic-guy-7 2 ปีที่แล้ว

    thank you dude i had forgotten how to make functions but now i remember how to because i watched 30% of the video

  • @Rafter101
    @Rafter101 ปีที่แล้ว

    this is the best tutorial ever ive always put off learning to code later since i thought it was going to be hard but this proves otherwise

  • @lav_fico
    @lav_fico 3 ปีที่แล้ว +1

    Thank you a lot, I was trying all things to develop: Animations, UGC, GFX, Building, Modelling. And I never saw this good Script Tutorials.

  • @planerunner4020
    @planerunner4020 2 ปีที่แล้ว +1

    Please Continue this series!

  • @valkryxdoesdesign
    @valkryxdoesdesign 3 ปีที่แล้ว

    Really nice to have an updated version of the beginner scripting tutorial and it's nice your back!

    • @AlvinBlox
      @AlvinBlox  3 ปีที่แล้ว +1

      Hey, thanks!

  • @therandomnova
    @therandomnova 2 ปีที่แล้ว

    Thank you for making these tutorials. I’ve come a long way in scripting on Roblox. My first scripting tutorials were these. They really helped me out.

  • @PersonallyGone
    @PersonallyGone ปีที่แล้ว

    I learned a lot from you and understand the most of things, learning functions are the most useful things if your a really bad typer or your hands hurt while doing typing. I really liked this video and I hope this comment gives you motivation

  • @hopeitworked2974
    @hopeitworked2974 3 ปีที่แล้ว +1

    Thanks soooo much for this series it helped SOOO MUCH ur the best person ever in scripting AND you know how to explain VERYYY WELL

  • @xcsdownfallrin6845
    @xcsdownfallrin6845 3 ปีที่แล้ว

    I like how he doesn't just bunch all yhe videos into one because when i see one hour plus tutorials i kinda feel overwhelmed

  • @LAT3R
    @LAT3R 3 ปีที่แล้ว +2

    Loved this! You make scripting somewhat fun while educational

  • @seespotbyte9920
    @seespotbyte9920 2 ปีที่แล้ว +1

    Thanks a million! Could never wrap my head around functions.

    • @AlvinBlox
      @AlvinBlox  2 ปีที่แล้ว +1

      You're very welcome! All the best to you my friend. Alvin

  • @lackinfr
    @lackinfr 2 ปีที่แล้ว

    I'm literally 11 and i started scripting.
    U won Alvin 😁

  • @tul4580
    @tul4580 3 ปีที่แล้ว +1

    Underrated and dedicated

  • @jamesisnotabeast8122
    @jamesisnotabeast8122 3 ปีที่แล้ว +1

    These scripting tutorials helped me alot! Thank you so much!

  • @CodeWithAbed
    @CodeWithAbed 3 ปีที่แล้ว +1

    i was confused in the first 2 minutes but then i understand thanks bro this was helpful too :)

  • @Corvus_the_wyvern
    @Corvus_the_wyvern 3 ปีที่แล้ว +2

    i finally understand parameters.

  • @greedoyt1138
    @greedoyt1138 2 ปีที่แล้ว

    OMG I JUST REALISED HOW HELPFUL THIS IS, THANK YOU SOOOOM MUCHH

  • @Apollo1428
    @Apollo1428 3 ปีที่แล้ว +1

    I am so happy about the fact that I've had to do little to no debugging so far.

  • @weenfle7256
    @weenfle7256 3 ปีที่แล้ว

    I tried to learn how to script sinxe last year but a lot of tutorials went straight to the point and it confused me- this one help me a lot 👌

  • @A1ic0
    @A1ic0 2 ปีที่แล้ว

    I love how much detail you put into your teaching!

  • @dauniverseitself7517
    @dauniverseitself7517 3 ปีที่แล้ว +6

    The moment I understood what he was talking about made me extremely happy.

  • @mvpbluesky9820
    @mvpbluesky9820 3 ปีที่แล้ว +12

    YAY A TUTORIAL AGAIN IM SUBS AND LIKEEEE LIKE IT SO MUCHHH!!!!!

  • @superlightning_yt7655
    @superlightning_yt7655 3 ปีที่แล้ว

    This is the only video that i havent skipped

  • @Queenofear
    @Queenofear 3 ปีที่แล้ว

    This is so interesting... I never knew what functions actually did but it all makes sense now.

  • @SupaThanos
    @SupaThanos 2 ปีที่แล้ว

    bro alvin your tutorial is so good learned so much in so little time

  • @eggstatus5824
    @eggstatus5824 2 ปีที่แล้ว +2

    "Whats the point of making a function? It's not all that bad to write out a but more code"
    Not only is it needed for events, but it can also help optimize your game. As in, the more efficient your code is, the better your game will run. So you aren't dropping fps for a dumb reason
    Cause, simply put, if an instruction sent to the cpu requires less code, it will be done faster. So obviously, it makes the program run faster

  • @cuppajoe2
    @cuppajoe2 3 ปีที่แล้ว

    I took a year of computer science in high school and hated it.
    So far I have learned way more from these videos then I did in that year (And I enjoy following along with my own game :)

  • @Smelliot4500
    @Smelliot4500 3 ปีที่แล้ว

    All you’re videos are so helpful and it’s for free you deserve more subs

  • @Btatue
    @Btatue 2 ปีที่แล้ว

    These tutorials are helping me so much! Thank you

  • @mezilga121
    @mezilga121 2 ปีที่แล้ว

    Tysm, i could make a cube that slowly dissapears over 1 second! That's the most advanced thing i've ever scripted.

  • @yassinsamir4508
    @yassinsamir4508 3 ปีที่แล้ว

    Alvin,u helped me alot thanks u so much I was gonna quit roblox studio but.you changed my mind I see your future being the best roblox employee and my dream is to work with u

  • @seylahbakez9504
    @seylahbakez9504 3 ปีที่แล้ว

    used this for reference for my first script, it worked!!! so proud of myself

  • @theman3033
    @theman3033 3 ปีที่แล้ว

    I have looked at tons of videos that teach LUA script. None of them worked except for Alvin's videos.

  • @kingjulienmonke9929
    @kingjulienmonke9929 3 ปีที่แล้ว +1

    Thank you so much for this series I’m working on my first game and it’s pretty big but I have zero knowledge keep up this series for people like me I learn a lot from you more people should be like you tysm

    • @wubbysalmon2072
      @wubbysalmon2072 3 ปีที่แล้ว

      Don't go for a big project first, start small and work your way up.

  • @apannisseberg3154
    @apannisseberg3154 3 ปีที่แล้ว +3

    Yey! New video!

  • @ast_jackm1902
    @ast_jackm1902 2 ปีที่แล้ว +1

    I love this series

    • @ast_jackm1902
      @ast_jackm1902 2 ปีที่แล้ว

      I give scripting tutorials

  • @lemonkeoof2512
    @lemonkeoof2512 ปีที่แล้ว +1

    i was subbed since 2017!

  • @WRLDPost
    @WRLDPost 3 ปีที่แล้ว

    I was looking forward to a new video on functions! I really enjoyed watching this episode!😀

  • @1mrguy133
    @1mrguy133 ปีที่แล้ว

    this is the easiest tutorial ive ever seen, it helps me alot cause i suck at scripting

  • @Corvus_the_wyvern
    @Corvus_the_wyvern 3 ปีที่แล้ว

    i watched this yesterday and learned so much i also took good notes but imma listen to it while reading comments.

  • @mreddie4014
    @mreddie4014 2 ปีที่แล้ว +1

    I was doubting me being able to make a game with this series but by looking at the comments, I'm hopefull! :D

  • @grileck6094
    @grileck6094 3 ปีที่แล้ว

    ilysm, you explained it clearly.

  • @VOR8EX
    @VOR8EX 2 ปีที่แล้ว

    Alvin i dont know what i would do without you :)

  • @DatToxicGuy
    @DatToxicGuy 3 ปีที่แล้ว +2

    Thanks! :D
    It was painful at first, but now, I have got it! :D
    KEEP IT UP! :DDDDDDDDDDDDDDD

  • @tartieswife4551
    @tartieswife4551 3 ปีที่แล้ว

    These are AMAZING tutorials, I literally started coding today and I know a lot more than I thought I would. Your getting a sub!!!

  • @AtrashEditor
    @AtrashEditor 2 ปีที่แล้ว

    Oh my god thank you Alvin! Because of you I’ve learnt something I never thought I’d learn

  • @jasonkloesel5113
    @jasonkloesel5113 2 ปีที่แล้ว

    At first, I was too scared to make my dream game (A horror one) 😅. But now I made a 60 FPS game. Thanks a lot😊

  • @darichdoge256
    @darichdoge256 2 ปีที่แล้ว +1

    We always put the fun in functions!

  • @bricks5045
    @bricks5045 3 ปีที่แล้ว

    You deserve a lot more views man! Thanks!

  • @ridhomblr
    @ridhomblr 2 ปีที่แล้ว

    Tysm!!! I saved thousands of lines of code by using functions!!!
    Instead of copying code manually to each action, you could do actionFunction(argument)
    This is awesome! 😎 👍

  • @jacehi2u
    @jacehi2u 3 ปีที่แล้ว

    Thanks alvin! this years tutorial imo was the best explained out of all and you help me learn simple lua scripting :D so far i know (while true do, if statement, fynctions, properties, how to make a leaderboard, findfirstchild) and so much more that i cant think of rn Thanks man :D

  • @jaystudios4252
    @jaystudios4252 2 ปีที่แล้ว

    ive allways wanted to learn functions ty!

  • @hencethecreator9718
    @hencethecreator9718 2 ปีที่แล้ว +1

    you could use a avariable so that you dont have to write
    game.Workspace.Alvinblox
    for example:
    function changeTrans(part,NewTrans)
    part.Transparency = NewTrans
    end
    changetrans = game.Workspace.Baseplate.Part
    changeTrans(changetrans,1)

  • @HanselDominc
    @HanselDominc 2 ปีที่แล้ว +1

    Here is a simpler explanation if you still dont understand
    Functions are something you can store code in, but that isnt the best way to explain it
    Lets say if someone joins and you want it to print something, but you also want it to happen when you touch something. So you use the same function for example.
    function SampleFunction()
    print("Yay!")
    - - Or other lines here
    end
    game.Player.Playeradded:Connect(SampleFunction)
    workspace.part.Touched:Connect(SampleFunction)
    They both use the same 'function' because I connected them to the function I wanted to (SampleFunction)
    So if someone joins the game it prints the "Yay!", or if someone touches a specific part it also Prints "Yay!"

  • @exomonoko2888
    @exomonoko2888 3 ปีที่แล้ว

    ive been watching since your 2020 series, nice job man. you do a good job going in depth on nearly everything and im coming back to see what your doing different for the new series :)

  • @Angel-fl6ny
    @Angel-fl6ny ปีที่แล้ว

    thank you for switching to dark mode as soon as tutorial 3

  • @_butter.
    @_butter. 3 ปีที่แล้ว

    I gave my test subject a friend, thanks for the tutorial!

  • @whybibble8957
    @whybibble8957 ปีที่แล้ว

    This is a big progression! now i can make stuff change transparency in front of my eyes in the game!