So for my game I'd much rather have ranks rather than typical levels. Is there anyway to change the usual Level 50 into Rank A?
Changing Level Numbers Into Rank Letters
RPG Maker MV SupportDepends on what exactly you want. Do you want to still keep the numerical level in the background, but only show the player his rank based on level range? For example:
- A: 50-90
- B: 40-49
- C: 30-39
- D: 20-29
- E: 10-19
- F: 1-9
If so, it is not so hard if you mess around in the game code (would be easy to do).
- A: 50-90
- B: 40-49
- C: 30-39
- D: 20-29
- E: 10-19
- F: 1-9
If so, it is not so hard if you mess around in the game code (would be easy to do).
Just pure ranks. I figure I'd set a certain amount of Exp needed to gain ranks.
@PixelGamerDev My suggestion would be:
1) Use the default level system.
2) Make the max level the number of available ranks in your game.
3) Modify the base code to make it so that instead of displaying the actor's level, it displays the equivalent in terms of a rank. (Easy and quick to do).
So an example would be:
- Level 1: Rank F
- Level 2: Rank E
- Level 3: Rank D
- etc.
Of course the player will never see the number and will always see the rank. The principle behind this system is still the same as traditional levels though.
1) Use the default level system.
2) Make the max level the number of available ranks in your game.
3) Modify the base code to make it so that instead of displaying the actor's level, it displays the equivalent in terms of a rank. (Easy and quick to do).
So an example would be:
- Level 1: Rank F
- Level 2: Rank E
- Level 3: Rank D
- etc.
Of course the player will never see the number and will always see the rank. The principle behind this system is still the same as traditional levels though.
So I've done this much already, prior to. But My issue lies within the coding trying to find how to substitute the numerical values for letters. Any idea where I search to change that? I've been looking through the main plugins all over.
You don't need to change the core functionality. You just need to change the text display. Here's how you can do it:
1) There's a function in the Window_Base object that is called to draw level: Window_Base.prototype.drawActorLevel
2) Modify it.
OR you can copy/paste this code in a new plugin and simply install it (note I coded it quickly and didn't test it):
1) There's a function in the Window_Base object that is called to draw level: Window_Base.prototype.drawActorLevel
2) Modify it.
OR you can copy/paste this code in a new plugin and simply install it (note I coded it quickly and didn't test it):
Code:
Window_Base.prototype.drawActorLevel = function(actor, x, y) {
this.changeTextColor(this.systemColor());
this.drawText(TextManager.levelA, x, y, 48);
this.resetTextColor();
this.drawText(this.getActorRank(actor.level), x + 84, y, 36, 'right');
};
Window_Base.prototype.getActorRank = function(lv) {
var rank = "";
switch (lv) {
// This is where you need to assign to rank text for each level.
// Use this format: case x: rank = "rank text in here"; break;
// x is the level.
case 1: rank = "Rank F"; break;
case 2: rank = "Rank E"; break;
case 3: rank = "Rank D"; break;
case 4: rank = "Rank C"; break;
case 5: rank = "Rank B"; break;
case 6: rank = "Rank A"; break;
case 7: rank = "Rank S"; break;
default: rank = "No Rank"; break;
}; return rank;
};
Original thread: https://forums.rpgmakerweb.com/threads/changing-level-numbers-into-rank-letters.103468/