It never ceases to amaze me how articles on the developer wiki explaining these concepts fail to explain things like a UA-cam video can. I have been using [ ] for dictionaries, not knowing I could just use a period. And low and behold, it is because there is no mention of that on the dev wiki.
@@CyberFlameYTB Perhaps for you, but for someone with no programming experience learning their first language, it might not be! No reason to throw someone an insult because you have more experience in the field!
I love that unlike the other UA-camrs you don't play around with the super basics like how to tie your shoe in every single video seems like all the other content creators are just making videos for people who just discovered studio for the first time and they never move past the extreme basics
Thanks mate that helped a lot! its really hard to find high quality content like this as such videos don't show up in the recommendations nor when searching for them...
This is a great video. Thank you! If I may make a suggestion, you want to not smack your mouth after you make a point. It's a bit offputting, especially for those wearing headphones. Thanks for explaining tables, it helped!
super good overview of how tables work! I was wondering, is there a way to directly put each value of a table into a variable (e.g. variable1, variable2) using a for loop and some clever use of the i variable? I can't tell if I'm looking past an obvious solution or if it's deceivingly complicated to do
You could do that with some meta programming but if I’m being honest I don’t know why you ever would. If the table is small you could use table.unpack and then set a bunch of locals seperated by a comma
local myTable = {"Wow!","Amazing","Tutorial!"} for i,v in pairs(myTable) do print(i) wait(.75) print(v) end -- I knowned this in my head still thinking of it Lol
tysm for making this video i already know the coding fundamentals and stuff but some stuff about tables i never knew about i now know like table.unpack! ty bro
how do i get the last value from a table? if i dont know how long that table will be, how do i get the last value from the table? i've tried but nothing works!
how about: for i, parts in pairs([group the parts you want to make transparent and insert the models name here]:GetDescendants()) do parts.Transparency = 1 end -btw idk if it will work
hey guys i need help with my script that i cant get it to print the value instead of the index can anybody help? local maps = {game.Workspace["The Forest"],game.Workspace["Mad City"]}
local winningMap
for index, value in pairs(maps) do winningMap = math.random(1,#maps) wait(1) print("CHOSEN MAP NAME IS "..winningMap.."!") wait(1) break end
It never ceases to amaze me how articles on the developer wiki explaining these concepts fail to explain things like a UA-cam video can. I have been using [ ] for dictionaries, not knowing I could just use a period. And low and behold, it is because there is no mention of that on the dev wiki.
because its common sense
@@CyberFlameYTB Perhaps for you, but for someone with no programming experience learning their first language, it might not be! No reason to throw someone an insult because you have more experience in the field!
@@CyberFlameYTB Nothing about programming is "common sense." That's a ridiculous statement that belies all introspection.
I love that unlike the other UA-camrs you don't play around with the super basics like how to tie your shoe in every single video seems like all the other content creators are just making videos for people who just discovered studio for the first time and they never move past the extreme basics
That's my goal exactly: there is a content gap for people who want advanced stuff.
holy moly this is clear as heck
super underrated youtuber man teaches better than the dev king
Thanks mate that helped a lot! its really hard to find high quality content like this as such videos don't show up in the recommendations nor when searching for them...
A youtuber who actually knows what they are talking about. Give this man a good mic, and a bit more confidence on camera and he could pass TheDevKing.
Thanks! Helped me and the others alot. I hope you'll be able to provide more videos like this, because they're really helpful!
Thank you, sir, i was struggling with this pairs/ipars stuff in some script tutorials bc i had no idea what it was about... Now its clear :]
Finally figured out how to give an item to all players, thanks!
This video is the best video to explain tables holy cow
Thanks!
This is a great video. Thank you! If I may make a suggestion, you want to not smack your mouth after you make a point. It's a bit offputting, especially for those wearing headphones. Thanks for explaining tables, it helped!
super good overview of how tables work! I was wondering, is there a way to directly put each value of a table into a variable (e.g. variable1, variable2) using a for loop and some clever use of the i variable? I can't tell if I'm looking past an obvious solution or if it's deceivingly complicated to do
You could do that with some meta programming but if I’m being honest I don’t know why you ever would. If the table is small you could use table.unpack and then set a bunch of locals seperated by a comma
very good explanation!
Thank you keep up the awesome tutorials!!
Thank you!!! keep up with this greats tutorials!!
thanks, so useful.
local myTable = {"Wow!","Amazing","Tutorial!"}
for i,v in pairs(myTable) do
print(i)
wait(.75)
print(v)
end
-- I knowned this in my head still thinking of it Lol
tysm for making this video i already know the coding fundamentals and stuff but some stuff about tables i never knew about i now know like table.unpack! ty bro
Not quite everything. I have been looking how to clone tables where i it will change the RAM address and i still couldn't find the way
all i want to know is how to add things to the table, remove things from the table and test if you have things inside the player : (
12:40
woah this was really helpful thanks man!
hey how exactly would you do it if you were working with numbers? (like "for i, 1+500 in pairs(c) do ... end")
how do i get the last value from a table?
if i dont know how long that table will be, how do i get the last value from the table? i've tried but nothing works!
You have to use the length of the table: tbl[#tbl]
@@BRicey thanks
Thank you!
Very helpful, thank you :D
Would it be possible to add multiple parts to the table and then just do MyTable.Transparency = 1 for example and it would change all of the parts?
No, you would have to loop through all of the parts in the tabel
how about:
for i, parts in pairs([group the parts you want to make transparent and insert the models name here]:GetDescendants()) do
parts.Transparency = 1
end
-btw idk if it will work
@@paopaothemaocow Thanks! ill give it a try
@@halifox2244 did it work?
@@paopaothemaocow i havent tried it yet, i will update when i have
Great, amazing video. But what about table.upack :(
Decimals is float
No, decimals in lua are doubles, not floats
B Ricey oh i didnt know that
B Ricey you still helped me a little bit
hey guys i need help with my script that i cant get it to print the value instead of the index can anybody help?
local maps = {game.Workspace["The Forest"],game.Workspace["Mad City"]}
local winningMap
for index, value in pairs(maps) do
winningMap = math.random(1,#maps)
wait(1)
print("CHOSEN MAP NAME IS "..winningMap.."!")
wait(1)
break
end
winningMap = maps[math.random(1, #maps)]
@@rashy15 sorry man i fixed it the day i've sent this message
Wow thx
So tables are harder than they look
No
i am new
Great!
boring fact: ipairs runs faster than pairs
you aswell can commenting like:
not commented
--[[
commented
commented
commented
commented
]]
not commented
wouldn't it be "]]--" on the second last line, or does that not matter?
no+why did you self liked? 💀@@FloxyCola
@@yarik_superpro I didn't like it, someone else did ig? also I tried the ]]-- thing yesterday and it worked...you should try it too lol
Please get a better mic it's so hard to hear you.
I did, check out my latest video