Author Topic: timer.  (Read 2709 times)

0 Members and 1 Guest are viewing this topic.

Offline kdzhiiTopic starter

  • Jr. Member
  • **
  • Posts: 44
  • Activity:
    0.4%
  • Reputation Power: 1
  • kdzhii has no influence.
  • Respect: 0
  • Referrals: 0
    • View Profile
timer.
« on: June 05, 2013, 11:38:26 PM »
0
hey guys. whats a nice way to create a script based on a timer?
i`m playing the old sphere and a nice way to farm money with a mage is by killing monsters in polymorph form. After its casted, it lasts about 10 minutes, so i need to create a timer. I`m planning that script will include a couple of things like 2 healing methods to keep myself alive, drinking refresh potions, invisibility potions if HP gets low. I just don`t know how to still update a timer constantly besides fighting monsters and healing myself ;<
thankss.

Offline Crome969

  • Elite
  • *
  • *
  • Posts: 2098
  • Activity:
    0%
  • Reputation Power: 25
  • Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.
  • Gender: Male
  • UO Enthusiast
  • Respect: +211
  • Referrals: 10
    • View Profile
    • ScriptSDK
Re: timer.
« Reply #1 on: June 06, 2013, 12:58:31 AM »
0
hey guys. whats a nice way to create a script based on a timer?
i`m playing the old sphere and a nice way to farm money with a mage is by killing monsters in polymorph form. After its casted, it lasts about 10 minutes, so i need to create a timer. I`m planning that script will include a couple of things like 2 healing methods to keep myself alive, drinking refresh potions, invisibility potions if HP gets low. I just don`t know how to still update a timer constantly besides fighting monsters and healing myself ;<
thankss.

Normal i would say use Datetime.Now + delay. In easyuo you could use http://wiki.easyuo.com/index.php?title=SCnt2 or http://wiki.easyuo.com/index.php?title=SCnt and then add 10 * 60 * 10 for scnt2 or 10*60 for scnt to the current represented value. So you will have a value in future wich will step in after 10 Minutes. Script sided you can just run your script and check in some intervals if #scnt or #scnt2 got bigger than your saved value ( this would mean you reached 10 Minutes ).

Offline kdzhiiTopic starter

  • Jr. Member
  • **
  • Posts: 44
  • Activity:
    0.4%
  • Reputation Power: 1
  • kdzhii has no influence.
  • Respect: 0
  • Referrals: 0
    • View Profile
Re: timer.
« Reply #2 on: June 06, 2013, 03:19:28 AM »
0
thanks. did as u say. works :)

Offline Crome969

  • Elite
  • *
  • *
  • Posts: 2098
  • Activity:
    0%
  • Reputation Power: 25
  • Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.
  • Gender: Male
  • UO Enthusiast
  • Respect: +211
  • Referrals: 10
    • View Profile
    • ScriptSDK
Re: timer.
« Reply #3 on: June 06, 2013, 04:47:10 AM »
0
thanks. did as u say. works :)

No Problem. Thats how a community works :-) Give and take..

Offline Alpha

  • Hero Member
  • *
  • Posts: 583
  • Activity:
    0%
  • Reputation Power: 10
  • Alpha barely matters.Alpha barely matters.
  • Respect: +44
  • Referrals: 0
    • View Profile
Re: timer.
« Reply #4 on: June 06, 2013, 05:02:08 AM »
0
A Timer is a good way to go, but if there are any other "differences" that the new polymorph form gives your character you could watch for those & Re-cast if you don't find what you like.   I know wraith form changes your resistance values for an example so I could just check those values and when they aren't what they should be for wraith form you know the your human again etc.

Offline Crome969

  • Elite
  • *
  • *
  • Posts: 2098
  • Activity:
    0%
  • Reputation Power: 25
  • Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.
  • Gender: Male
  • UO Enthusiast
  • Respect: +211
  • Referrals: 10
    • View Profile
    • ScriptSDK
Re: timer.
« Reply #5 on: June 06, 2013, 06:05:21 AM »
0

Tags: