ScriptableEntity

public abstract class ScriptableEntity

Base class for anything that can be scripted with Lua. Plugins extend this for their specific entity types.

Constructors

Link copied to clipboard
public void ScriptableEntity()

Functions

Link copied to clipboard
public abstract LuaTable buildContextTable(ScriptInstance instance)
Build the primary context table entry for this entity.
Link copied to clipboard
public abstract Entity getBukkitEntity()
The underlying Bukkit entity, if any.
Link copied to clipboard
public abstract String getContextKey()
The key name used in the Lua context table (e.g., "boss", "prop").
Link copied to clipboard
public Map<String, Long> getGlobalCooldownStore()
Returns the shared cooldown store for global cooldowns.
Link copied to clipboard
public Map<String, Long> getLocalCooldownStore(ScriptDefinition definition)
Returns the local cooldown store for a given script definition.
Link copied to clipboard
public abstract Location getLocation()
Current location for zone calculations.
Link copied to clipboard
public abstract Set<ScriptHook> getSupportedHooks()
Returns all hooks this entity type supports.
Link copied to clipboard
public boolean handleScriptError(String context, Exception failure)
Return true when the host owns error reporting, for example revision-scoped suppression.
Link copied to clipboard
public boolean isScriptOwnerActive()
Whether the scripted owner should keep its runtime alive.
Link copied to clipboard
public void onShutdown()
Called when ScriptInstance is shut down.
Link copied to clipboard
public LuaValue resolveExtraContext(String key, ScriptInstance instance)
Resolve additional context values beyond standard ones.