mirror of
https://github.com/KAMKEEL/CustomNPC-Plus-API.git
synced 2026-11-15 23:04:44 +00:00
Abilities are now Stored by Name not UUID. Refactor Built In and Toggleable Abilities
This commit is contained in:
1 parent
22bce4b2ac
commit
010849fe8f
1 file changed
+14
-3
@@ -9,7 +9,8 @@ import noppes.npcs.api.INbt;
|
||||
public interface IAbility {
|
||||
|
||||
/**
|
||||
* Get the unique ID of this ability instance.
|
||||
* Get the unique ID (UUID for custom abilities, registry key for built-in).
|
||||
* This is the stable reference that never changes after creation.
|
||||
*/
|
||||
String getId();
|
||||
|
||||
@@ -19,15 +20,25 @@ public interface IAbility {
|
||||
void setId(String id);
|
||||
|
||||
/**
|
||||
* Get the display name of this ability.
|
||||
* Get the unique identifier/name of this ability (used for file naming, commands, search).
|
||||
*/
|
||||
String getName();
|
||||
|
||||
/**
|
||||
* Set the display name of this ability.
|
||||
* Set the unique identifier/name of this ability.
|
||||
*/
|
||||
void setName(String name);
|
||||
|
||||
/**
|
||||
* Get the display name (cosmetic). Falls back to getName() if not set.
|
||||
*/
|
||||
String getDisplayName();
|
||||
|
||||
/**
|
||||
* Set the display name (cosmetic). Pass empty string to use getName() as display.
|
||||
*/
|
||||
void setDisplayName(String displayName);
|
||||
|
||||
/**
|
||||
* Get the type ID of this ability (e.g., "cnpc:slam", "cnpc:beam").
|
||||
*/
|
||||
|
||||
Reference in new issue
Block a user