There are two main languages used when working with TFS: XML and Lua. Depending on your knowledge, you may also want to edit the sources, which would mean you would have to work with C++ as well. XML is a markup language that lets you register Lua scripts and store information, while Lua is used for scripting and interacting with the game world. You can start learning Lua with Programming in Lua or Stigma's Lua guide.
TFS scripting interface
There are a few main functions that are needed when creating scripts.
The current scripting interfaces are: Actions, Chatchannels, Creaturescripts, Events, Globalevents, Monsters, Movements, Npc, Spells, Talkactions and Weapons.
For scripting purposes, you should use some reference or memorize the main functions used in these interfaces: