Results 1 to 21 of 21

Thread: best way to check EXP?

  1. #1
    Join Date
    Dec 2006
    Location
    Canada, BC
    Posts
    728
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default best way to check EXP?

    the title says it all. ive tried differant methods of getting the EXP gained as my scripts progress.. one function i used always had highlight the stat being checked, so i didnt like that way, seemed kinda bannable. Then i tried counting the monsters killed, and added there HP * 4 each time one died, but that dosnt give you a very accurate calculation does it? and now im training on goblins whos HP varies.. so yeah. what are the best ways to get the EXP gainned? i will rep+ the best helper ;D
    Lance. Da. Pants.

  2. #2
    Join Date
    Jan 2008
    Location
    California, US
    Posts
    2,765
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Well for fighting it is kinda hard if it is universal. But you can get the EXP at start of script, then get it at end and minus start from end.

  3. #3
    Join Date
    Dec 2006
    Location
    Canada, BC
    Posts
    728
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    i was thinking about that, but i was hopeing there would be a better way lol but sure ill try that thanks.
    Lance. Da. Pants.

  4. #4
    Join Date
    Dec 2008
    Posts
    259
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    If u are owning a specific monster, you could multiply monster hp with 4 i think (4 is how many xp u get when hitting 1)

  5. #5
    Join Date
    Feb 2007
    Location
    Access Violation at 0x00000000
    Posts
    2,865
    Mentioned
    3 Post(s)
    Quoted
    18 Post(s)

    Default

    Meh, with reflection it's easy ^^.
    Can't you count hits with some function and * 4 -> add to exp?
    Ce ne sont que des gueux


  6. #6
    Join Date
    Dec 2006
    Location
    Canada, BC
    Posts
    728
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    yeah, i was trying that before, but with goblins there HP changes, sometimes 5 sometiems 15 sometimes 20, so it screws up the exp = dammage * 4 thing. but for now just checking the xp before and after the scripts done is fine for me lol
    Lance. Da. Pants.

  7. #7
    Join Date
    Jan 2008
    Location
    California, US
    Posts
    2,765
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    No what Floris said will work. Count what you hit until they are dead and then multiply total by four.

  8. #8
    Join Date
    Feb 2007
    Location
    PA, USA
    Posts
    5,240
    Mentioned
    36 Post(s)
    Quoted
    496 Post(s)

    Default

    Quote Originally Posted by lancerawks View Post
    yeah, i was trying that before, but with goblins there HP changes, sometimes 5 sometiems 15 sometimes 20, so it screws up the exp = dammage * 4 thing. but for now just checking the xp before and after the scripts done is fine for me lol
    Quote Originally Posted by Da 0wner View Post
    No what Floris said will work. Count what you hit until they are dead and then multiply total by four.
    all you need to do is when u "move" ur mouse over them to click check the uptext for there lvl, there hp will be static to there level.
    so all you do is.
    if they lvl is w/e, go to runehq and find the 3 hp's for each goblin.
    then set the hitpoints to x:

    4*x = exp


  9. #9
    Join Date
    Jan 2008
    Location
    California, US
    Posts
    2,765
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    SCAR Code:
    function GetGoblinXP(Level : integer) : integer;
    begin
      case level of
        5 : result := 48;
        25 : result := 104;
        2 : result := 20;
        16 : result := 88;
        13 : result := 64;
        11 : result := 28;
      else
        SRL_Warn('GetGoblinXP', 'Invalid goblin level: ' + IntToStr(Level) + '.', warn_AllVersions);
      end;
    end;

    function GetLevel : integer;
    begin
      result := StrToInt(Between('-', ')', GetUpText));
      if result = 0 then
      begin
        SRL_Warn('GetLevel', 'Could not get level.', warn_AllVersions);
        result := -1;
      end;
    end;

    Use those like:
    SCAR Code:
    IncEx(Players[CurrentPlayer].Integers[0]{XP GAINED?}, GetGoblinXP(GetLevel));
    Last edited by Da 0wner; 06-05-2009 at 10:15 AM.

  10. #10
    Join Date
    Dec 2006
    Location
    Canada, BC
    Posts
    728
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    oh snap, thanks very helpful
    Lance. Da. Pants.

  11. #11
    Join Date
    Dec 2008
    Posts
    2,813
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Monsters regain health during combat.

    (So I'm saying you have to count hits then multiply by 4, or just ending experience minus beginning experience ).
    Last edited by ian.; 06-05-2009 at 07:19 PM.

  12. #12
    Join Date
    Feb 2007
    Location
    South East England
    Posts
    2,906
    Mentioned
    2 Post(s)
    Quoted
    8 Post(s)

    Default

    Quote Originally Posted by 99_ View Post
    Monsters regain health during combat.
    Depends how quick you kill them.
    Jus' Lurkin'

  13. #13
    Join Date
    Dec 2008
    Posts
    2,813
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by Torrent of Flame View Post
    Depends how quick you kill them.
    It seems to be almost random, actually. I've hit a one on a newly spawned chicken, then a three. So it really isn't a perfect science for how fast they regain health.

  14. #14
    Join Date
    Feb 2007
    Location
    South East England
    Posts
    2,906
    Mentioned
    2 Post(s)
    Quoted
    8 Post(s)

    Default

    Quote Originally Posted by 99_ View Post
    It seems to be almost random, actually. I've hit a one on a newly spawned chicken, then a three. So it really isn't a perfect science for how fast they regain health.
    Fairs.
    Jus' Lurkin'

  15. #15
    Join Date
    Feb 2007
    Location
    PA, USA
    Posts
    5,240
    Mentioned
    36 Post(s)
    Quoted
    496 Post(s)

    Default

    can't reflection be used to "check" ur exp without going into ur skills tab?

  16. #16
    Join Date
    Dec 2008
    Posts
    2,813
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by footballjds View Post
    can't reflection be used to "check" ur exp without going into ur skills tab?
    Yes, I believe so. And lance, you might want to check something that Shady? made. It was a damage detector, as your experience goes up before you hit, you can know slightly before. I bet you can get some good ideas using that. ^^ Good luck.

  17. #17
    Join Date
    Dec 2006
    Location
    Canada, BC
    Posts
    728
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    lol ok, ill check it out. i wasnt expecting so much help lol, maby just a function not a page of advice XD
    Lance. Da. Pants.

  18. #18
    Join Date
    Aug 2007
    Location
    in a random little world
    Posts
    5,778
    Mentioned
    0 Post(s)
    Quoted
    7 Post(s)

  19. #19
    Join Date
    Dec 2006
    Location
    Canada, BC
    Posts
    728
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    sick, thanks man, this is gonna make life very easy for me

    Edit: umm how exactly do you use this function? Ive never used reflection before btw
    SmartGetFieldArrayInt(0, Experiences, {skill number})
    whats Experiances and Skill number?

    and im guessing the function returns the Exp so i can do something like
    SCAR Code:
    OrigionalExp := SmartGetFieldArrayInt(0, Experiences, {skill number})
    Last edited by Lance; 06-06-2009 at 08:10 AM.
    Lance. Da. Pants.

  20. #20
    Join Date
    Aug 2007
    Location
    in a random little world
    Posts
    5,778
    Mentioned
    0 Post(s)
    Quoted
    7 Post(s)

    Default

    skill numbers
    SCAR Code:
    {*******************************************************************************
     Index     Skill              Index      Skill
       0    -    Attack             12    -    Crafting
       1    -    Defence            13    -    Smithing
       2    -    Strength           14    -    Mining
       3    -    Hitpoints          15    -    Herblore
       4    -    Range              16    -    Agility
       5    -    Prayer             17    -    Theiving
       6    -    Magic              18    -    Slayer
       7    -    Cooking            19    -    Farming
       8    -    Woodcutting        20    -    Runecrafting
       9    -    Fletching          21    -    Hunter
       10   -    Fishing            22    -    Construction
       11   -    Firemaking         23    -    Summoning
    *******************************************************************************}
    and leave experiences

    ~shut

  21. #21
    Join Date
    Dec 2006
    Location
    Canada, BC
    Posts
    728
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    ok, thanks :]
    Lance. Da. Pants.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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