Results 1 to 1 of 1

Thread: Help with creating a function and how to enable settings

  1. #1
    Normal User
    Join Date
    Mar 2013
    0 Post(s)
    0 Thread(s)
    0 Post(s)
    Rep Power

    Help with creating a function and how to enable settings

    I don't know how to make functions?

    I want to have a function that prints a message on the client that displayed what the bot is doing.
    For example if it's going to deposit then it will display message on the screen for me so I know what it's doing.

    My attempt was making an action and wrote this inside it:

    msg = notification
    setfontstyle(Verdana, 34, red)
    addtext(notification, 300,300)

    But how can I pass a message to this function? I was hoping something like function("notification").
    and then every time i use that function with a message the message is displayed at 300,300 for a few seconds.

    Also I made this so I can decide what spells to choose depending on what vocation:

    if vocation != 1 then -- If char is not a knight
    setsettings("Settings\\Healer\\Rules\\Exura\\Enabled", yes)
    setsettings("Settings\\Healer\\Rules\\Exura Ico\\Enabled", yes)

    I made it on an action waypoint at the top cavebot waypoints.
    But it doesn't work.
    This is also where I will add code to display message like function("Enabling light healing (exura) because you are not a knight").
    Last edited by Serdig; 03-24-2013 at 07:25 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts