Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

What do I need to know?

Relating to weapons and technology, what's the first thing I should learn about scripts before I should actually make one.

2 answers

There is nothing in particular about scripts or Lua as a language that relate specifically to "weapons and technology", but there are a lot of common functions and structures in the ROBLOX API that it would be useful to familiarise yourself with.

Being able to develop compelling weapons, vehicles, and other devices often hinges on some mathematical understanding. For example, you should understand what a Vector is and how to use the Vector3 structure, the principles of matrices and 3-dimensional transformations (represented in ROBLOX by CFrame), trigonometry, angles in radians - in short, geometry.

You should know about common data structures like arrays (called tables in Lua), what variables are, and what a ROBLOX Instance is.

You'll also find many useful functions to help with more advanced processes. For example, in 'modern' guns ray-casting is a common technique to simulate projectiles, for which you'll need to understand the Ray object and the FindPartOnRay method.

If you don't know anything about Lua, start with the basics. Don't take the "what do I need to make a gun" approach, learn all the fundamental principles and this will enable you to create whatever you want. Often help from your mathematics or computing teachers (if you have them) can be useful in grasping concepts that you don't understand. I'd recommend taking plenty of time to thoroughly go through as many Tutorials as you can.

Let me know if you have any further questions.

3 comments

0

How do I debug a script?

0

That is a question best asked as a separate post, but the easiest and often most convenient way to debug scripts is to use "print" statements and follow their output in the console.

0

You do not need to know a lot about math to make a gun. I hate math, but I can make guns on roblox.

you need to know what is Lua frist, Then you can start to look some free model script,if you think you is fully Learn ,you can try to make a game for test youself

This discussion is preserved as it was. New answers, comments, and votes are closed.