Get DisplayName from player class

So, using the player_manager library, I’ve made a couple of classes for players. Each class has a display name and other variables setup in the table that gets passed to player_manager.RegisterClass. The only thing I have found that looks into that table is in lua/includes/modules/player_manager.lua and the LookupPlayerClass function, which of course is local.

Is there any way to get to that information?

(I know about the util.NetworkIDToString(Player:GetClassID()) deal, but that’s not the actual display name, just the class ID)

I can’t see any way of getting that information, as you say it’s all local.
A possible workaround for any classes you are adding yourself would be to add your own method that returns self.DisplayName, then you could call it using player_manager.RunClass(ply,‘GetDisplayName’). Drawbacks include needing a player argument, you can’t just run it on a class by name.

I forgot about using RunClass. I will give that a shot and come back with the results.

[editline]13th January 2014[/editline]

That works perfectly. Thanks!

How about getting variables from classes that aren’t in use by the player? (Meaning there is no player object I can pass to player_manager.RunClass)