[ian-reeds-games] Scripters

  • From: Ian Reed <support@xxxxxxxxxxxxxxxxxxx>
  • To: ian-reeds-games@xxxxxxxxxxxxx
  • Date: Sat, 19 Jan 2013 22:44:05 -0700

Greetings Carlos and Craig,

Well scripting for TB is here. It was definitely a lot of work but I'm pretty happy with where it's at now.

You can find the Scripting Guide in the Data for TB folder it's called Scripting.md.html.
I've put a lot of effort into the guide so I hope it works well for you.

Have a look at the Testing.js script I wrote and add some of the events defined in the comments to your default map flags file or your skill files to see them in action. They are pretty random and not really useful but demonstrate how to do some helpful things.

I think scripting will be a bit rocky to start with but as time goes on we will work through the issues and get more variables and functions exposed to let you do all sorts of things with it.

After you've had a chance to see what's their and do some quick test scripts be sure to let us know what feature you are working on so that we don't duplicate each others work.

Here are some suggestions for things I think could be implemented with what is currently exposed:
1 Make on_key events that give better information about your surroundings.
2 Make a permanent charm skill by changing the team of the target. (I will probably replace this in the not too distant future, but you will probably finish it quicker.) 3 Make a drain point skill, it should take the point name as a parameter so it could be used for health or mana or whatever. 4 Make a random effect skill, it could take an array of effect names of which one will randomly be chosen.

You'll find that sometimes the naming convention of variables is camel casing and other times it's proper casing. This is due to proper casing being the standard in C# and camel casing being the standard in javascript. So you'll just have to pay careful attention to which variables use which convention.

When you complete features we should document them.
I intend on adding a new section to the main user guide for features created by scripters. This will be a good place for the documentation and a good place to give credit to those who added the features. The user guide is written in markdown so maybe you could send me that. Or in the beginning you could just send me text documentation and I'll adjust it for the user guide.

Well thanks again for your willingness to help.
Remember there is no pressure so if you find yourself more interested in map creation than scripting I won't have my feelings hurt.
Well, not too badly anyway, smile.

Cheers,
Ian Reed


Other related posts: