Learning the basics of scripting?

Before I start this I have many questions in this, as I’m writing this I don’t know how long this will be but thanks for sticking around and helping me out.

Learning the basics?
So I’ve been on the Roblox platform since 2017 though it isn’t a lot I’ve been thinking I want to make my own game instead of playing others games. I’ve tried building and such but I can’t find something that suits me until I found out about scripting. I think it’s fascinating how lines of code can bring a whole game together. I don’ t know where to get started though? I’ve looked up countless websites that try to teach the basics but I can’t seem to find one? I also don’t know if Lua is the right coding language for me but I’m pretty sure Roblox only supports Lua?

Managing time?
I work at some groups, yes corny people may say but I like it a lot actually. When you guys started scripting did you just give up and dive right into it? Someone was telling me I needed to only focus on scripting and nothing else on Roblox. I thought that was a very difficult thing for me to do, but if it has to be that way I’m willing to take that risk.

Conclusion
Sorry if I made this too long but I wanted to get my point around. And I’m known to ramble a lot so I’m very sorry if this doesn’t make any sense to you guys. I’d like to thank you for reading all of this if you’ve got to this part! Have a wonderful rest of your evening.

2 Likes

You can start by watching tutorial videos on Youtube(alvinblox and devking11 that I can suggest) and if you do want to learn faster I would recommend to only focus scripting for some time too. For managing time there is great techniques(Pomodore etc.) to manage your time while trying to learn and don’t forget to learn step by step.

Example: You can’t learn coroutines without learning basics of functions.

Hope you work hard and learn it!

1 Like

You can easily start by Getting free models in Roblox Studio and looking at the scripts in them. You then should try to figure out how they work. Imagine you are the script and the lines of code are your instructions.

2 Likes

First of all please correct your spelling of your title in the future of if so, do it now.

I’m am in the process of learning how to code and I can say it is quite fun once you figure out how certain things work. How I first tackled coding was thinking of a few different things I wanted to build and trying my best with Youtube videos and the Developer Hub to make those things reality. I don’t think your friend is correct on the part where you have to devote yourself to just scripting and nothing else on Roblox. If you enjoy playing the game I think you should keep having fun but to always remember that there is more code to learn and work to be done. Obviously it isn’t smart to code for hours on end since it is pretty tiring trying to debug code and to learn new things in general for long period of time. So take it slow, try to create small things that eventually lead into bigger things, and never forget to ask questions a long the way.

1 Like

Thanks for the tips! Will be trying this tomorrow.

1 Like

Okay, thanks for the tip with the title also! I hope your coding goes well also. :slight_smile:

1 Like

Honestly i recommend watching all of TheDevKing youtube videos. Not just his scripting tutorials, He teaches you all there is about roblox game development also and how to stay motivated, how to monitise your game etc.

@Alvin_Blox Is also 100% Worth the watch, although he has alot more videos :stuck_out_tongue_winking_eye: Some of his tutorials on how to make minigames etc are highly beneficial, Alongside his scripting tutorials.

A combination of watching these two, You will be scripting functioning games in no time :slight_smile:

1 Like

There are some scripting tutorials here on YouTube (I recommend @Alvin_Blox) or you can use the ones provided by Roblox here.

3 Likes

Okay, thanks so much for the tips! I see you’re a programmer can I ask you how long it took you to get good at coding?

No problem! I definitely wouldnt call myself good at coding, I’ve been coding for about a year on and off but really got into it about 3 months ago (Lockdown xd)

Honestly if you are in lockdown in your area and you have the time on your hands to watch these and learn, i couldnt see why, in 2 weeks you couldnt be an excellent scripter.

I also learnt python along the way, but a bit more recently. ( Youtube courses ) which helps you understand the basics of programming and can help you learn how languages work and compare.

1 Like

Agreed! Lock down is the best time to learn scripting I have all this time on my hand. Also, thanks again man have a wonderful day.

When I first started learning to script I was really doing the simplest of things. I started by just learning how print() worked. Although it seems super simple just using this can teach you the general idea of how Lua works.

print(5) -- Prints 5

print("Hello World!") -- Prints Hello World!

But obviously this gets boring after a bit and the computer isn’t doing much to give you the wow factor so you make you stretch your boundaries.

print(5+3) -- Prints 8

print("Hello".." ".."World".."!") -- Prints Hello World!

Now you got the computer doing some work to put your numbers and strings together. Except this is kinda boring since you just do nothing but change 1 line of code. Except, variables could change thins up a little.

local myVariable = "Hey I'm a variable!"

print(myVariable) -- Prints Hey I'm a variable!

But a variable isn’t just some text. It can be so much more! Variables can store anything. But for now lets keep it simplistic. How about we make a calculator that adds two numbers?

local firstNumber = 1         --Keep our two numbers in a spot that can easily be accessed
local secondNumber = 6

print(firstNumber + secondNumber)       --Prints 7

Now, we have a simple calculator but it’s no good if we have to keep changing the numbers manually. What if we could reuse our code but change the numbers? Well we can by using Functions! Here is an example below!

local function myFunction() --Define our function here and give it the code we want it to run
    print("Hello World!")
end

myFunction() --Call our function later in the code to have it run!

But how do we make this function into a calculator? Well we can give functions variables to use in their code!

local function addNumbers(Number1,Number2) --Noticed we add variables that the functions will want use
    print(Number1 + Number2)
end

addNumbers(3,4) --Now we add those two numbers in the same order they are listed in the function
addNumbers(5,6) --And now we just give it different numbers!

In conclusion, this is how coding works. You start with the most simple of code and expand on it.

Yes, you may aswell spend the time wisely doing something you want to learn/do, i’ve always wanted to learn how to program and ive been able to do so. Technically Coronavirus has been a blessing in disguise :slight_smile:
Have a wonderful day too man

2 Likes