WoolHat
|
  |
| Joined: 19 May 2013 |
| Total Posts: 1873 |
|
|
| 08 Jan 2016 07:14 AM |
Got any secret methods or events that you use, but not many people know about? Do you have any beneficial tips for beginner, intermediate or even advanced scripers? Post it here :D
This thread may die but that's okay. I love hearing advice on how to improve. |
|
|
| Report Abuse |
|
|
Ryuzoji
|
  |
| Joined: 21 Dec 2015 |
| Total Posts: 937 |
|
| |
|
WoolHat
|
  |
| Joined: 19 May 2013 |
| Total Posts: 1873 |
|
|
| 08 Jan 2016 08:38 AM |
I might add that this is intended to be a constructive thread. If you have nothing to add, please don't add anything.
I guess I should contribute. That's only fair. Keep organized.
This is usually how I set up my scripts: Global reference variables on top, after those come the value variables (references and values separated by a return),function definitions (each definition has a return before the next definition), basic operations (not assigned within a function, maybe a startup loop. This allows it to reference the above functions and variables), and lastly a list of events. |
|
|
| Report Abuse |
|
|
Egzekiel
|
  |
| Joined: 10 Jan 2011 |
| Total Posts: 1079 |
|
|
| 08 Jan 2016 09:09 AM |
Personally, i put all the variables at the top, in a certain order, at the middle i put the functions and at the bottom i call/connect the functions.
Also, when i have too much variables of the same type (Sounds, Animations,...) i make a table and call them from the table so it looks better.
|
|
|
| Report Abuse |
|
|
edenojack
|
  |
| Joined: 18 Jul 2008 |
| Total Posts: 989 |
|
|
| 08 Jan 2016 09:24 AM |
ModuleScripts can be called from a table, so just having you ModuleScripts in a folder means that instead of having to pre-define all of them, you can make a function that sorts through the folder, requires them and adds them all to a table. This is crazy helpful when you begin dealing with a load of them e.g: Using modules to hold information for Gear/Weapons/Tools. This is super helpful if each Item has individual stats/functions, as you just need to change the code in the modules, rather than make a HUGE script containing all their info and uses. |
|
|
| Report Abuse |
|
|
|
| 08 Jan 2016 09:28 AM |
Learning: -My best advice would be just go search for Friaza Hyuga on youtube and go search for his tutorial , seriously that man is a boss and give alot of well-explained tutorial! (No they aren't outdated, go check'em out.)
-Also , don't forget to check the roblox script wiki!
Training: -Set yourself a goal. Describe the step on how to make it achievable. Try to do it , even if you have little knowledge. Learn about how to do it. Repeat the same procedure and learn roblox lua script quick.
-Oh and yeah put the variables in the top please xD
|
|
|
| Report Abuse |
|
|
eLunate
|
  |
| Joined: 29 Jul 2014 |
| Total Posts: 13268 |
|
|
| 08 Jan 2016 10:14 AM |
Wow man why did the forums get so much noob.
Don't be efficient, be effective. Don't use a polling loop, use event connections. Use ModuleScripts. Use Locals. Use Valkyrie. Use Tables. Use Loops. Don't use viruses. |
|
|
| Report Abuse |
|
|
lupine
|
  |
| Joined: 24 Jun 2008 |
| Total Posts: 3561 |
|
|
| 08 Jan 2016 10:20 AM |
In addition to pretty much everything eLunate said,
Learn how to read the Object Browser. It's super awesome and useful |
|
|
| Report Abuse |
|
|
|
| 08 Jan 2016 10:27 AM |
I suggest 2 things: Play around with existing code. You can revert to the old code and compare the differences if you mess up. Learn the vocabulary. If you ask for help, you'll understand what they say better. You'll also understand output errors, so you can learn from your mistakes. |
|
|
| Report Abuse |
|
|
WoolHat
|
  |
| Joined: 19 May 2013 |
| Total Posts: 1873 |
|
|
| 08 Jan 2016 11:32 AM |
| I actually never did this :P it's on my to-do list now though |
|
|
| Report Abuse |
|
|
Link5659
|
  |
| Joined: 04 Jun 2012 |
| Total Posts: 4525 |
|
|
| 08 Jan 2016 11:34 AM |
elunate got it all
Scripter, Builder... Yet cant use events worth anything. (In Filtering Enabled) |
|
|
| Report Abuse |
|
|
nox7
|
  |
| Joined: 29 Aug 2008 |
| Total Posts: 27467 |
|
|
| 08 Jan 2016 12:22 PM |
| I'd recommend becoming familiar with CFrame's and the horrors/alternatives to Euler Angles: http://wiki.roblox.com/index.php?title=User:MrNicNac/CFrame_Cheat_Sheet |
|
|
| Report Abuse |
|
|
|
| 08 Jan 2016 01:21 PM |
| All the body objects (BodyPosition, BodyVelocity, etc.) are worth learning what they do. |
|
|
| Report Abuse |
|
|
|
| 08 Jan 2016 01:29 PM |
Maintain a balance between efficiency, readability, and functionality: all these things are important in the writing of your code.
Use local variables whenever applicable and use modules to ease up the process even more (especially if you have functions that need to be accessed through several different scripts).
Develop your own coding style, just prepare to be yelled at and falcon punched if your coding style involves unnecessary/unreadable/terribly inefficient code. |
|
|
| Report Abuse |
|
|