Results 1 to 7 of 7
  1. #1
    BlackRayquaza's Avatar
    Join Date
    Nov 2012
    Gender
    male
    Posts
    574
    Reputation
    10
    Thanks
    186
    My Mood
    In Love

    [Tutorial] Custom HP and MP regeneration

    Click here for the ****** commit and source code

    Explanation:

    Code:
    return 2 + 0.17333333333333333333333333333333f * vitality;
    /* (Maxregen - Minregen) / Maxvit = x
    * Minregen + x * vit
    * 
    * (15 - 2) / 75 = 0.17333333333333333333333333333333
    * 2 + 0.17333333333333333333333333333333 * vit
    */

    (Maxregen - Minregen) / Maxvit = x
    (15 - 2) / 75 = 0.17333333333333333333333333333333

    Maxregen is the amount at regen at 75 and Minregen is the amount of regen at 0 vit.
    75 is the max vit.



    Minregen + x * vit
    2 + 0.17333333333333333333333333333333 * vit

    Minregen is the same as the minregen from the explanation above and x is the number you get from (Maxregen - Minregen) / Maxvit.

    More info about the calculations.
    Last edited by BlackRayquaza; 03-31-2015 at 10:38 AM.
    YEP cock

  2. The Following 2 Users Say Thank You to BlackRayquaza For This Useful Post:

    cxydsaewq (04-02-2015),Goodfeet (03-31-2015)

  3. #2
    BARm's Avatar
    Join Date
    Sep 2012
    Gender
    male
    Location
    Tel Aviv
    Posts
    406
    Reputation
    32
    Thanks
    1,007
    My Mood
    Inspired
    Useless for the community, most people probably don't even understand what you wrote there..

    But thanks for sharing anyways.

  4. #3
    Ahl's Avatar
    Join Date
    Dec 2012
    Gender
    male
    Location
    /modcp
    Posts
    16,599
    Reputation
    3219
    Thanks
    5,383
    My Mood
    Angelic
    Quote Originally Posted by BARm View Post
    Useless for the community, most people probably don't even understand what you wrote there..

    But thanks for sharing anyways.
    I understood

    All just maths work to just finalise the speed of hp/mp regen.
    News Force Head Editor from 09/14/2018 - 03/02/2020
    Publicist from 11/23/2017 - 06/07/2019
    Global Moderator since 09/24/2017
    Minion+ from 04/16/2017 - 09/24/2017
    Market Place Minion from 04/16/2017 - 09/24/2017
    Minecraft Minion from 02/23/2017 - 09/24/2017
    Realm of the Mad God Minion from 11/06/2016 - 09/24/2017

    Middleman from 09/14/2016 - 09/24/2017
    News Force Editor from 08/23/2016 - 09/14/2018
    News Force (Section of the Week) from 03/21/2016 - 07/17/2017
    News Force (User News) from 10/18/2015 - 09/14/2018

    Donator since 03/16/2015
    Realm of the Mad God Editor from 05/20/2014 - 07/08/2014
    Member since 12/23/2012


    Rep Power: 82

  5. #4
    BARm's Avatar
    Join Date
    Sep 2012
    Gender
    male
    Location
    Tel Aviv
    Posts
    406
    Reputation
    32
    Thanks
    1,007
    My Mood
    Inspired
    Quote Originally Posted by Dave's Cameltoe's Goat View Post
    I understood

    All just maths work to just finalise the speed of hp/mp regen.
    I did say: "most" :P

  6. #5
    BlackRayquaza's Avatar
    Join Date
    Nov 2012
    Gender
    male
    Posts
    574
    Reputation
    10
    Thanks
    186
    My Mood
    In Love
    Quote Originally Posted by BARm View Post
    Useless for the community, most people probably don't even understand what you wrote there..

    But thanks for sharing anyways.
    Its really hard to explain, but its really easy todo
    YEP cock

  7. The Following User Says Thank You to BlackRayquaza For This Useful Post:

    BARm (04-05-2015)

  8. #6
    Stellar Spark's Avatar
    Join Date
    Jun 2013
    Gender
    female
    Posts
    724
    Reputation
    35
    Thanks
    799
    Simple explanation:

    If you want to increase regen rate, make the float (.17333...) a tad bit bigger. If you want to decrease regen rate, make the float a tad bit smaller. I could explain the entire thing if I wanted to, seeing how I love to expand on things, but this short explanation covers it. xD

  9. #7
    BlackRayquaza's Avatar
    Join Date
    Nov 2012
    Gender
    male
    Posts
    574
    Reputation
    10
    Thanks
    186
    My Mood
    In Love
    The source code is now located at here, line 92-120
    YEP cock

Similar Threads

  1. [Tutorial] Font Tags and the basics.
    By Spookerzz in forum Web Languages
    Replies: 11
    Last Post: 10-10-2011, 12:35 AM
  2. [Tutorial] Custom Background Music in 10 Easy steps
    By ZeroTroubles in forum Call of Duty Modern Warfare 2 Tutorials
    Replies: 50
    Last Post: 08-29-2010, 07:54 AM
  3. Custom Mod and Custom Map??
    By Slayer418 in forum Call of Duty Modern Warfare Help
    Replies: 3
    Last Post: 04-27-2010, 12:15 AM
  4. Replies: 33
    Last Post: 07-28-2009, 04:38 AM
  5. [Tutorial] CE's and Address's - hao do i mayke h4ck?
    By Iwin in forum Combat Arms Hacks & Cheats
    Replies: 29
    Last Post: 09-22-2008, 05:27 PM