mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-22 01:32:19 +00:00
Implemented global Forge events. Reorganized NPC API files.
This commit is contained in:
1 parent
c5ed7497c8
commit
72f2c3c60a
72 files changed
+321
-395
No files matched your search
@@ -0,0 +1,11 @@
|
||||
//
|
||||
// Source code recreated from a .class file by IntelliJ IDEA
|
||||
// (powered by Fernflower decompiler)
|
||||
//
|
||||
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.entity.passive.EntityAnimal;
|
||||
|
||||
public interface IAnimal<T extends EntityAnimal> extends IEntityLiving<T> {
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
//
|
||||
// Source code recreated from a .class file by IntelliJ IDEA
|
||||
// (powered by Fernflower decompiler)
|
||||
//
|
||||
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
|
||||
public interface IBlock {
|
||||
int getX();
|
||||
|
||||
int getY();
|
||||
|
||||
int getZ();
|
||||
|
||||
IPos getPos();
|
||||
|
||||
String getName();
|
||||
|
||||
void remove();
|
||||
|
||||
boolean isAir();
|
||||
|
||||
IBlock setBlock(String var1);
|
||||
|
||||
IBlock setBlock(IBlock var1);
|
||||
|
||||
boolean isContainer();
|
||||
|
||||
IContainer getContainer();
|
||||
|
||||
IWorld getWorld();
|
||||
|
||||
TileEntity getMCTileEntity();
|
||||
|
||||
Block getMCBlock();
|
||||
|
||||
String getDisplayName();
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
//
|
||||
// Source code recreated from a .class file by IntelliJ IDEA
|
||||
// (powered by FernFlower decompiler)
|
||||
//
|
||||
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.inventory.Container;
|
||||
import net.minecraft.inventory.IInventory;
|
||||
|
||||
public interface IContainer {
|
||||
int getSize();
|
||||
|
||||
IItemStack getSlot(int var1);
|
||||
|
||||
void setSlot(int slot, IItemStack item);
|
||||
|
||||
IInventory getMCInventory();
|
||||
|
||||
Container getMCContainer();
|
||||
|
||||
int count(IItemStack var1, boolean var2, boolean var3);
|
||||
|
||||
IItemStack[] getItems();
|
||||
}
|
||||
@@ -0,0 +1,387 @@
|
||||
//
|
||||
// Source code recreated from a .class file by IntelliJ IDEA
|
||||
// (powered by FernFlower decompiler)
|
||||
//
|
||||
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.entity.EntityCreature;
|
||||
import noppes.npcs.scripted.ScriptFaction;
|
||||
import noppes.npcs.scripted.ScriptItemStack;
|
||||
import noppes.npcs.scripted.entity.ScriptLivingBase;
|
||||
import noppes.npcs.scripted.entity.ScriptPlayer;
|
||||
import noppes.npcs.scripted.roles.*;
|
||||
|
||||
public interface ICustomNpc<T extends EntityCreature> extends IEntityLiving<T> {
|
||||
/**
|
||||
* @return Returns the current npcs size 1-30
|
||||
*/
|
||||
public int getSize();
|
||||
|
||||
/**
|
||||
* @param size The size of the npc (1-30) default is 5
|
||||
*/
|
||||
public void setSize(int size);
|
||||
|
||||
/**
|
||||
* @return Returns the current npcs modelType of the NPC
|
||||
*/
|
||||
public int getModelType();
|
||||
|
||||
/**
|
||||
* @param modelType The modelType of the NPC. 0: Steve, 1: Steve64, 2: Alex
|
||||
*/
|
||||
public void setModelType(int modelType);
|
||||
|
||||
/**
|
||||
* @return The npcs name
|
||||
*/
|
||||
public String getName();
|
||||
|
||||
public void setRotation(float rotation);
|
||||
/**
|
||||
* @param name The name of the npc
|
||||
*/
|
||||
public void setName(String name);
|
||||
|
||||
/**
|
||||
* @since 1.7.10
|
||||
* @return The npcs title
|
||||
*/
|
||||
public String getTitle();
|
||||
|
||||
/**
|
||||
* @since 1.7.10
|
||||
* @param title The title of the npc
|
||||
*/
|
||||
public void setTitle(String title);
|
||||
|
||||
/**
|
||||
* @return The npcs texture
|
||||
*/
|
||||
public String getTexture();
|
||||
|
||||
/**
|
||||
* @param texture The texture of the npc
|
||||
*/
|
||||
public void setTexture(String texture);
|
||||
|
||||
/**
|
||||
* @return Home position x
|
||||
*/
|
||||
public int getHomeX();
|
||||
|
||||
/**
|
||||
* @param x The home x position
|
||||
*/
|
||||
public void setHomeX(int x);
|
||||
|
||||
/**
|
||||
* @return Home position x
|
||||
*/
|
||||
public int getHomeY();
|
||||
|
||||
/**
|
||||
* @param y The home y position
|
||||
*/
|
||||
public void setHomeY(int y);
|
||||
|
||||
/**
|
||||
* @return Home position x
|
||||
*/
|
||||
public int getHomeZ();
|
||||
|
||||
/**
|
||||
* @param z The home x position
|
||||
*/
|
||||
public void setHomeZ(int z);
|
||||
|
||||
/**
|
||||
* @param x The home x position
|
||||
* @param y The home y position
|
||||
* @param z The home z position
|
||||
*/
|
||||
public void setHome(int x, int y, int z);
|
||||
/**
|
||||
* @param health New max health
|
||||
*/
|
||||
public void setMaxHealth(int health);
|
||||
|
||||
/**
|
||||
* @param bo Whether or not the npc will try to return to his home position
|
||||
*/
|
||||
public void setReturnToHome(boolean bo);
|
||||
|
||||
/**
|
||||
* @return Whether or not the npc returns home
|
||||
*/
|
||||
public boolean getReturnToHome();
|
||||
|
||||
/**
|
||||
* @return The faction of the npc
|
||||
*/
|
||||
public ScriptFaction getFaction();
|
||||
|
||||
/**
|
||||
* @param id The id of the new faction
|
||||
*/
|
||||
public void setFaction(int id);
|
||||
|
||||
public int getType();
|
||||
|
||||
public boolean typeOf(int type);
|
||||
|
||||
/**
|
||||
* @param target The targeted npc
|
||||
* @param item The item you want to shoot
|
||||
* @param accuracy Accuracy of the shot (0-100)
|
||||
*/
|
||||
public void shootItem(ScriptLivingBase target, ScriptItemStack item, int accuracy);
|
||||
|
||||
/**
|
||||
* @param message The message the npc will say
|
||||
*/
|
||||
public void say(String message);
|
||||
|
||||
/**
|
||||
* @param message The message the npc will say
|
||||
*/
|
||||
public void say(ScriptPlayer player, String message);
|
||||
|
||||
/**
|
||||
* Kill the npc, doesnt't despawn it
|
||||
*/
|
||||
public void kill();
|
||||
|
||||
/**
|
||||
* Basically completely resets the npc. This will also call the Init script
|
||||
*/
|
||||
public void reset();
|
||||
|
||||
/**
|
||||
* @return Returns the npcs current role
|
||||
*/
|
||||
public ScriptRoleInterface getRole();
|
||||
|
||||
/**
|
||||
* @return Returns the npcs current job
|
||||
*/
|
||||
public ScriptJobInterface getJob();
|
||||
|
||||
/**
|
||||
* @return The item held in the right hand
|
||||
*/
|
||||
public ScriptItemStack getRightItem();
|
||||
|
||||
/**
|
||||
* @param item Item to be held in the right hand
|
||||
*/
|
||||
public void setRightItem(ScriptItemStack item);
|
||||
|
||||
/**
|
||||
* @return The item held in the left hand
|
||||
*/
|
||||
public ScriptItemStack getLefttItem();
|
||||
|
||||
/**
|
||||
* @param item Item to be held in the left hand
|
||||
*/
|
||||
public void setLeftItem(ScriptItemStack item);
|
||||
|
||||
/**
|
||||
* @return Returns the projectile the npc uses
|
||||
*/
|
||||
public ScriptItemStack getProjectileItem();
|
||||
|
||||
/**
|
||||
* @param item Item to be used as projectile
|
||||
*/
|
||||
public void setProjectileItem(ScriptItemStack item);
|
||||
|
||||
/**
|
||||
* @param slot The armor slot to return. 0:head, 1:body, 2:legs, 3:boots
|
||||
* @return Returns the worn armor in slot
|
||||
*/
|
||||
public ScriptItemStack getArmor(int slot);
|
||||
|
||||
/**
|
||||
* @param slot The armor slot to set. 0:head, 1:body, 2:legs, 3:boots
|
||||
* @param item Item to be set as armor
|
||||
*/
|
||||
public void setArmor(int slot, ScriptItemStack item);
|
||||
|
||||
/**
|
||||
* @param type The AnimationType
|
||||
*/
|
||||
public void setAnimation(int type);
|
||||
|
||||
/**
|
||||
* @param type The visibility type of the npc, 0:visible, 1:invisible, 2:semi-visible
|
||||
*/
|
||||
public void setVisibleType(int type);
|
||||
|
||||
/**
|
||||
* @return The visibility type of the npc, 0:visible, 1:invisible, 2:semi-visible
|
||||
*/
|
||||
public int getVisibleType();
|
||||
|
||||
/**
|
||||
* @param type The visibility type of the name, 0:visible, 1:invisible, 2:when-attacking
|
||||
*/
|
||||
public void setShowName(int type);
|
||||
|
||||
/**
|
||||
* @return Returns the visibility type of the name, 0:visible, 1:invisible, 2:when-attacking
|
||||
*/
|
||||
public int getShowName();
|
||||
|
||||
/**
|
||||
* @return Returns the visiblity of the boss bar, 0:invisible, 1:visible, 2:when-attacking
|
||||
*/
|
||||
public int getShowBossBar();
|
||||
|
||||
/**
|
||||
* @param type The visibility type of the boss bar, 0:invisible, 1:visible, 2:when-attacking
|
||||
*/
|
||||
public void setShowBossBar(int type);
|
||||
|
||||
/**
|
||||
* @return The melee strength
|
||||
*/
|
||||
public int getMeleeStrength();
|
||||
|
||||
/**
|
||||
* @param strength The melee strength
|
||||
*/
|
||||
public void setMeleeStrength(int strength);
|
||||
|
||||
/**
|
||||
* @return The melee speed
|
||||
*/
|
||||
public int getMeleeSpeed();
|
||||
|
||||
/**
|
||||
* @param speed The melee speed
|
||||
*/
|
||||
public void setMeleeSpeed(int speed);
|
||||
|
||||
/**
|
||||
* @return The ranged strength
|
||||
*/
|
||||
public int getRangedStrength();
|
||||
|
||||
/**
|
||||
* @param strength The ranged strength
|
||||
*/
|
||||
public void setRangedStrength(int strength);
|
||||
|
||||
/**
|
||||
* @return The ranged speed
|
||||
*/
|
||||
public int getRangedSpeed();
|
||||
|
||||
/**
|
||||
* @param speed The ranged speed
|
||||
*/
|
||||
public void setRangedSpeed(int speed);
|
||||
|
||||
/**
|
||||
* @return The ranged burst count
|
||||
*/
|
||||
public int getRangedBurst();
|
||||
|
||||
/**
|
||||
* @param count The ranged burst count
|
||||
*/
|
||||
public void setRangedBurst(int count);
|
||||
|
||||
/**
|
||||
* @param player The player to give the item to
|
||||
* @param item The item given to the player
|
||||
*/
|
||||
public void giveItem(ScriptPlayer player, ScriptItemStack item);
|
||||
|
||||
|
||||
/**
|
||||
* On servers the enable-command-block option in the server.properties needs to be set to true
|
||||
* @param command The command to be executed
|
||||
*/
|
||||
public void executeCommand(String command);
|
||||
|
||||
public void setHeadScale(float x, float y, float z);
|
||||
|
||||
public void setBodyScale(float x, float y, float z);
|
||||
|
||||
public void setArmsScale(float x, float y, float z);
|
||||
|
||||
public void setLegsScale(float x, float y, float z);
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* @param resistance Explosion resistance (0-2) default is 1
|
||||
*/
|
||||
public void setExplosionResistance(float resistance);
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* @return Returns Explosion Resistance
|
||||
*/
|
||||
public float getExplosionResistance();
|
||||
|
||||
/**
|
||||
* @param resistance Melee resistance (0-2) default is 1
|
||||
*/
|
||||
public void setMeleeResistance(float resistance);
|
||||
|
||||
/**
|
||||
* @return Returns Melee Resistance
|
||||
*/
|
||||
public float getMeleeResistance();
|
||||
|
||||
/**
|
||||
* @param resistance Arrow resistance (0-2) default is 1
|
||||
*/
|
||||
public void setArrowResistance(float resistance);
|
||||
|
||||
/**
|
||||
* @return Returns Arrow Resistance
|
||||
*/
|
||||
public float getArrowResistance();
|
||||
|
||||
/**
|
||||
* @param resistance Knockback resistance (0-2) default is 1
|
||||
*/
|
||||
public void setKnockbackResistance(float resistance);
|
||||
|
||||
/**
|
||||
* @return Returns Knockback Resistance
|
||||
*/
|
||||
public float getKnockbackResistance();
|
||||
|
||||
/**
|
||||
* @param type Retaliation type. 0:normal, 1:panic, 2:retreat, 3:nothing
|
||||
*/
|
||||
public void setRetaliateType(int type);
|
||||
|
||||
/**
|
||||
* @return Returns the combat health regen per second
|
||||
*/
|
||||
public int getCombatRegen();
|
||||
|
||||
/**
|
||||
* @param regen The combat health regen per second
|
||||
*/
|
||||
public void setCombatRegen(int regen);
|
||||
|
||||
/**
|
||||
* @return Returns the health regen per second when not in combat
|
||||
*/
|
||||
public int getHealthRegen();
|
||||
|
||||
/**
|
||||
* @param regen The health regen per second when not in combat
|
||||
*/
|
||||
public void setHealthRegen(int regen);
|
||||
|
||||
public long getAge();
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
//
|
||||
// Source code recreated from a .class file by IntelliJ IDEA
|
||||
// (powered by FernFlower decompiler)
|
||||
//
|
||||
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.util.DamageSource;
|
||||
|
||||
public interface IDamageSource {
|
||||
String getType();
|
||||
|
||||
boolean isProjectile();
|
||||
|
||||
IEntity getTrueSource();
|
||||
|
||||
IEntity getImmediateSource();
|
||||
|
||||
DamageSource getMCDamageSource();
|
||||
}
|
||||
@@ -0,0 +1,303 @@
|
||||
//
|
||||
// Source code recreated from a .class file by IntelliJ IDEA
|
||||
// (powered by FernFlower decompiler)
|
||||
//
|
||||
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.entity.Entity;
|
||||
import noppes.npcs.scripted.entity.ScriptEntity;
|
||||
import noppes.npcs.scripted.ScriptItemStack;
|
||||
|
||||
public interface IEntity<T extends Entity> {
|
||||
/**
|
||||
* @param directory The particle's directory. Use only forward slashes when writing a directory. Example: "customnpcs:textures/particle/tail.png"
|
||||
* @param HEXcolor The particle's color as a HEX integer
|
||||
* @param amount The amount of particles to spawn
|
||||
* @param maxAge The particle's maximum age in MC ticks
|
||||
|
||||
* @param x The particle's x position
|
||||
* @param y The particle's y position
|
||||
* @param z The particle's z position
|
||||
|
||||
* @param motionX The particle's speed in the x axis
|
||||
* @param motionY The particle's speed in the y axis
|
||||
* @param motionZ The particle's speed in the z axis
|
||||
* @param gravity The particle's gravity
|
||||
|
||||
* @param scale1 The particle's starting scale
|
||||
* @param scale2 The particle's ending scale
|
||||
* @param scaleRate Multiplier for the particle's scale growth rate
|
||||
* @param scaleRateStart The time at which the particle begins growing/shrinking
|
||||
|
||||
* @param alpha1 The particle's starting transparency
|
||||
* @param alpha2 The particle's ending transparency
|
||||
* @param scaleRate Multiplier for the particle's transparency growth rate
|
||||
* @param alphaRateStart The time at which the particle begins appearing/fading
|
||||
*/
|
||||
public void spawnParticle(String directory, int HEXcolor, int amount, int maxAge,
|
||||
double x, double y, double z,
|
||||
double motionX, double motionY, double motionZ, float gravity,
|
||||
float scale1, float scale2, float scaleRate, int scaleRateStart,
|
||||
float alpha1, float alpha2, float alphaRate, int alphaRateStart
|
||||
);
|
||||
|
||||
public double getYOffset();
|
||||
|
||||
/**
|
||||
* @return The entities width
|
||||
*/
|
||||
public double getWidth();
|
||||
|
||||
/**
|
||||
* @return The entities height
|
||||
*/
|
||||
public double getHeight();
|
||||
|
||||
/**
|
||||
* @return The entities x position
|
||||
*/
|
||||
public double getX();
|
||||
|
||||
/**
|
||||
* @param x The entities x position
|
||||
*/
|
||||
public void setX(double x);
|
||||
|
||||
/**
|
||||
* @return The entities y position
|
||||
*/
|
||||
public double getY();
|
||||
|
||||
/**
|
||||
* @param y The entities y position
|
||||
*/
|
||||
public void setY(double y);
|
||||
|
||||
/**
|
||||
* @return The entities x position
|
||||
*/
|
||||
public double getZ();
|
||||
|
||||
/**
|
||||
* @param z The entities x position
|
||||
*/
|
||||
public void setZ(double z);
|
||||
|
||||
/**
|
||||
* @return The block x position
|
||||
*/
|
||||
public int getBlockX();
|
||||
|
||||
/**
|
||||
* @return The block y position
|
||||
*/
|
||||
public int getBlockY();
|
||||
|
||||
/**
|
||||
* @return The block z position
|
||||
*/
|
||||
public int getBlockZ();
|
||||
|
||||
/**
|
||||
* @param x The x position
|
||||
* @param y The y position
|
||||
* @param z The z position
|
||||
*/
|
||||
public void setPosition(double x, double y, double z);
|
||||
|
||||
|
||||
/**
|
||||
* @param range The search range for entities around this entity
|
||||
* @return Array of entities within range
|
||||
*/
|
||||
public ScriptEntity[] getSurroundingEntities(int range);
|
||||
|
||||
/**
|
||||
* @param range The search range for entities around this entity
|
||||
* @param type The EntityType you want to find
|
||||
* @return Array of entities within range
|
||||
*/
|
||||
public ScriptEntity[] getSurroundingEntities(int range, int type);
|
||||
|
||||
/**
|
||||
* @return Whether the entity is alive or not
|
||||
*/
|
||||
public boolean isAlive();
|
||||
|
||||
/**
|
||||
* @param key Get temp data for this key
|
||||
* @return Returns the stored temp data
|
||||
*/
|
||||
public Object getTempData(String key);
|
||||
|
||||
/**
|
||||
* Tempdata gets cleared when the entity gets unloaded or the world restarts
|
||||
* @param key The key for the data stored
|
||||
* @param value The data stored
|
||||
*/
|
||||
public void setTempData(String key, Object value);
|
||||
|
||||
/**
|
||||
* @param key The key thats going to be tested against the temp data
|
||||
* @return Whether or not temp data containes the key
|
||||
*/
|
||||
public boolean hasTempData(String key);
|
||||
|
||||
/**
|
||||
* @param key The key for the temp data to be removed
|
||||
*/
|
||||
public void removeTempData(String key);
|
||||
|
||||
/**
|
||||
* Remove all tempdata
|
||||
*/
|
||||
public void clearTempData();
|
||||
|
||||
/**
|
||||
* @param key The key of the data to be returned
|
||||
* @return Returns the stored data
|
||||
*/
|
||||
public Object getStoredData(String key);
|
||||
|
||||
/**
|
||||
* Stored data persists through world restart. Unlike tempdata only Strings and Numbers can be saved
|
||||
* @param key The key for the data stored
|
||||
* @param value The data stored. This data can be either a Number or a String. Other data is not stored
|
||||
*/
|
||||
public void setStoredData(String key, Object value);
|
||||
|
||||
/**
|
||||
* @param key The key of the data to be checked
|
||||
* @return Returns whether or not the stored data contains the key
|
||||
*/
|
||||
public boolean hasStoredData(String key);
|
||||
|
||||
/**
|
||||
* @param key The key of the data to be removed
|
||||
*/
|
||||
public void removeStoredData(String key);
|
||||
|
||||
/**
|
||||
* Remove all stored data
|
||||
*/
|
||||
public void clearStoredData();
|
||||
|
||||
/**
|
||||
* @return The age of this entity in ticks
|
||||
*/
|
||||
public long getAge();
|
||||
|
||||
/**
|
||||
* Despawns this entity. Removes it permanently
|
||||
*/
|
||||
public void despawn();
|
||||
|
||||
/**
|
||||
* @return Return whether or not this entity is standing in water
|
||||
*/
|
||||
public boolean inWater();
|
||||
|
||||
/**
|
||||
* @return Return whether or not this entity is standing in lava
|
||||
*/
|
||||
public boolean inLava();
|
||||
|
||||
/**
|
||||
* @return Return whether or not this entity is standing in fire
|
||||
*/
|
||||
public boolean inFire();
|
||||
|
||||
/**
|
||||
* @return Return whether or not this entity is on fire
|
||||
*/
|
||||
public boolean isBurning();
|
||||
|
||||
/**
|
||||
* @param ticks Amount of world ticks this entity will burn. 20 ticks equals 1 second
|
||||
*/
|
||||
public void setBurning(int ticks);
|
||||
|
||||
/**
|
||||
* Removes fire from this entity
|
||||
*/
|
||||
public void extinguish();
|
||||
|
||||
/**
|
||||
* @return Name as which it's registered in minecraft
|
||||
*/
|
||||
public String getTypeName();
|
||||
|
||||
/**
|
||||
* @param item Item to be dropped
|
||||
*/
|
||||
public void dropItem(ScriptItemStack item);
|
||||
|
||||
/**
|
||||
* @return Return the rider
|
||||
*/
|
||||
public ScriptEntity getRider();
|
||||
|
||||
/**
|
||||
* @param entity The entity to ride this entity
|
||||
*/
|
||||
public void setRider(ScriptEntity entity);
|
||||
|
||||
/**
|
||||
* @return Return the entity, this entity is riding
|
||||
*/
|
||||
public ScriptEntity getMount();
|
||||
|
||||
/**
|
||||
* @param entity The entity this entity will mount
|
||||
*/
|
||||
public void setMount(ScriptEntity entity);
|
||||
|
||||
/**
|
||||
* @see noppes.npcs.scripted.constants.EntityType
|
||||
* @return Returns the EntityType of this entity
|
||||
*/
|
||||
public int getType();
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* @param type @EntityType to check
|
||||
* @return Returns whether the entity is type of the given @EntityType
|
||||
*/
|
||||
public boolean typeOf(int type);
|
||||
|
||||
/**
|
||||
* @param rotation The rotation to be set (0-360)
|
||||
*/
|
||||
public void setRotation(float rotation);
|
||||
|
||||
/**
|
||||
* @return Current rotation of the npc
|
||||
*/
|
||||
public float getRotation();
|
||||
|
||||
/**
|
||||
* @param power How strong the knockback is
|
||||
* @param direction The direction in which he flies back (0-360). Usually based on getRotation()
|
||||
*/
|
||||
public void knockback(int power, float direction);
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* @return Returns whether or not this entity is sneaking
|
||||
*/
|
||||
public boolean isSneaking();
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* @return Returns whether or not this entity is sprinting
|
||||
*/
|
||||
public boolean isSprinting();
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* Expert users only
|
||||
* @return Returns minecrafts entity
|
||||
*/
|
||||
public T getMCEntity();
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
//
|
||||
// Source code recreated from a .class file by IntelliJ IDEA
|
||||
// (powered by Fernflower decompiler)
|
||||
//
|
||||
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.entity.EntityLiving;
|
||||
|
||||
public interface IEntityLiving<T extends EntityLiving> extends IEntityLivingBase<T> {
|
||||
boolean isNavigating();
|
||||
|
||||
void clearNavigation();
|
||||
|
||||
void navigateTo(double var1, double var3, double var5, double var7);
|
||||
|
||||
T getMCEntity();
|
||||
}
|
||||
@@ -0,0 +1,108 @@
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import noppes.npcs.scripted.entity.ScriptEntity;
|
||||
import noppes.npcs.scripted.ScriptItemStack;
|
||||
import noppes.npcs.scripted.entity.ScriptLivingBase;
|
||||
|
||||
public interface IEntityLivingBase<T extends EntityLivingBase> extends IEntity<T> {
|
||||
/**
|
||||
* @return The entity's current health
|
||||
*/
|
||||
public float getHealth();
|
||||
|
||||
/**
|
||||
* @param health The new health of this entity
|
||||
*/
|
||||
public void setHealth(float health);
|
||||
|
||||
/**
|
||||
* @return Entity's max health
|
||||
*/
|
||||
public float getMaxHealth();
|
||||
/**
|
||||
* @return Whether or not this entity is attacking something
|
||||
*/
|
||||
public boolean isAttacking();
|
||||
|
||||
/**
|
||||
* @param living Entity which this entity will attack
|
||||
*/
|
||||
public void setAttackTarget(ScriptLivingBase living);
|
||||
|
||||
/**
|
||||
* @return The entity which this entity is attacking
|
||||
*/
|
||||
public ScriptLivingBase getAttackTarget();
|
||||
|
||||
public int getType();
|
||||
|
||||
public boolean typeOf(int type);
|
||||
|
||||
/**
|
||||
* @param entity Entity to check
|
||||
* @return Whether or not this entity can see the given entity
|
||||
*/
|
||||
public boolean canSeeEntity(ScriptEntity entity);
|
||||
|
||||
/**
|
||||
* Expert use only
|
||||
* @return Returns the minecraft entity object
|
||||
*/
|
||||
public T getMCEntity();
|
||||
|
||||
/**
|
||||
* Makes the entity swing its hand
|
||||
*/
|
||||
public void swingHand();
|
||||
|
||||
/**
|
||||
* Works the same as the <a href="http://minecraft.gamepedia.com/Commands#effect">/effect command</a>
|
||||
* @param effect
|
||||
* @param duration The duration in seconds
|
||||
* @param strength The amplifier of the potion effect
|
||||
* @param hideParticles Whether or not you want to hide potion particles
|
||||
*/
|
||||
public void addPotionEffect(int effect, int duration, int strength, boolean hideParticles);
|
||||
|
||||
/**
|
||||
* Clears all potion effects
|
||||
*/
|
||||
public void clearPotionEffects();
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* @param effect Potion effect to check
|
||||
* @return Returns -1 if its not active. Otherwise returns the strenght of the potion
|
||||
*/
|
||||
public int getPotionEffect(int effect);
|
||||
|
||||
/**
|
||||
* Note not all Living Entities support this
|
||||
* @since 1.7.10c
|
||||
* @return The item the entity is holding
|
||||
*/
|
||||
public ScriptItemStack getHeldItem();
|
||||
|
||||
/**
|
||||
* Note not all Living Entities support this
|
||||
* @since 1.7.10c
|
||||
* @param item The item to be set
|
||||
*/
|
||||
public void setHeldItem(ScriptItemStack item);
|
||||
|
||||
/**
|
||||
* Note not all Living Entities support this
|
||||
* @param slot Slot of what armor piece to get, 0:boots, 1:pants, 2:body, 3:head
|
||||
* @return The item in the given slot
|
||||
*/
|
||||
public ScriptItemStack getArmor(int slot);
|
||||
|
||||
/**
|
||||
* Note not all Living Entities support this
|
||||
* @since 1.7.10c
|
||||
* @param slot Slot of what armor piece to set, 0:boots, 1:pants, 2:body, 3:head
|
||||
* @param item Item to be set
|
||||
*/
|
||||
public void setArmor(int slot, ScriptItemStack item);
|
||||
}
|
||||
@@ -0,0 +1,113 @@
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public interface IItemStack {
|
||||
public String getName();
|
||||
|
||||
/**
|
||||
* @return Returns the stacksize
|
||||
*/
|
||||
public int getStackSize();
|
||||
|
||||
/**
|
||||
* @return Return whether or not the item has a custom name
|
||||
*/
|
||||
public boolean hasCustomName();
|
||||
|
||||
/**
|
||||
* @param name The custom name this item will get
|
||||
*/
|
||||
public void setCustomName(String name);
|
||||
|
||||
/**
|
||||
* @return Return the ingame displayed name. This is either the item name or the custom name if it has one.
|
||||
*/
|
||||
public String getDisplayName();
|
||||
|
||||
/**
|
||||
* @return Get the items ingame name. Use this incase the item ingame has custom name and you want the original name.
|
||||
*/
|
||||
public String getItemName();
|
||||
|
||||
/**
|
||||
* @param size The size of the itemstack. A number between 1 and 64
|
||||
*/
|
||||
public void setStackSize(int size);
|
||||
|
||||
/**
|
||||
* @return Returns the item damage of this item. For tools this is the durability for other items the color and more.
|
||||
*/
|
||||
public int getItemDamage();
|
||||
|
||||
/**
|
||||
* @param value The value to be set as item damage. For tools this is the durability for other items the color and more.
|
||||
*/
|
||||
public void setItemDamage(int value);
|
||||
|
||||
/**
|
||||
* @param key The key of this NBTTag
|
||||
* @param value The value to be stored. Can be a Number or String
|
||||
*/
|
||||
public void setTag(String key, Object value);
|
||||
|
||||
/**
|
||||
* @param key The key of the NBTTag
|
||||
* @return Returns whether or not the key exists
|
||||
*/
|
||||
public boolean hasTag(String key);
|
||||
|
||||
/**
|
||||
* @param key The key of the NBTTag
|
||||
* @return Returns the value associated with the key. Returns null of it doesnt exist
|
||||
*/
|
||||
public Object getTag(String key);
|
||||
|
||||
public boolean isEnchanted();
|
||||
|
||||
/**
|
||||
* @since 1.7.10d
|
||||
* @param id The enchantment id
|
||||
* @return
|
||||
*/
|
||||
public boolean hasEnchant(int id);
|
||||
|
||||
/**
|
||||
* @since 1.7.10d
|
||||
* @return Returns whether this item is a book
|
||||
*/
|
||||
public boolean isWrittenBook();
|
||||
|
||||
/**
|
||||
* @since 1.7.10d
|
||||
* @return Returns the books title
|
||||
*/
|
||||
public String getBookTitle();
|
||||
|
||||
/**
|
||||
* @since 1.7.10d
|
||||
* @return Returns the books author
|
||||
*/
|
||||
public String getBookAuthor();
|
||||
|
||||
/**
|
||||
* @since 1.7.10d
|
||||
* @return If the item is a book, returns a string array with book pages
|
||||
*/
|
||||
public String[] getBookText();
|
||||
|
||||
/**
|
||||
* @return Returns whether or not this item is a block
|
||||
*/
|
||||
public boolean isBlock();
|
||||
|
||||
public INbt getNbt();
|
||||
|
||||
public INbt getItemNbt();
|
||||
|
||||
/**
|
||||
* No support is given for this method. Dont use if you dont know what you are doing.
|
||||
* @return Minecraft ItemStack
|
||||
*/
|
||||
public ItemStack getMCItemStack();
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
//
|
||||
// Source code recreated from a .class file by IntelliJ IDEA
|
||||
// (powered by Fernflower decompiler)
|
||||
//
|
||||
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.entity.monster.EntityMob;
|
||||
|
||||
public interface IMonster<T extends EntityMob> extends IEntityLiving<T> {
|
||||
}
|
||||
@@ -0,0 +1,76 @@
|
||||
//
|
||||
// Source code recreated from a .class file by IntelliJ IDEA
|
||||
// (powered by Fernflower decompiler)
|
||||
//
|
||||
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
|
||||
public interface INbt {
|
||||
void remove(String var1);
|
||||
|
||||
boolean has(String var1);
|
||||
|
||||
boolean getBoolean(String var1);
|
||||
|
||||
void setBoolean(String var1, boolean var2);
|
||||
|
||||
short getShort(String var1);
|
||||
|
||||
void setShort(String var1, short var2);
|
||||
|
||||
int getInteger(String var1);
|
||||
|
||||
void setInteger(String var1, int var2);
|
||||
|
||||
byte getByte(String var1);
|
||||
|
||||
void setByte(String var1, byte var2);
|
||||
|
||||
long getLong(String var1);
|
||||
|
||||
void setLong(String var1, long var2);
|
||||
|
||||
double getDouble(String var1);
|
||||
|
||||
void setDouble(String var1, double var2);
|
||||
|
||||
float getFloat(String var1);
|
||||
|
||||
void setFloat(String var1, float var2);
|
||||
|
||||
String getString(String var1);
|
||||
|
||||
void setString(String var1, String var2);
|
||||
|
||||
byte[] getByteArray(String var1);
|
||||
|
||||
void setByteArray(String var1, byte[] var2);
|
||||
|
||||
int[] getIntegerArray(String var1);
|
||||
|
||||
void setIntegerArray(String var1, int[] var2);
|
||||
|
||||
Object[] getList(String var1, int var2);
|
||||
|
||||
int getListType(String var1);
|
||||
|
||||
void setList(String var1, Object[] var2);
|
||||
|
||||
INbt getCompound(String var1);
|
||||
|
||||
void setCompound(String var1, INbt var2);
|
||||
|
||||
String[] getKeys();
|
||||
|
||||
int getType(String var1);
|
||||
|
||||
NBTTagCompound getMCNBT();
|
||||
|
||||
String toJsonString();
|
||||
|
||||
boolean isEqual(INbt var1);
|
||||
|
||||
void clear();
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
//
|
||||
// Source code recreated from a .class file by IntelliJ IDEA
|
||||
// (powered by Fernflower decompiler)
|
||||
//
|
||||
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.entity.passive.EntityTameable;
|
||||
|
||||
public interface IPixelmon<T extends EntityTameable> extends IAnimal<T> {
|
||||
}
|
||||
@@ -0,0 +1,169 @@
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayerMP;
|
||||
import noppes.npcs.scripted.ScriptItemStack;
|
||||
import noppes.npcs.scripted.ScriptPixelmonPlayerData;
|
||||
|
||||
public interface IPlayer<T extends EntityPlayerMP> extends IEntityLivingBase<T> {
|
||||
/**
|
||||
* @return Returns the displayed name of the player
|
||||
*/
|
||||
public String getDisplayName();
|
||||
|
||||
/**
|
||||
* @return Returns the players name
|
||||
*/
|
||||
public String getName();
|
||||
|
||||
public void setPosition(double x, double y, double z);
|
||||
|
||||
public boolean hasFinishedQuest(int id);
|
||||
|
||||
public boolean hasActiveQuest(int id);
|
||||
|
||||
public boolean hasReadDialog(int id);
|
||||
|
||||
/**
|
||||
* Add the quest from active quest list
|
||||
* @param id The Quest ID
|
||||
*/
|
||||
public void startQuest(int id);
|
||||
|
||||
/**
|
||||
* Add the quest from finished quest list
|
||||
* @param id The Quest ID
|
||||
*/
|
||||
public void finishQuest(int id);
|
||||
/**
|
||||
* Removes the quest from active quest list
|
||||
* @param id The Quest ID
|
||||
*/
|
||||
public void stopQuest(int id);
|
||||
|
||||
/**
|
||||
* Removes the quest from active and finished quest list
|
||||
* @param id The Quest ID
|
||||
*/
|
||||
public void removeQuest(int id);
|
||||
|
||||
public int getType();
|
||||
|
||||
public boolean typeOf(int type);
|
||||
/**
|
||||
* @param faction The faction id
|
||||
* @param points The points to increase. Use negative values to decrease
|
||||
*/
|
||||
public void addFactionPoints(int faction, int points);
|
||||
|
||||
/**
|
||||
* @param faction The faction id
|
||||
* @return points
|
||||
*/
|
||||
public int getFactionPoints(int faction);
|
||||
|
||||
/**
|
||||
* @param message The message you want to send
|
||||
*/
|
||||
public void sendMessage(String message);
|
||||
|
||||
/**
|
||||
* @return Return gamemode. 0: Survival, 1: Creative, 2: Adventure
|
||||
*/
|
||||
public int getMode();
|
||||
|
||||
/**
|
||||
* @param type The gamemode type. 0:SURVIVAL, 1:CREATIVE, 2:ADVENTURE
|
||||
*/
|
||||
public void setMode(int type);
|
||||
|
||||
/**
|
||||
* @param item The item to be checked
|
||||
* @return How many of this item the player has
|
||||
*/
|
||||
public int inventoryItemCount(ScriptItemStack item);
|
||||
|
||||
/**
|
||||
* @since 1.7.10d
|
||||
* @return Returns a IItemStack array size 36
|
||||
*/
|
||||
public ScriptItemStack[] getInventory();
|
||||
|
||||
/**
|
||||
* @param item The Item type to be removed
|
||||
* @param amount How many will be removed
|
||||
* @return Returns true if the items were removed succesfully. Returns false incase a bigger amount than what the player has was given
|
||||
*/
|
||||
public boolean removeItem(ScriptItemStack item, int amount);
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* @param id The items name
|
||||
* @param damage The damage value
|
||||
* @param amount How many will be removed
|
||||
* @return Returns true if the items were removed succesfully. Returns false incase a bigger amount than what the player has was given or item doesnt exist
|
||||
*/
|
||||
public boolean removeItem(String id, int damage, int amount);
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* @param item Item to be added
|
||||
* @param amount The amount of the item to be added
|
||||
* @return Returns whether or not it gave the item succesfully
|
||||
*/
|
||||
public boolean giveItem(ScriptItemStack item, int amount);
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* @param id The items name
|
||||
* @param damage The damage value
|
||||
* @param amount The amount of the item to be added
|
||||
* @return Returns whether or not it gave the item succesfully
|
||||
*/
|
||||
public boolean giveItem(String id, int damage, int amount);
|
||||
|
||||
/**
|
||||
* Same as the /spawnpoint command
|
||||
* @param x The x position
|
||||
* @param y The y position
|
||||
* @param z The z position
|
||||
*/
|
||||
public void setSpawnpoint(int x, int y, int z);
|
||||
|
||||
public void resetSpawnpoint();
|
||||
|
||||
/**
|
||||
* @param item The item to be removed from the players inventory
|
||||
*/
|
||||
public void removeAllItems(ScriptItemStack item);
|
||||
|
||||
|
||||
/**
|
||||
* @param achievement The achievement id. For a complete list see http://minecraft.gamepedia.com/Achievements
|
||||
* @return Returns whether or not the player has this achievement
|
||||
*/
|
||||
public boolean hasAchievement(String achievement);
|
||||
|
||||
/**
|
||||
* @param permission Bukkit/Cauldron permission
|
||||
* @return Returns whether or not the player has the permission
|
||||
*/
|
||||
public boolean hasBukkitPermission(String permission);
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* @return Returns the exp level
|
||||
*/
|
||||
public int getExpLevel();
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* @param level The new exp level you want to set
|
||||
*/
|
||||
public void setExpLevel(int level);
|
||||
|
||||
/**
|
||||
* Requires pixelmon to be installed
|
||||
* @since 1.7.10d
|
||||
*/
|
||||
public ScriptPixelmonPlayerData getPixelmonData();
|
||||
}
|
||||
@@ -0,0 +1,58 @@
|
||||
//
|
||||
// Source code recreated from a .class file by IntelliJ IDEA
|
||||
// (powered by Fernflower decompiler)
|
||||
//
|
||||
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
|
||||
public interface IPos {
|
||||
int getX();
|
||||
|
||||
int getY();
|
||||
|
||||
int getZ();
|
||||
|
||||
IPos up();
|
||||
|
||||
IPos up(int var1);
|
||||
|
||||
IPos down();
|
||||
|
||||
IPos down(int var1);
|
||||
|
||||
IPos north();
|
||||
|
||||
IPos north(int var1);
|
||||
|
||||
IPos east();
|
||||
|
||||
IPos east(int var1);
|
||||
|
||||
IPos south();
|
||||
|
||||
IPos south(int var1);
|
||||
|
||||
IPos west();
|
||||
|
||||
IPos west(int var1);
|
||||
|
||||
IPos add(int var1, int var2, int var3);
|
||||
|
||||
IPos add(IPos var1);
|
||||
|
||||
IPos subtract(int var1, int var2, int var3);
|
||||
|
||||
IPos subtract(IPos var1);
|
||||
|
||||
double[] normalize();
|
||||
|
||||
BlockPos getMCBlockPos();
|
||||
|
||||
IPos offset(int var1);
|
||||
|
||||
IPos offset(int var1, int var2);
|
||||
|
||||
double distanceTo(IPos var1);
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
//
|
||||
// Source code recreated from a .class file by IntelliJ IDEA
|
||||
// (powered by Fernflower decompiler)
|
||||
//
|
||||
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
public interface ITimers {
|
||||
void start(int var1, int var2, boolean var3);
|
||||
|
||||
void forceStart(int var1, int var2, boolean var3);
|
||||
|
||||
boolean has(int var1);
|
||||
|
||||
boolean stop(int var1);
|
||||
|
||||
void reset(int var1);
|
||||
|
||||
void clear();
|
||||
}
|
||||
@@ -0,0 +1,212 @@
|
||||
package noppes.npcs.scripted.interfaces;
|
||||
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import noppes.npcs.scripted.*;
|
||||
import noppes.npcs.scripted.entity.ScriptEntity;
|
||||
import noppes.npcs.scripted.entity.ScriptPlayer;
|
||||
|
||||
public interface IWorld {
|
||||
/**
|
||||
* @return The worlds time
|
||||
*/
|
||||
public long getTime();
|
||||
|
||||
/**
|
||||
* @return The total world time
|
||||
*/
|
||||
public long getTotalTime();
|
||||
|
||||
/**
|
||||
* @param x World position x
|
||||
* @param y World position y
|
||||
* @param z World position z
|
||||
* @return The block at the given position. Returns null if there isn't a block
|
||||
*/
|
||||
public IBlock getBlock(int x, int y, int z);
|
||||
|
||||
/**
|
||||
* @param x World position x
|
||||
* @param y World position y
|
||||
* @param z World position z
|
||||
* @return Text from signs
|
||||
* @since 1.7.10d
|
||||
*/
|
||||
public String getSignText(int x, int y, int z);
|
||||
|
||||
/**
|
||||
* @param x World position x
|
||||
* @param y World position y
|
||||
* @param z World position z
|
||||
* @param item The block to be set
|
||||
*/
|
||||
public void setBlock(int x, int y, int z, ScriptItemStack item);
|
||||
|
||||
/**
|
||||
* @param x World position x
|
||||
* @param y World position y
|
||||
* @param z World position z
|
||||
*/
|
||||
public void removeBlock(int x, int y, int z);
|
||||
|
||||
/**
|
||||
* @param name The name of the player to be returned
|
||||
* @return The Player with name. Null is returned when the player isnt found
|
||||
*/
|
||||
public ScriptPlayer getPlayer(String name);
|
||||
|
||||
/**
|
||||
* @param time The world time to be set
|
||||
*/
|
||||
public void setTime(long time);
|
||||
|
||||
/**
|
||||
* @return Whether or not its daytime
|
||||
*/
|
||||
public boolean isDay();
|
||||
|
||||
/**
|
||||
* @return Whether or not its currently raining
|
||||
*/
|
||||
public boolean isRaining();
|
||||
|
||||
/**
|
||||
* @param bo Set if it's raining
|
||||
*/
|
||||
public void setRaining(boolean bo);
|
||||
|
||||
/**
|
||||
* @param x The x position
|
||||
* @param y The y position
|
||||
* @param z The z position
|
||||
*/
|
||||
public void thunderStrike(double x, double y, double z);
|
||||
|
||||
/**
|
||||
* Sends a packet from the server to the client everytime its called. Probably should not use this too much.
|
||||
* @param particle Particle name. Particle name list: http://minecraft.gamepedia.com/Particles
|
||||
* @param x The x position
|
||||
* @param y The y position
|
||||
* @param z The z position
|
||||
* @param dx Usually used for the x motion
|
||||
* @param dy Usually used for the y motion
|
||||
* @param dz Usually used for the z motion
|
||||
* @param speed Speed of the particles, usually between 0 and 1
|
||||
* @param count Particle count
|
||||
*/
|
||||
public void spawnParticle(String particle, double x, double y, double z, double dx, double dy, double dz, double speed, int count);
|
||||
|
||||
/**
|
||||
* @param id The items name
|
||||
* @param damage The damage value
|
||||
* @param size The number of items in the item
|
||||
* @return Returns the item
|
||||
*/
|
||||
public ScriptItemStack createItem(String id, int damage, int size);
|
||||
|
||||
/**
|
||||
* @param directory The particle's texture directory. Use only forward slashes when writing a directory. Example: "customnpcs:textures/particle/tail.png"
|
||||
* @return Returns ScriptEntityParticle object
|
||||
*/
|
||||
public ScriptEntityParticle createEntityParticle(String directory);
|
||||
|
||||
/**
|
||||
* @param key Get temp data for this key
|
||||
* @return Returns the stored temp data
|
||||
*/
|
||||
public Object getTempData(String key);
|
||||
|
||||
/**
|
||||
* Tempdata gets cleared when the server restarts. All worlds share the same temp data.
|
||||
* @param key The key for the data stored
|
||||
* @param value The data stored
|
||||
*/
|
||||
public void setTempData(String key, Object value);
|
||||
|
||||
/**
|
||||
* @param key The key thats going to be tested against the temp data
|
||||
* @return Whether or not temp data containes the key
|
||||
*/
|
||||
public boolean hasTempData(String key);
|
||||
|
||||
/**
|
||||
* @param key The key for the temp data to be removed
|
||||
*/
|
||||
public void removeTempData(String key);
|
||||
|
||||
/**
|
||||
* Removes all tempdata
|
||||
*/
|
||||
public void clearTempData();
|
||||
|
||||
/**
|
||||
* @param key The key of the data to be returned
|
||||
* @return Returns the stored data
|
||||
*/
|
||||
public Object getStoredData(String key);
|
||||
|
||||
/**
|
||||
* Stored data persists through world restart. Unlike tempdata only Strings and Numbers can be saved
|
||||
* @param key The key for the data stored
|
||||
* @param value The data stored. This data can be either a Number or a String. Other data is not stored
|
||||
*/
|
||||
public void setStoredData(String key, Object value);
|
||||
|
||||
/**
|
||||
* @param key The key of the data to be checked
|
||||
* @return Returns whether or not the stored data contains the key
|
||||
*/
|
||||
public boolean hasStoredData(String key);
|
||||
|
||||
/**
|
||||
* @param key The key of the data to be removed
|
||||
*/
|
||||
public void removeStoredData(String key);
|
||||
|
||||
/**
|
||||
* Remove all stored data
|
||||
*/
|
||||
public void clearStoredData();
|
||||
|
||||
/**
|
||||
* @param x Position x
|
||||
* @param y Position y
|
||||
* @param z Position z
|
||||
* @param range Range of the explosion
|
||||
* @param fire Whether or not the explosion does fire damage
|
||||
* @param grief Whether or not the explosion does damage to blocks
|
||||
*/
|
||||
public void explode(double x, double y, double z, float range, boolean fire, boolean grief);
|
||||
|
||||
public ScriptPlayer[] getAllServerPlayers();
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* @param x Position x
|
||||
* @param z Position z
|
||||
* @return Returns the name of the biome
|
||||
*/
|
||||
public String getBiomeName(int x, int z);
|
||||
|
||||
/**
|
||||
* Lets you spawn a server side cloned entity
|
||||
* @param x The x position the clone will be spawned at
|
||||
* @param y The y position the clone will be spawned at
|
||||
* @param z The z position the clone will be spawned at
|
||||
* @param tab The tab in which the clone is
|
||||
* @param name Name of the cloned entity
|
||||
* @return Returns the entity which was spawned
|
||||
*/
|
||||
public ScriptEntity spawnClone(int x, int y, int z, int tab, String name);
|
||||
|
||||
public ScriptScoreboard getScoreboard();
|
||||
|
||||
BlockPos getMCBlockPos(int x, int y, int z);
|
||||
|
||||
/**
|
||||
* @since 1.7.10c
|
||||
* Expert use only
|
||||
* @return Returns minecraft world object
|
||||
*/
|
||||
public World getMCWorld();
|
||||
}
|
||||
Reference in new issue
Block a user