Search Unity

Leveling. Experience. Enemy dificulty curve.

Discussion in 'Game Design' started by Daahrien, Apr 10, 2020.

  1. Daahrien

    Daahrien

    Joined:
    Dec 5, 2016
    Posts:
    100
    Any good "standard" curve to follow about leveling? Experience needed for next level, etc.

    Also, the enemy dificulty, I guess add more HP, more damage, and more given exp when killed. But what would be a pleasant/engaging curve for it?

    I know the first levels should be easy and fast, and then gradually go harder and harder.

    My game is a dungeon crawler, you can find and equip armor and weapons, that would be an important variable in defining the enemy strength besides player level.
     
  2. Murgilod

    Murgilod

    Joined:
    Nov 12, 2013
    Posts:
    10,160
    An exponential curve that you can tweak to adjust the values of is a good start, followed by playtesting and internal adjustments. There's no single right answer for this, you've got to experiment.
     
    JoeStrout likes this.
  3. BIGTIMEMASTER

    BIGTIMEMASTER

    Joined:
    Jun 1, 2017
    Posts:
    5,181
    Limited experience here, but what I've found so far is:

    1. Identify the variables which influence difficulty
    2. make the game fun for you to play
    3. assume first timers will have a terrible time to do as well as you do. For you to get through the game with moderate difficulty, this is like "hardcore death mode". Make adjustments from that
    4. thats starting point, got to playtest from there
     
  4. Not_Sure

    Not_Sure

    Joined:
    Dec 13, 2011
    Posts:
    3,546
    It always depends on the experience, but I will say that added damage and added life is artificial and makes the difficulty artificial.

    A better method is to:

    1) Increase the orthogonal spectrum. That is, make player tools and enemies situational and increase the amount of tools and enemies giving the player more and more to juggle. Also, just throwing everything at the player is poor design. Keep a solid number in mind of enemy types at a given time. Maybe start with 2 (melee and ranged). Then add another (melee, ranged, and a healer). Then another (melee, ranged, healer, and one that does stick and move tactics). And so on. Swap them in and out, but stay consistent with the number of different types and ramp it up with the curve.

    2) Decrease the player’s time to react. Make enemies attack more frequently. Decrease the shock state of enemies and have them attack the player sooner after they see the player.

    3) Increase the amount of things to deal with. More enemies. More shots fired. Special abilities cool down faster.
     
    Red-Owl-Games and Socrates like this.
  5. Joe-Censored

    Joe-Censored

    Joined:
    Mar 26, 2013
    Posts:
    11,847
    I'd suggest not to steadily increase the difficulty like a straight line. Increase difficulty to a new peak, then tone it back down. Increase to an even higher peak then tone it back down again. Give the player a breather between increased difficulty peaks.
     
    ClaudiaTheDev and Not_Sure like this.
  6. Not_Sure

    Not_Sure

    Joined:
    Dec 13, 2011
    Posts:
    3,546
    Yup!

    Make it a progressing saw tooth.

    123 New Skill
    234 New Skill
    345 New Skill
    456 New Skill
    567 New Skill
    678 New Skill

    And by "skill" I mean and expectation of the player, not an in game ability.

    So if this was Mario:

    Small Mario:
    -Open area to move around in
    -Blocks to jump on
    -Goomba to Avoid

    Large Mario:
    -Break Blocks
    -More Goombas
    -Pit to Jump over

    Fire Flower:
    -Mulitple Goombas
    -Another Pit
    -A Koopa Trooper

    Racoon Suit:
    -Pit to Jump over
    -Multiple Koopa Troopers
    -Winged Koopa Trooper
     
  7. Serinx

    Serinx

    Joined:
    Mar 31, 2014
    Posts:
    788
    The increasing difficulty shouldn't ever just be increasing hp and damage of the enemies.
    Players love to learn, learning that this new enemy has double the health of the old one isn't very fun, but learning that this enemy does a devastating slam after that mysterious animation is fun.
    Most players will get hit the first few times but then they learn to anticipate it.
    More HP/damage is ok to add as long as it's not the only thing you're changing.
    It's great for players to learn how to attack and pitting them against puny enemies with 1hp, but the next enemy should be able to take a hit and then attack back - now the player needs to learn to dodge or block.
    If you make all of the mechanics fairly easy to learn, you'll end up with a natural difficulty curve as the player will need to remember the relevant mechanics based on the situation.

    So basically, introduce a new mechanic every so often, could be every level or every 20 minutes, whatever suits your game. This will give the player time to learn the mechanic, apply it, and then have a break until the next lot of learning.
     
  8. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I group my enemies based on their difficulty level, then enable all objects for the difficulty I'm on or below. That way if I'm playing on hard mode, the easy, normal, and hard enemies will spawn, but the super hard ones will not. I hate when games change difficulty but just changing stats, I like how in Halo for example in lower difficulties you may be fighting two blue elites, but in higher ones one might change to a red one.

    I also have this class, where all systems affected by difficulty
    Screen Shot 2020-04-24 at 12.44.45 PM.png
    For example, when a character is shooting, it points it's gun directly at the enemy (plus some lead) then offsets it by a float that's part of their class, multiplied by Difficulty.getScalar_GunAccuracy():

    Code (CSharp):
    1. public static float getScalar_GunAccuracy(GameObject obj){  //Higher result means more likely to miss
    2.         if (obj.layer == Consts.Layer_Cats){
    3.             switch(SessionManager.mode){
    4.                 case Consts.Mode.Campaign_Easy:
    5.                     return 0.1f;
    6.                 case Consts.Mode.Campaign_Normal:
    7.                     return 0.75f;
    8.                 case Consts.Mode.Campaign_Hard:
    9.                     return 1.0f;
    10.                 case Consts.Mode.Campaign_Hardest:
    11.                     return 1.5f;
    12.             }
    13.         } else {
    14.             switch(SessionManager.mode){
    15.                 case Consts.Mode.Campaign_Easy:
    16.                     return 2.05f - 0.05f * KeyboardOrNetworkController.playerFCount();
    17.                 case Consts.Mode.Campaign_Normal:
    18.                     return 1.3f - 0.05f * KeyboardOrNetworkController.playerFCount();
    19.                 case Consts.Mode.Campaign_Hard:
    20.                     return 0.8f - 0.05f * KeyboardOrNetworkController.playerFCount();
    21.                 case Consts.Mode.Campaign_Hardest:
    22.                     return 0.26f - 0.01f * KeyboardOrNetworkController.playerFCount();
    23.             }
    24.         }
    25.         Debug.Assert(false);
    26.         return 1.0f;
    27.     }
    It determines if the character is friend or foe based on the layer, then returns hardcoded values for each difficulty level. So a friendly (cat) gun on easy will almost never miss, but the same gun on higher difficulty has a greater spread. Contrarily, an enemy gun on easy will miss a lot, but on the hardest, they are deadly accurate. Notice that the accuracy of the enemies also depends very slightly on the number of players, so that in co-op the difficulty is raised proportionally to the number of players (up to 4.)