Skip to content

Actions: Place Block

NorthWestTrees edited this page Feb 21, 2023 · 4 revisions

⚠ Work In Progress: These things may change as development progresses.

Overview

Place block is a type of action run from the Action command in AAI.

  • Anything using [] square brackets are optional.
  • Anything using <> the greater and less than sign are required.
  • Anything using () brackets have more than one option they can also be ([]) or (<>) too
Icon Description
item Itemstack value
block_state Block state value
position Position value
string String value (Text)
entity Entity value
boolean Boolean value (True/False)
math Math value (Number)
literal Literal value

Conditional

  • /aai

    • Main command
  • literal action

    • Subcommand
  • literal placeBlock

    • The action subcommand.
  • literal (conditional|look|position)

    • conditional

      This can be used to search for a block near the entity using conditions.

      • item itemToPlace
        • The item you wish to place.
      • math searchRadius
        • The area in which the target block will be searched for.
      • math slotCount
        • The total number of inventory slots the entity has.
        • This is used when placing items from the entity's inventory.
      • block_state targetBlock
        • The block which you will be found first.
      • block_state conditionBlock
        • The block used for the condition!
      • string tags
        • Tags are used for configuring the command.
        • Each tag runs a part of the script.
          • -S: When added as a tag the block state will be kept.
          • -D: When added as a tag the block inventory and NBT will be kept.
          • -B: If you are using buckets of water or lava then you can use bucket mode to place liquids.
          • -I: When used this will require the item to be in the entity's inventory.
          • -C: Only used when -I is added to the list but will make it like creative mode.
          • -H: Will allow you to use NBT Hooks
          • -T: When T is used you can replace the block using a targetBlock instead.
      • string face
        • The fact that the conditionBlock should be on from your search location.
          • north: Will test for the conditional block on this side of the target block.
          • east: Will test for the conditional block on this side of the target block.
          • south: Will test for the conditional block on this side of the target block.
          • west: Will test for the conditional block on this side of the target block.
          • up: Will test for the conditional block on this side of the target block.
          • down: Will test for the conditional block on this side of the target block.
      • string rotation
        • This attempts to override the block's rotation after it has been placed.
          • north: Will try to rotate the block to face this side.
          • east: Will try to rotate the block to face this side.
          • south: Will try to rotate the block to face this side.
          • west: Will try to rotate the block to face this side.
          • up: Will try to rotate the block to face this side.
          • down: Will try to rotate the block to face this side.
      • string hookOutput
        • If you are using the hook tag -H then you can set a string variable to be set once the action was complete.

Look

  • /aai

    • Main command
  • literal action

    • Subcommand
  • literal placeBlock

    • The action subcommand.
  • literal (conditional|look|position)

    • look

      This place action will place the block on the face of the block closest to the entity is looking at.

      • item itemToPlace
        • The item you wish to place.
      • math slotCount
        • The total number of inventory slots the entity has.
        • This is used when placing items from the entity's inventory.
      • math raytraceDistance
        • The maximum reach where the entity can place a block.
      • string tags
        • Tags are used for configuring the command.
        • Each tag runs a part of the script.
          • -S: When added as a tag the block state will be kept.
          • -D: When added as a tag the block inventory and NBT will be kept.
          • -B: If you are using buckets of water or lava then you can use bucket mode to place liquids.
          • -I: When used this will require the item to be in the entity's inventory.
          • -C: Only used when -I is added to the list but will make it like creative mode.
          • -H: Will allow you to use NBT Hooks
          • -T: When T is used you can replace the block using a targetBlock instead.
      • string face
        • The fact that the conditionBlock should be on from your search location.
          • north: Will test for the conditional block on this side of the target block.
          • east: Will test for the conditional block on this side of the target block.
          • south: Will test for the conditional block on this side of the target block.
          • west: Will test for the conditional block on this side of the target block.
          • up: Will test for the conditional block on this side of the target block.
          • down: Will test for the conditional block on this side of the target block.
      • string rotation
        • This attempts to override the block's rotation after it has been placed.
          • north: Will try to rotate the block to face this side.
          • east: Will try to rotate the block to face this side.
          • south: Will try to rotate the block to face this side.
          • west: Will try to rotate the block to face this side.
          • up: Will try to rotate the block to face this side.
          • down: Will try to rotate the block to face this side.
      • string hookOutput
        • If you are using the hook tag -H then you can set a string variable to be set once the action was complete.

Position

  • /aai

    • Main command
  • literal action

    • Subcommand
  • literal placeBlock

    • The action subcommand.
  • literal (conditional|look|position)

    • position

      This can use a set position you enter to place the block.

      • item itemToPlace
        • The item you wish to place.
      • math slotCount
        • The total number of inventory slots the entity has.
        • This is used when placing items from the entity's inventory.
      • position position
        • The coordinates for where you want the block to be placed.
      • string tags
        • Tags are used for configuring the command.
        • Each tag runs a part of the script.
          • -S: When added as a tag the block state will be kept.
          • -D: When added as a tag the block inventory and NBT will be kept.
          • -B: If you are using buckets of water or lava then you can use bucket mode to place liquids.
          • -I: When used this will require the item to be in the entity's inventory.
          • -C: Only used when -I is added to the list but will make it like creative mode.
          • -H: Will allow you to use NBT Hooks
          • -T: When T is used you can replace the block using a targetBlock instead.
      • string face
        • The fact that the conditionBlock should be on from your search location.
          • north: Will test for the conditional block on this side of the target block.
          • east: Will test for the conditional block on this side of the target block.
          • south: Will test for the conditional block on this side of the target block.
          • west: Will test for the conditional block on this side of the target block.
          • up: Will test for the conditional block on this side of the target block.
          • down: Will test for the conditional block on this side of the target block.
      • string rotation
        • This attempts to override the block's rotation after it has been placed.
          • north: Will try to rotate the block to face this side.
          • east: Will try to rotate the block to face this side.
          • south: Will try to rotate the block to face this side.
          • west: Will try to rotate the block to face this side.
          • up: Will try to rotate the block to face this side.
          • down: Will try to rotate the block to face this side.
      • string hookOutput
        • If you are using the hook tag -H then you can set a string variable to be set once the action was complete.
Clone this wiki locally