There are a variety of bots already written that will do all kinds of things. You will be best off checking script sites like the one given above to see what is available and figure out exactly what you need. In most cases, there will already be something written for you.

As far as learning to script, the help file is a great resource. Start with a simple script, such as using on TEXT to respond to certain triggers...

Code:
on *:text:some trigger:#channel: {
  echo -a I am echoing something...
  msg $chan I am saying somthing in the channel...
  describe $chan I am using /me in the channel...
  msg $nick I am sending a message to the person who typed the trigger...
}


And so on. This is the base for any bot script. Use /help on text for syntax and other information. From there, just expand outward. Again, you'll want to start small and work up to something big; not the other way around.