Exp Monitor MQ2Data compliant

A forum for you to dump all the macros you create, allowing users to use, modify, and comment on your work.

Moderator: MacroQuest Developers

n00bie
orc pawn
orc pawn
Posts: 26
Joined: Sun Feb 29, 2004 3:21 pm

Exp Monitor MQ2Data compliant

Post by n00bie » Thu Apr 22, 2004 3:03 pm

Updated for new data and added an estimated time till next AA. Still has slightly issues if you ding, like showing -xp, and is useless if you spend AAs since it can only count free AAs and not total.


Code: Select all

|======================================================================| 
| ExpMon.mac                                                           | 
|                                                                      | 
| Version:    1.0                                                      | 
| Date:       21 Feb 2004                                              | 
| Created by: NotHere - Based on code by daerck                        | 
|                                                                      | 
| Usage:      Expmon <interval>                                        | 
|                                                                      | 
| Displays a report every <interval> minutes containing:               | 
|  - current LVL and AA experience                                     | 
|   - How much was earned since last report                            | 
|   - How much was earned pr. minute                                   | 
|   - How much would be earned on an hour at the current rate          | 
|   - How long before the next AA ding				       |
|                                                                      | 
| If no interval is given, it will default to 10 minutes               | 
|                                                                      | 
|======================================================================| 

Sub Main 
  /declare ReportInterval Global 
  /declare Report Timer 
  /declare StartLvlExp Global 
  /declare StartLvl Global 
  /declare StartAAExp Global 
  /declare StartAA Global 
  /declare LastAAExp Global
  /declare LastLvlExp Global
  /declare TotalLVLearned Global
  /declare TotalAAearned Global
  /declare Counter Global
  
  /if (${Defined[Param0]}) { 
     /varset ReportInterval @Param0 
  } else { 
     /varset ReportInterval 10
  } 
  /varset Counter 1
  /varset StartLvlExp ${Me.PctExp} 
  /varset StartLvl ${Me.Level} 
  /varset LastLvlExp ${Me.PctExp}
  /varset LastAAExp ${Me.PctAAExp}
  /varset StartAAExp ${Me.PctAAExp} 
  /varset StartAA ${Me.AAPoints} 
  /varset Report ${Math.Calc[@ReportInterval*600]} 

  /echo [${Time.Time12}] ExpMon running. Will report every @ReportInterval minute(s) 

  :Start 
  /doevents 
  /goto :Start 
/return 

Sub Event_Timer() 
  /declare LVLearned local 
  /declare AAearned local 
  /varset TotalLVLearned ${Math.Calc[${Math.Calc[${Me.PctExp}-@StartLvlExp]}+${Math.Calc[${Math.Calc[${Me.Level}-@StartLvl]}*100]}]} 
  /varset TotalAAearned ${Math.Calc[${Math.Calc[${Me.PctAAExp}-@StartAAExp]}+${Math.Calc[${Math.Calc[${Me.AAPoints}-@StartAA]}*100]}]} 
  /varset LVLearned ${Math.Calc[${Math.Calc[${Me.PctExp}-@LastLvlExp]}]}
  /varset AAearned ${Math.Calc[${Math.Calc[${Me.PctAAExp}-@LastAAExp]}]} 
   
  /echo ----------------------------------------------------------- 
  /echo [${Time.Time12}] LVL: ${Me.PctExp} (@LVLearned%, ${Math.Calc[@TotalLVLearned/${Math.Calc[@ReportInterval*@Counter]}]}%/min , ${Math.Calc[${Math.Calc[@TotalLVLearned/${Math.Calc[@ReportInterval*@Counter]}]}*60]}%/hr] 
  /echo [${Time.Time12}] AA: ${Me.PctAAExp} (@AAearned%, ${Math.Calc[@TotalAAearned/${Math.Calc[@ReportInterval*@Counter]}]}%/min , ${Math.Calc[${Math.Calc[@TotalAAearned/${Math.Calc[@ReportInterval*@Counter]}]}*60]}%/hr] 
  /echo Next AA in ${Math.Calc[${Math.Calc[100-${Me.PctAAExp}]}/${Math.Calc[@TotalAAearned/${Math.Calc[@ReportInterval*@Counter]}]}]} minutes

  /varset Report ${Math.Calc[@ReportInterval*600]}
  /varset LastLvlExp ${Me.PctExp} 
|  /varset StartLvl ${Me.Level} 
  /varset LastAAExp ${Me.PctAAExp} 
|  /varset StartAA ${Me.AAPoints} 
  /varadd Counter 1
/return

Midnight
a lesser mummy
a lesser mummy
Posts: 68
Joined: Wed Nov 12, 2003 12:51 pm

Post by Midnight » Thu Apr 22, 2004 3:54 pm

Not exactly sure how this would be effective if you were using an attack or any kind of casting macros? You can only run one mac at a time. Think about making this a plugin that runs all the time instead? Curious how you have it working effectively.

Preocts
a snow griffon
a snow griffon
Posts: 312
Joined: Thu Jan 29, 2004 1:02 pm

Post by Preocts » Thu Apr 22, 2004 3:57 pm

Put it in your attack/casting macro :wink: