Author Topic: Torque Script  (Read 749 times)

I want to know how to code Torque Script.
Well, the way blockland does it.
Any suggestions?

- Make a thread right here for your questions.
- There are some beginner tutorials found on this forum.
- Read the code of other add-ons you have / especially ones related to what you want to do.
- This board right here is the worlds largest resource for torkscript, searching it usually gets you a solution.


Zeblote, if I may ask, where did you learn Torque Script?

Reading other scripts. I also made this super fail topic and a few others that aren't so fail.

Before that I was playing around with eval on Negative's server. First just copy pasting code I found in "console command list" topics and nonsense like that, then slowly understanding what they do and modifying them. I remember Port was also playing around with eval on that server and he used packages and functions, so I asked what he was doing, and he explained it. Then I knew how to create functions and what the point of a package is. It just went along from there, reading other scripts, asking people what stuff does, trial and error, etc

I learned from Ibans CityRPG. Worst mistake ever. Learn by looking at other peoples scripts. However don't I repeat DON'T try and learn from ANY cityRPG. They are coded so hideously. Zebo knows the extent of the handicapation this has caused me.


There are tons of things that you can look at for reference. Things like Slayer, and Item Storage.

They have a wide range of things used in them, and you should be able to find whatever technique/methods you need inside them somewhere.

There are tons of things that you can look at for reference. Things like Slayer, and Item Storage.

They have a wide range of things used in them, and you should be able to find whatever technique/methods you need inside them somewhere.

Start small. Look at basic scripts before you go into the AAA mods. Ill give you a hint. Adding on to other peoples code is more difficult than coding yourself. When you add on to other peoples code you don't know what their functions do, how they do it, when they do it, etc.

I learned from Ibans CityRPG. Worst mistake ever. Learn by looking at other peoples scripts. However don't I repeat DON'T try and learn from ANY cityRPG. They are coded so hideously. Zebo knows the extent of the handicapation this has caused me.

I would strongly disagree, Iban's CityRPG is the best annotated and most modular code available for blockland, and at least when I was learning, everyone had experience with playing in a CityRPG.  I particularly like it because you can start off simple, simply modifying variables and learning to add new jobs and holidays like the mod is designed to let you do, and then get into more advanced stuff that involves editing functions, or even adding your own.  If you come across code you can't understand, even from reading the comments and descriptions, then maybe you are jumping in too deep too fast.

Start small. Look at basic scripts before you go into the AAA mods. Ill give you a hint. Adding on to other peoples code is more difficult than coding yourself. When you add on to other peoples code you don't know what their functions do, how they do it, when they do it, etc.

This I also disagree with in its entirety.  If you have a foundation for a mod you want to make in the form of an existing mod, then it is much simpler and usually a better learning experience to add on to it.  One of my first mods was a server chat mod that gave people titles and changed name colors and such, and there is probably no way I would have figured out how to do something like that if I didn't work off an existing chat mod first.
« Last Edit: April 08, 2014, 01:15:20 AM by Nexus »