Hey gamers programmers, first tutorial on here and I’m planning to do more. In this tutorial I will discuss basic programming terminology and tutorials later on. This series of tutorials is meant to be a crash course and will progressively get more advanced as I move through these tutorials.
I hope this tutorial is well explained and accessible, thanks for taking interest in this.
Terminology
Well, programming is supposed to be universal and so is it’s terminology. Don’t worry, these aren’t hard to learn and (hopefully) will easily be remembered.
- Globals – Globals are a blanket term for functions/variables which can be called from any type of script (modulescript, localscript or script).
- Global Functions can be called from any script and can be used anywhere! (take
require
for example) - Global Variables are variables which can be called anywhere! Like the
workspace
constant (it’s a constant because it’ll always exist no matter what) ormath.pi
(which is also a constant because there will never be a day where pi doesn’t exist, cherry pie don’t leave me please ) .
- Global Functions can be called from any script and can be used anywhere! (take
- Functions, basically something which performs a specific task (even if it’s creating a black hole!).
- Variables, little snippets of information within code. From text “Ewan is a Noob” to numbers like 1337.
- Serialization, turning an instance into a piece of information which can be used later. Like packing SFOTH into a table and using it later (see this epic article for more info).
- Deserialization, turning a piece of serialized data into something physical. Like a brick for example!
- Libraries, basically a blanket term for specialized functions. Like mathematical based operations like
math.tan
. This is what you plug your code into rather than framework which is the opposite. -
Replication, essentially sharing a piece of data (like an instance or string) between multiple clients/systems.See Starmaq’s reply.
Okay that should be a good starter!
Events
What are Events?
I’m glad you asked, events are something which fire (start) when a certain action is performed. Like me washing my car for example. These can be used to make killer bricks >:) or similar. This should go above but I like readability .
Tables
What are tables?
Tables are a form of representing large quantities of data within code, like how many pies Bob, Jerry and Toby has.
local array= {20, 20, 500} --this is an array
local dictionary = {bob = 20, jerry = 20, toby = 500} --this is a dictionary
local dictionary2 = {
["bob"] = 20;
["jerry"] = 20;
["toby"] = 500;
}
Frameworks
What are they?
Frameworks are just a big fancy word for a group of modules which are specialised to do a certain task, like a FPS system.
API
What is this?
It’s an abbreviation for Application programming interface. It’s a bit like a framework accept it’s on a much grander scale. It is just a big term for what a set of functions go under, like calling wait
would be under the Roblox Lua API.
Okay okay, that should be enough info. (I promise)
Well done for making it this far and making it through my rambling, I now gift you with this:
Gift
My best practises for trying to code.
When I was in my first few months of programming, I would just copy and paste code from the tutorial. If you want to learn, DO NOT do what I did. Instead, experiment with the code and think: “Hmm, what would happen if I changed this to this?”.
Another good practise for writing long scripts is to write a small plan down on a bit of paper. A flow chart is what you are looking for here. I find that no human can write long pieces of code just from their head. It’s a lot of hassle and sometimes you’ll forget what you are even supposed to do! If you don’t like writing on paper, use this website for making one yourself. Heck, even reply with ones you personally like!
Okay awesome, hopefully you have more information in your noggin than about 10 minutes ago!
In the next tutorial, we’ll be looking at CFrames and the more mathematical side of programming in Roblox! Also, all feedback is welcome. Just don’t make it destructive