Trilobytes MZ #4: Prestige Class Titles

Prestige Class Titles v1.02
Trilobytes by Trihan
​

Introduction
This plugin provides the developer the facility to have actor classes automatically change their names as the actor possessing that class hits defined level milestones.

Features
- Set up a list of level points where a class will change its displayed name
- Provide evaluated code blocks to determine class names programmatically

Screenshots
1678883769849.png
1678883843488.png
1678883879482.png


How to Use
Download the plugin's .js file to your project's js/plugins folder and save it as TLB_PrestigeClassTitles.js. Open your plugin manager (
1678883947273.png
or F10), double click an empty slot, select TLB_PrestigeClassTitles from the list and click OK on both dialog boxes to confirm installing the plugin.

With the plugin installed, you can use the notetag

Code:
<NameList>
  level1:name1
  level2:name2
  level3:name3
</NameList>

in any class's notebox.

For users with more Javascript knowledge, a <NameListCustom> tag is provided. Place valid Javascript code inside the tag and it will be used to determine the class name. You can use 'a' for the actor. The final result should be stored in the variable 'text'. For example:

JavaScript:
<NameList Custom>
  if (a.skills().contains($dataSkills[10])) {
    text = 'Prestige Class C';
  } else if (a.equips()[0].id == 30 && a.skills().contains($dataSkills[18]) && a.level >= 10) {
    text = 'Prestige Class B3';
  } else if (a.equips()[0].id == 30) {
    text = 'Prestige Class B2';
  } else if (a.skills().contains($dataSkills[18])) {
    text = 'Prestige Class B1';
  } else if (a.skills().contains($dataSkills[17])) {
    text = 'Prestige Class A';
  } else {
    text = 'Fallback';
  }
</NameList Custom>

If the actor has skill 10, their class will be called "Prestige Class C". Otherwise, if they have weapon 30 equipped, skill 18, and a level greater then or equal to 10, it will be "Prestige Class B3". And so on.

Plugin Commands / Script Calls
This plugin has no commands or script calls.

Demo
N/A

Download
This plugin is available from itch.io

Terms and Credits
You may use this plugin for commercial or non-commercial games. Please credit Trilobytes or Trihan.

Special Thanks
@Puppet Knight for the original plugin request
Mánibranðr System for the plugin name suggestion
Glad to be of help with the naming.
I do know it wont work for MV because of the ?? operator, otherwise, some MV
users can make use of it 🙂

but I love the idea, specially if you have multiple actors, as "swordsman".
I dont know if it has each class progress of the actor itself it not reach
that level yet, but keep up the awesome work 🙂.
I've been testing this our in my project, and it works like a charm.
Thank you.
MZ version is updated to 1.01! It's now compatible with VisuStella's Class Change System and will show prestige titles for subclasses.
Super thanking you again for building this one out!!! Such a needed plugin that I know a lot of folks are going to benefit from!
@Trihan

I was wondering if its possible to add these notetags into skills as well. For a multilateral skill system, it would be nice to define the actors classes based on their skill choices.
@Trihan

I was wondering if its possible to add these notetags into skills as well. For a multilateral skill system, it would be nice to define the actors classes based on their skill choices.
What are you using for assigning skills to actors via player choice?
@Trihan
I am using a skill tree system. Essentially thinking that it would be great to assign a class name that differs depending on the choices players make on the skill tree . It was just a thought and could be useful for others wanting to do similar things.
@Trihan
I am using a skill tree system. Essentially thinking that it would be great to assign a class name that differs depending on the choices players make on the skill tree . It was just a thought and could be useful for others wanting to do similar things.
How would I integrate that generically, though? RPG Maker doesn't support skill tree systems by default, and modifying it specifically for your needs sounds more like a commission than an update.
@Trihan
I am not sure, I am not a coder. Basically a script which changes class name of the specific actor when they use a particular skill. But it sounds like it may be difficult to do from your response - so no drama.
@Trihan
I am not sure, I am not a coder. Basically a script which changes class name of the specific actor when they use a particular skill. But it sounds like it may be difficult to do from your response - so no drama.
Oh, if you just want it to change when they *use* a particular skill that's more than doable. It sounded like what you were asking for was a way to change class based on which skills the player had chosen for the actor to have access to.
@Trihan
You are right, that would require some sort of integration of plugins which would be a custom thing I imagine. Anyway it was just an idea, thanks for your time =)
@Trihan
You are right, that would require some sort of integration of plugins which would be a custom thing I imagine. Anyway it was just an idea, thanks for your time =)
Can you give me a worked example of how what you're requesting would work?
Hey hey,

Is there a way to have the Prestige Title pulled when drawing the name?

For example:

// Draw Armoire Rank // this.contents.fontSize = 30; const subClass = actor.multiclassId(2) const subClassLvl = actor.classLevel(subClass) // if check for Unranked Class is equipped at all before running this section if (subClass != 9){ const subClassName = actor.multiclass(2).name; const subClassWidth = this.textWidth(subClassName) + 8; const subClassHeight = this.contents.fontSize const nextsubLevel = subClassLvl + 1 this.drawTextEx(subClassName, ax, ay + 2, subClassWidth); this.resetFontSettings(); this.contents.fontSize = 24; this.drawText("Lv" + " " + subClassLvl, ax + subClassWidth - 64, ay + 4) this.resetFontSettings();

is used with the following note tag for a class

<NameList> 1:Novice 10:Adept 25:Scholar 50:Maester </NameList>


But the database Class name is what gets drawn still.
Micro bump here. To further explain my use case: I'm drawing class names and levels in the scene for Moogle Xs Equip Skill plugin:


1689260584730.png



Currently the main class "Academy" has the note tag:
<NameList> 1:Novice 10:Adept 25:Scholar 50:Maester </NameList>

So it should be showing "Novice" instead of Academy. But its using the default name.

I'm tried even using const primClass = actor.currentClass().tlbClassNames; when drawing the class name instead but it results in :

1689260938537.png


The plugin was updating in the Class Change Systems scene fine, so I'm assuming I might need a way to properly reference the name directly and/or have an addition function thats hooked into `Window_Base` instead maybe?


Thoughts?
So... would it be possible for the player to be able to choose the names of the class in-game? I am making a sort of make-your-own-class class.
So... would it be possible for the player to be able to choose the names of the class in-game? I am making a sort of make-your-own-class class.
Not as released but if you change "drawText" on line 122 of the plugin code to "drawTextEx", you can use \v[x] in your notetag and it'll display the value of variable x, so you could store your custom class names in the variables you use.
Not as released but if you change "drawText" on line 122 of the plugin code to "drawTextEx", you can use \v[x] in your notetag and it'll display the value of variable x, so you could store your custom class names in the variables you use.
This may be a dumb question.... but so you can store letters in variables? I thought variables were numbers only.
This may be a dumb question.... but so you can store letters in variables? I thought variables were numbers only.
You can store practically anything mate

Original thread: https://forums.rpgmakerweb.com/threads/trilobytes-mz-4-prestige-class-titles.155836/