diff options
-rw-r--r-- | MCServer/Plugins/APIDump/APIDesc.lua | 111 | ||||
-rw-r--r-- | MCServer/Plugins/APIDump/Classes/Projectiles.lua | 111 |
2 files changed, 112 insertions, 110 deletions
diff --git a/MCServer/Plugins/APIDump/APIDesc.lua b/MCServer/Plugins/APIDump/APIDesc.lua index afe002784..44e4bb35f 100644 --- a/MCServer/Plugins/APIDump/APIDesc.lua +++ b/MCServer/Plugins/APIDump/APIDesc.lua @@ -63,45 +63,6 @@ g_APIDesc = }, ]]-- - cArrowEntity = - { - Desc = [[ - Represents the arrow when it is shot from the bow. A subclass of the {{cProjectileEntity}}. - ]], - - Functions = - { - CanPickup = { Params = "{{cPlayer|Player}}", Return = "bool", Notes = "Returns true if the specified player can pick the arrow when it's on the ground" }, - GetDamageCoeff = { Params = "", Return = "number", Notes = "Returns the damage coefficient stored within the arrow. The damage dealt by this arrow is multiplied by this coeff" }, - GetPickupState = { Params = "", Return = "PickupState", Notes = "Returns the pickup state (one of the psXXX constants, above)" }, - IsCritical = { Params = "", Return = "bool", Notes = "Returns true if the arrow should deal critical damage. Based on the bow charge when the arrow was shot." }, - SetDamageCoeff = { Params = "number", Return = "", Notes = "Sets the damage coefficient. The damage dealt by this arrow is multiplied by this coeff" }, - SetIsCritical = { Params = "bool", Return = "", Notes = "Sets the IsCritical flag on the arrow. Critical arrow deal additional damage" }, - SetPickupState = { Params = "PickupState", Return = "", Notes = "Sets the pickup state (one of the psXXX constants, above)" }, - }, - - Constants = - { - psInCreative = { Notes = "The arrow can be picked up only by players in creative gamemode" }, - psInSurvivalOrCreative = { Notes = "The arrow can be picked up by players in survival or creative gamemode" }, - psNoPickup = { Notes = "The arrow cannot be picked up at all" }, - }, - - ConstantGroups = - { - PickupState = - { - Include = "ps.*", - TextBefore = [[ - The following constants are used to signalize whether the arrow, once it lands, can be picked by - players: - ]], - }, - }, - - Inherits = "cProjectileEntity", - }, - cBlockArea = { Desc = [[ @@ -850,20 +811,6 @@ cFile:Delete("/usr/bin/virus.exe"); }, }, -- cFile - cFireChargeEntity = - { - Desc = "", - Functions = {}, - Inherits = "cProjectileEntity", - } , - - cGhastFireballEntity = - { - Desc = "", - Functions = {}, - Inherits = "cProjectileEntity", - }, -- cGhastFireballEntity - cGroup = { Desc = [[ @@ -1828,42 +1775,7 @@ cPluginManager.AddHook(cPluginManager.HOOK_CHAT, OnChatMessage); HOOK_WEATHER_CHANGING = { Notes = "Called just before the weather changes" }, HOOK_WORLD_TICK = { Notes = "Called in each world's tick thread when the game logic is about to tick (20 times a second)." }, }, - }, - - cProjectileEntity = - { - Desc = "", - Functions = - { - GetCreator = { Params = "", Return = "{{cEntity}} descendant", Notes = "Returns the entity who created this projectile. May return nil." }, - GetMCAClassName = { Params = "", Return = "string", Notes = "Returns the string that identifies the projectile type (class name) in MCA files" }, - GetProjectileKind = { Params = "", Return = "ProjectileKind", Notes = "Returns the kind of this projectile (pkXXX constant)" }, - IsInGround = { Params = "", Return = "bool", Notes = "Returns true if this projectile has hit the ground." }, - }, - Constants = - { - pkArrow = { Notes = "The projectile is an {{cArrowEntity|arrow}}" }, - pkEgg = { Notes = "The projectile is a {{cThrownEggEntity|thrown egg}}" }, - pkEnderPearl = { Notes = "The projectile is a {{cThrownEnderPearlEntity|thrown enderpearl}}" }, - pkExpBottle = { Notes = "The projectile is a thrown exp bottle (NYI)" }, - pkFireCharge = { Notes = "The projectile is a {{cFireChargeEntity|fire charge}}" }, - pkFirework = { Notes = "The projectile is a (flying) firework (NYI)" }, - pkFishingFloat = { Notes = "The projectile is a fishing float (NYI)" }, - pkGhastFireball = { Notes = "The projectile is a {{cGhastFireballEntity|ghast fireball}}" }, - pkSnowball = { Notes = "The projectile is a {{cThrownSnowballEntity|thrown snowball}}" }, - pkSplashPotion = { Notes = "The projectile is a thrown splash potion (NYI)" }, - pkWitherSkull = { Notes = "The projectile is a wither skull (NYI)" }, - }, - ConstantGroups = - { - ProjectileKind = - { - Include = "pk.*", - TextBefore = "The following constants are used to distinguish between the different projectile kinds:", - }, - }, - Inherits = "cEntity", - }, + }, -- cPluginManager cRoot = { @@ -1948,27 +1860,6 @@ end }, }, -- cServer - cThrownEggEntity = - { - Desc = "", - Functions = {}, - Inherits = "cProjectileEntity", - }, -- cThrownEggEntity - - cThrownEnderPearlEntity = - { - Desc = "", - Functions = {}, - Inherits = "cProjectileEntity", - }, -- cThrownEnderPearlEntity - - cThrownSnowballEntity = - { - Desc = "", - Functions = {}, - Inherits = "cProjectileEntity", - }, -- cThrownSnowballEntity - cTracer = { Desc = [[ diff --git a/MCServer/Plugins/APIDump/Classes/Projectiles.lua b/MCServer/Plugins/APIDump/Classes/Projectiles.lua new file mode 100644 index 000000000..08c981e5d --- /dev/null +++ b/MCServer/Plugins/APIDump/Classes/Projectiles.lua @@ -0,0 +1,111 @@ +return +{ + cArrowEntity = + { + Desc = [[ + Represents the arrow when it is shot from the bow. A subclass of the {{cProjectileEntity}}. + ]], + Functions = + { + CanPickup = { Params = "{{cPlayer|Player}}", Return = "bool", Notes = "Returns true if the specified player can pick the arrow when it's on the ground" }, + GetDamageCoeff = { Params = "", Return = "number", Notes = "Returns the damage coefficient stored within the arrow. The damage dealt by this arrow is multiplied by this coeff" }, + GetPickupState = { Params = "", Return = "PickupState", Notes = "Returns the pickup state (one of the psXXX constants, above)" }, + IsCritical = { Params = "", Return = "bool", Notes = "Returns true if the arrow should deal critical damage. Based on the bow charge when the arrow was shot." }, + SetDamageCoeff = { Params = "number", Return = "", Notes = "Sets the damage coefficient. The damage dealt by this arrow is multiplied by this coeff" }, + SetIsCritical = { Params = "bool", Return = "", Notes = "Sets the IsCritical flag on the arrow. Critical arrow deal additional damage" }, + SetPickupState = { Params = "PickupState", Return = "", Notes = "Sets the pickup state (one of the psXXX constants, above)" }, + }, + Constants = + { + psInCreative = { Notes = "The arrow can be picked up only by players in creative gamemode" }, + psInSurvivalOrCreative = { Notes = "The arrow can be picked up by players in survival or creative gamemode" }, + psNoPickup = { Notes = "The arrow cannot be picked up at all" }, + }, + ConstantGroups = + { + PickupState = + { + Include = "ps.*", + TextBefore = [[ + The following constants are used to signalize whether the arrow, once it lands, can be picked by + players: + ]], + }, + }, + Inherits = "cProjectileEntity", + }, -- cArrowEntity + + cFireChargeEntity = + { + Desc = "", + Functions = {}, + Inherits = "cProjectileEntity", + }, -- cFireChargeEntity + + cGhastFireballEntity = + { + Desc = "", + Functions = {}, + Inherits = "cProjectileEntity", + }, -- cGhastFireballEntity + + cProjectileEntity = + { + Desc = "", + Functions = + { + GetCreator = { Params = "", Return = "{{cEntity}} descendant", Notes = "Returns the entity who created this projectile. May return nil." }, + GetMCAClassName = { Params = "", Return = "string", Notes = "Returns the string that identifies the projectile type (class name) in MCA files" }, + GetProjectileKind = { Params = "", Return = "ProjectileKind", Notes = "Returns the kind of this projectile (pkXXX constant)" }, + IsInGround = { Params = "", Return = "bool", Notes = "Returns true if this projectile has hit the ground." }, + }, + Constants = + { + pkArrow = { Notes = "The projectile is an {{cArrowEntity|arrow}}" }, + pkEgg = { Notes = "The projectile is a {{cThrownEggEntity|thrown egg}}" }, + pkEnderPearl = { Notes = "The projectile is a {{cThrownEnderPearlEntity|thrown enderpearl}}" }, + pkExpBottle = { Notes = "The projectile is a thrown exp bottle (NYI)" }, + pkFireCharge = { Notes = "The projectile is a {{cFireChargeEntity|fire charge}}" }, + pkFirework = { Notes = "The projectile is a (flying) firework (NYI)" }, + pkFishingFloat = { Notes = "The projectile is a fishing float (NYI)" }, + pkGhastFireball = { Notes = "The projectile is a {{cGhastFireballEntity|ghast fireball}}" }, + pkSnowball = { Notes = "The projectile is a {{cThrownSnowballEntity|thrown snowball}}" }, + pkSplashPotion = { Notes = "The projectile is a thrown splash potion (NYI)" }, + pkWitherSkull = { Notes = "The projectile is a wither skull (NYI)" }, + }, + ConstantGroups = + { + ProjectileKind = + { + Include = "pk.*", + TextBefore = "The following constants are used to distinguish between the different projectile kinds:", + }, + }, + Inherits = "cEntity", + }, -- cProjectileEntity + + cThrownEggEntity = + { + Desc = "", + Functions = {}, + Inherits = "cProjectileEntity", + }, -- cThrownEggEntity + + cThrownEnderPearlEntity = + { + Desc = "", + Functions = {}, + Inherits = "cProjectileEntity", + }, -- cThrownEnderPearlEntity + + cThrownSnowballEntity = + { + Desc = "", + Functions = {}, + Inherits = "cProjectileEntity", + }, -- cThrownSnowballEntity +} + + + + |