Builder: Difference between revisions

From Citizens Wiki

No edit summary
No edit summary
 
(61 intermediate revisions by 3 users not shown)
Line 3: Line 3:
| AUTHOR      =  jrbudda
| AUTHOR      =  jrbudda
| NAME        = Builder
| NAME        = Builder
| VERSION    = 0.6 Preview2
| VERSION    = 0.9.1 build 2
| CITIZENSBUILD  = [http://ci.citizensnpcs.com/job/Citizens2/ 2.0.3 Build 470]
| CITIZENSBUILD  = [http://ci.citizensnpcs.co/job/Citizens2/ 2.0.20] (Craftbukkit 1.10+)
| DEVSTATUS    = InDev
| DEVSTATUS    = Release
| DEPENDS    =  None required.
| DEPENDS    =  None required.
| DOWNLOADLINK  = https://github.com/jrbudda/Builder/downloads
| DOWNLOADLINK  = http://ci.citizensnpcs.co/job/Builder/lastSuccessfulBuild/
| DESCRIPTION  = Citizens NPCs that build schematics.
| DESCRIPTION  = Citizens NPCs that build schematics.
}}
}}


'''{{color|darkgoldenrod|white| Builder should be used with the specified development build of Citizens2. Use the link at the right to download it along with Builder.}}
===ATTENTION:===
===The author of this plugin has gone inactive. Third party forks exist if you search for them elsewhere.===


'''Builder''' is a Citizens 2.0 [[Characters|character trait]] that gives NPCs the ability to:
'''Builder''' is a Citizens 2.0 [[Characters|character trait]] that gives NPCs the ability to:
Line 21: Line 22:
==Updates==
==Updates==
{{scrollbox|
{{scrollbox|
'''Builder For CraftBukkit 1.10+''' [http://ci.citizensnpcs.co/job/Builder/18/artifact/target/Builder.jar download]
* NMS update by Morphan1
'''Builder For CraftBukkit 1.9.4''' [http://ci.citizensnpcs.co/job/Builder/13/artifact/target/Builder.jar download]
* NMS update by Morphan1
'''Builder For CraftBukkit 1.9''' [http://ci.citizensnpcs.co/job/Builder/12/artifact/target/Builder.jar download]
* NMS update by Morphan1
'''Builder For CraftBukkit 1.8.7''' [http://ci.citizensnpcs.co/job/Builder/9/artifact/target/Builder.jar download]
* NMS update by Morphan1
'''Builder For CraftBukkit 1.8.3''' [http://ci.citizensnpcs.co/job/Builder/4/artifact/target/Builder.jar download]
* NMS update by Morphan1
'''Builder For CraftBukkit 1.8''' [http://ci.citizensnpcs.co/job/Builder/3/artifact/target/Builder.jar download]
* NMS update by Morphan1
'''v. 0.9.1 build 2''' 6/3/2014 [http://ci.citizensnpcs.co/job/Builder/2/artifact/target/Builder.jar download]
* Update for craftbukkit 1.7.10
'''v. 0.9.1''' 6/3/2014 [http://www.sendspace.com/file/646mvv download]
* Update for craftbukkit 1.7.9
'''v. 0.9.0''' 12/11/2013 [http://www.sendspace.com/file/5q3v9h download]
* Update for craftbukkit 1.7.2
'''v. 0.8.2''' 9/20/2013 [http://www.sendspace.com/file/3qk2qa download]
* Update for craftbukkit 1.6.4
'''v. 0.8.1''' 8/8/2013 [http://www.sendspace.com/file/sb8tfc download]
* added ''silent'' build option that suppresses the messages builder sends to the person who started a build.
* Fixed excavate option so it works.
'''v. 0.8''' 7/29/2013 [http://www.sendspace.com/file/4yhc12 download]
*Builders have gone to engineering school and now support tile entities (chest contents, sign text, skull types, command blocks, etc...)
*Added command /builder origin x,y,z
*Maybe some improvements to memory usage on large schematics.
*Added command block to default list of blocks not needed for supply mode.
*Fix warning at startup.
'''v. 0.7.2 ''' 7/9/2013 [http://www.sendspace.com/file/imftlv download]
*Compatible with Bukkit 1.6.2
'''v. 0.7.1 ''' 7/3/2013 [http://www.sendspace.com/file/xkjvbb download]
*Compatible with Bukkit 1.6.1
*Compatible with Denizen .9
'''v. 0.7 ''' 6/27/2013 [http://www.sendspace.com/file/v7td6n download]
*Supply mode is now customizable
'''v. 0.6.9 ''' 5/4/2013 [http://www.sendspace.com/file/smy3z8 download]
* Update for craftbukkit 1.5.2
* Properly group new blocks from 1.4.7 and 1.5.x updates.
* Add server-wide setting so that Supply mode requires exact blocks.
'''v. 0.6.8.1 ''' 3/21/2013 [http://www.sendspace.com/file/nv50m2 download]
* Update for craftbukkit 1.5.1
'''v. 0.6.8 ''' 3/19/2013 [http://www.sendspace.com/file/x36t95 download]
* Compatibility with cb 1.5, citizens 2.0.8, and Denizen .8
'''v. 0.6.7 ''' 1/19/2013 [http://www.sendspace.com/file/dwm2gl download]
* Compatibility with cb 1.4.7
'''v. 0.6.6 final ''' 1/4/2013 [http://www.sendspace.com/file/49vrxe download]
* Use with cb 1.4.6
* Fix persistence bug with needed materials in supply mode and layers build option.
'''v. 0.6.6b ''' 12/22/2012 [http://www.sendspace.com/file/634eev download]
* Compatibility with CraftBukkit 1.4.6r0.1 and Citizens2 2.0.6.
'''v. 0.6.5''' 12/20/2012 [http://www.sendspace.com/file/5xpctb download]
* Compatibility with CraftBukkit 1.4.5r1.0 and Citizens2 2.0.5 Release.
'''v. 0.6.4''' 12/9/2012
* Compatibility with latest craftbukkit 1.4.5 r.03 and citizens2 build 606+.
'''v. 0.6.3''' 11/30/2012
* Compatible with craftbukkit 1.4.4 - 1.4.5 r0.2 and citizens2 build 597.
* Fix crops/seeds error.
* Accept either type of pressure plate for supply mode.
'''v. 0.6.2''' 10/29/2012
* Update for cb 1.4.2... with NOT work with 1.3 !
'''v. 0.6.1''' 10/25/2012
* Final fixes to supply mode. Release of .6
'''v. 0.6 ALPHA3''' 10/19/2012 {{color|green|white| This is a test release to ferret out any oddities in Supply Mode, please let me know if it doesn't work like it should}}
'''v. 0.6 ALPHA3''' 10/19/2012 {{color|green|white| This is a test release to ferret out any oddities in Supply Mode, please let me know if it doesn't work like it should}}
* Fixed supply requirement for glass blocks and panes, melon, bookshelves, ender chests, snow, ice, double slabs.
* Fixed supply requirement for glass blocks and panes, melon, bookshelves, ender chests, snow, ice, double slabs.
Line 103: Line 194:
}}
}}


<!-- THIS SECTION IS BROKEN
{|
{|
{{#ev:youtube|UyAR7-_17XY|}} |{{#ev:youtube|ZiYhFZi5vB0|}} | {{#ev:youtube|HOxX9pb--NQ|}} | {{#ev:youtube|KS4v17Y8xcA|}}  
{{#ev:youtube|UyAR7-_17XY|}} |{{#ev:youtube|ZiYhFZi5vB0|}} | {{#ev:youtube|HOxX9pb--NQ|}} | {{#ev:youtube|KS4v17Y8xcA|}}  
|}
|}
-->


==Installation==
==Installation==
Line 146: Line 239:


'''/builder origin current''' - Sets the origin of the builder's projects to the origin of the project currently being built. Use this if you forgot to set the origin before starting to build, and need to cancel it to resume later.
'''/builder origin current''' - Sets the origin of the builder's projects to the origin of the project currently being built. Use this if you forgot to set the origin before starting to build, and need to cancel it to resume later.
'''/builder origin x,y,z''' - Sets the origin of the builder's projects to the location x,y,z of the builder's current world.


'''/builder mark (item)''' - Places a block at the 4 corners of the footprint, then returns to the origin, so you can see where it's going to build. You can specify the item to use, although that item must be allowed in the config.yml. The first item on the list in the config is the default if no item is specified. If the config is missing the builder will use GLASS.
'''/builder mark (item)''' - Places a block at the 4 corners of the footprint, then returns to the origin, so you can see where it's going to build. You can specify the item to use, although that item must be allowed in the config.yml. The first item on the list in the config is the default if no item is specified. If the config is missing the builder will use GLASS.
Line 162: Line 257:
*ignoreair - the builder will not place air blocks. (Use to build into an existing structure, pointless if used with excavate)
*ignoreair - the builder will not place air blocks. (Use to build into an existing structure, pointless if used with excavate)
*ignoreliquid - the builder will not place lava or water blocks. (Use if the schematic has unconstrained liquids on the bottom.)
*ignoreliquid - the builder will not place lava or water blocks. (Use if the schematic has unconstrained liquids on the bottom.)
*onstart:Task - the builder will run the [[Denizen]] task script on start of build (after material collection). See [[#Advanced Usage]]
*oncomplete:Task - the builder will run the [[Denizen]] task script on completion of build. See [[#Advanced Usage]]
*oncomplete:Task - the builder will run the [[Denizen]] task script on completion of build. See [[#Advanced Usage]]
*oncancel:Task - the builder will run the [[Denizen]] task script on cancellation of build. See [[#Advanced Usage]]
*oncancel:Task - the builder will run the [[Denizen]] task script on cancellation of build. See [[#Advanced Usage]]
*silent - the builder will not send completion/error messages to the command sender.


Examples:
Examples:
  /builder build
  /builder build
  /builder build excavate reverselinear yoffset:-3
  /builder build excavate reverselinear yoffset:-3
  /builder build ignoreair ignoreliquid oncomplete:Celbrate
  /builder build ignoreair ignoreliquid oncomplete:Celebrate
  /builder build groupall layers:3
  /builder build groupall layers:3


Line 186: Line 283:


==Usage==
==Usage==
*.schematic files should be placed in the /plugins/Builder/schematics/ directory. This directory can be configured in the config.yml
*.schematic files should be placed in the ''/plugins/Builder/schematics/'' directory. This directory can be configured in the config.yml
* Position the builder, or set the builder's '''origin''', to the ''center'' of the footpoint you want to build before calling '''build'''. The size of the schematic is shown upon load.
* Position the builder, or set the builder's '''origin''', to the ''center'' of the footpoint you want to build before calling '''build'''. The size of the schematic is shown upon load.
* You can cancel a build and resume it later if you have an Origin set. You can use <code> /builder origin current </code> to set the origin after building has started if you forgot.
* You can cancel a build and resume it later if you have an Origin set. You can use <code> /builder origin current </code> to set the origin after building has started if you forgot.
Line 197: Line 294:
***Load the schematic to a builder and call <code> /builder origin schematic</code>.
***Load the schematic to a builder and call <code> /builder origin schematic</code>.
***Call /builder build and the builder will place any missing blocks or destroy new ones.
***Call /builder build and the builder will place any missing blocks or destroy new ones.
*Builder will '''{{color|red|white| NOT}}''' create sign text, chest contents, paintings, or anything else that uses extended data. (Hey this is Construction, not Home Decoratin'.)
*Rail and dispensers my not be placed correctly. (Hey this is Construction, not Engimaneerin'.)
*Rail and dispensers my not be placed correctly. (Hey this is Construction, not Engimaneerin'.)
*By default, NPCs despawn when their chunk unloads. This behavior can be changed in the Citizens2 config.yml, and is recommended if you would like builders to continue to work unattended.


==Supply Mode==
==Supply Mode==
If the Builder is set to require materials for building (with /builder supply true), he will go into Supply Mode when build is called. When Supply Mode starts the Builder will survey the build site and generate a list of required materials to start building. Players must provide these materials for the builder to begin.  
If the Builder is set to require materials for building (with ''/builder supply true''), he will go into Supply Mode when ''/builder build'' is called. When Supply Mode starts the Builder will survey the build site and generate a list of required materials to start building. Players must provide these materials for the builder to begin.  


While in Supply Mode:
While in Supply Mode:
Line 209: Line 306:
* After receiving a material the Builder will say how many more blocks he needs in total to begin, or he will begin building if he has everything.
* After receiving a material the Builder will say how many more blocks he needs in total to begin, or he will begin building if he has everything.


Some notes about Supply Mode:
What materials are required:
* Water and Lava do not need to be supplied.
*By default all blocks require their normal drop type (i.e. Cobwebs require String)
* Unobtainable blocks, or blocks only obtainable via Silk Touch or Creative Mode, are supplied by giving their normal drop type. (example Cobwebs require giving String).
*This behavior can be overridden via the 'supply.txt' file found in the \Builder folder.
* All blocks are matched on Item ID only. This means:
**Each line contains the Item ID of the block in the schematic, and the ItemID of the block/Item that is required.
** All Wool is Wool. Color is ignored building the list, and any color wool can be given to fulfill the requirement.
**Optionally you can specify the number of blocks/items required for each source block.
** The same goes for saplings, slabs, logs, and wood planks.
**Setting the required Item ID to 0 will not include that source block in the requirements.
** Stairs are similar. All wood stairs count as 'oak'. All stone/brick stairs count as 'stone' with the exception of nether brick stairs which are separate.
 
* If the build is canceled at any point, the collected materials are lost.
{| class="wikitable collapsible collapsed"
! Default Supply Mode configuration
|-
|<pre>
Original Block Number:Require Item Number:Amount(Optional)
Set to 0 to never require block. Blocks not specified will require their normal drop item.
90:0
97:0
95:54
78:0
34:0
119:0
80:80
92:354
43:44:2
125:126:2
20:20
102:102
47:47
103:362
130:130
134:53
135:53
136:53
128:67
109:67
108:67
79:332
51:0
59:295
72:70
71:330:0.5
26:335:0.5
</pre>
|}
 
All blocks are currently matched on Item ID only. This means:
* All Wool is Wool. Color is ignored building the list, and any color wool can be given to fulfill the requirement.
* The same goes for saplings, slabs, logs, and wood planks.
* Stairs are similar. All wood stairs count as 'oak'. All stone/brick stairs count as 'stone' with the exception of nether brick stairs which are separate.
 
If the build is canceled at any point, the collected materials are lost.


==Advanced Usage==
==Advanced Usage==
Line 227: Line 365:
Example:
Example:
  /builder build oncomplete:DespawnTask oncancel:AnnounceTask
  /builder build oncomplete:DespawnTask oncancel:AnnounceTask
**Only certain commands are valid in a Task script of this kind. See [[..something]]
 
**This usage would almost always be used from another Denizen script, although you may call it in-game, if you wish.
*Builder can also run [[Denizen Actions]] at the 3 indicated events. Add the following to the NPC's actions:
**"Build Start"
**"Build Complete"
**"Build Cancel"
Example:
 
<code>
BuilderAssignment:
  type: assignment
  actions:
    on Build Start:
      - ANNOUNCE "Let's do this!"
    on Build Complete:
      - ANNOUNCE "I have finished!"
</code>


For more complex examples with Denizen and Builder see [[Builder/Builder_and_Denizen|Builder and Denizen Examples]]
For more complex examples with Denizen and Builder see [[Builder/Builder_and_Denizen|Builder and Denizen Examples]]


==Planned Additions==
==FAQ==
Q: How can I use multiple builders on one project?


0.6
A: You can use up to 4 builders on one project by giving them all the same schematic and origin, but different build patterns. You can also manually split your schematic into multiple parts with WorldEdit or MCEdit.
*Require materials for building.


0.7+
Q: How can I make builders go faster?
*Rotate/flip before build
*Chest contents and sign texts
*'Mimic' mode, builds and digs alongside you!
*'Construction Registry' remembers schematic/location data and can dispatch repairmen later on.
*Optionally honor build protection. This has proven problematic due to builders building when their owner is offline.


NOT doing:
A: Use the /builder timeout command to set the max time between blocks. You can also make the builder walk faster with "/npc speed"
*Multiple builders per schematic. Sorry, no. split up the schematic manually  with worldedit, it will look better anyway.
*Built-in economy handling. Use [[Denizen]], much more configurable. Example scripts soon.


[https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=JVBJLN5HJJS52&lc=US&item_name=jrbudda&currency_code=USD&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHosted Donate to jrbudda]
[https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=JVBJLN5HJJS52&lc=US&item_name=jrbudda&currency_code=USD&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHosted Donate to jrbudda]

Latest revision as of 21:24, 1 February 2021

Builder.png

Builder


Author jrbudda
Version 0.9.1 build 2
Citizens build 2.0.20 (Craftbukkit 1.10+)
Other dependencies None required.
Download Link
Description: Citizens NPCs that build schematics.

ATTENTION:

The author of this plugin has gone inactive. Third party forks exist if you search for them elsewhere.

Builder is a Citizens 2.0 character trait that gives NPCs the ability to:

  • Build MCEdit/Worldedit schematics, block by block.
  • Rebuild an area, fixing anything that has been changed.
  • Collect the required materials from players before building.

Updates


Builder For CraftBukkit 1.10+ download

  • NMS update by Morphan1

Builder For CraftBukkit 1.9.4 download

  • NMS update by Morphan1

Builder For CraftBukkit 1.9 download

  • NMS update by Morphan1

Builder For CraftBukkit 1.8.7 download

  • NMS update by Morphan1

Builder For CraftBukkit 1.8.3 download

  • NMS update by Morphan1

Builder For CraftBukkit 1.8 download

  • NMS update by Morphan1

v. 0.9.1 build 2 6/3/2014 download

  • Update for craftbukkit 1.7.10

v. 0.9.1 6/3/2014 download

  • Update for craftbukkit 1.7.9

v. 0.9.0 12/11/2013 download

  • Update for craftbukkit 1.7.2

v. 0.8.2 9/20/2013 download

  • Update for craftbukkit 1.6.4

v. 0.8.1 8/8/2013 download

  • added silent build option that suppresses the messages builder sends to the person who started a build.
  • Fixed excavate option so it works.

v. 0.8 7/29/2013 download

  • Builders have gone to engineering school and now support tile entities (chest contents, sign text, skull types, command blocks, etc...)
  • Added command /builder origin x,y,z
  • Maybe some improvements to memory usage on large schematics.
  • Added command block to default list of blocks not needed for supply mode.
  • Fix warning at startup.

v. 0.7.2 7/9/2013 download

  • Compatible with Bukkit 1.6.2

v. 0.7.1 7/3/2013 download

  • Compatible with Bukkit 1.6.1
  • Compatible with Denizen .9

v. 0.7 6/27/2013 download

  • Supply mode is now customizable

v. 0.6.9 5/4/2013 download

  • Update for craftbukkit 1.5.2
  • Properly group new blocks from 1.4.7 and 1.5.x updates.
  • Add server-wide setting so that Supply mode requires exact blocks.

v. 0.6.8.1 3/21/2013 download

  • Update for craftbukkit 1.5.1

v. 0.6.8 3/19/2013 download

  • Compatibility with cb 1.5, citizens 2.0.8, and Denizen .8

v. 0.6.7 1/19/2013 download

  • Compatibility with cb 1.4.7

v. 0.6.6 final 1/4/2013 download

  • Use with cb 1.4.6
  • Fix persistence bug with needed materials in supply mode and layers build option.

v. 0.6.6b 12/22/2012 download

  • Compatibility with CraftBukkit 1.4.6r0.1 and Citizens2 2.0.6.

v. 0.6.5 12/20/2012 download

  • Compatibility with CraftBukkit 1.4.5r1.0 and Citizens2 2.0.5 Release.

v. 0.6.4 12/9/2012

  • Compatibility with latest craftbukkit 1.4.5 r.03 and citizens2 build 606+.

v. 0.6.3 11/30/2012

  • Compatible with craftbukkit 1.4.4 - 1.4.5 r0.2 and citizens2 build 597.
  • Fix crops/seeds error.
  • Accept either type of pressure plate for supply mode.

v. 0.6.2 10/29/2012

  • Update for cb 1.4.2... with NOT work with 1.3 !

v. 0.6.1 10/25/2012

  • Final fixes to supply mode. Release of .6

v. 0.6 ALPHA3 10/19/2012 This is a test release to ferret out any oddities in Supply Mode, please let me know if it doesn't work like it should

  • Fixed supply requirement for glass blocks and panes, melon, bookshelves, ender chests, snow, ice, double slabs.
  • Changed supply requirement for stairs: all wood stairs count as 'oak wood stairs'. All stone stairs (except nether brick) count as 'stone brick stairs'. This is to match the behavior with slabs.

v. 0.6 ALPHA2 10/15/2012 This is a test release to ferret out any oddities in Supply Mode, please let me know if it doesn't work like it should

  • Added builder.donate permission. This allows players to donate to a builder in supply mode.
  • Fix calling build from the console.

v. 0.6 ALPHA 10/14/2012 This is a test release to ferret out any oddities in Supply Mode, please let me know if it doesn't work like it should

  • Supply Mode - Builders can now be set so that players must provide all the materials before the builder will start building. use /builder supply true to turn this on, then call /builder build as usual.
    • Once build is called the Builder will go into Supply mode. See section for details.
    • Only those blocks actually needed will be required (if some are already in place)
    • The collected materials will persist if the server is restarted.
    • Localized names are used for all items and blocks. (based on server language setting)
    • If the build is canceled the collected items are lost.
    • Unobtainable blocks are supplied by giving their normal drop type (example: Cobwebs require players to supply String). Please let me know if I missed any.
  • Fixed 'mark' and 'schematic origin' sometimes being off by 1 block.
  • Moved the 'nohold' build option to its own command: /builder hold true/false
  • Added onstart: build option, this will run a Denizen task when the builder starts building (after collecting required materials, if set)

v. 0.5.1 Beta 10/4/2012

  • Added command /builder list
  • Added build option: yoffset

v. 0.5 Beta 9/25/2012

  • It is highly recommenced you use this with build 382+ of citizens2. 382 has some pathfinding fixes that make high /npc speed settings less... undesirable.
  • Builders loaded with the same schematic will share it in memory. Reduces RAM overhead.
  • Schematics are now pre-processed right when you call build, this has the following consequences:
    • Less memory usage for the to-build list
    • /builder info now shows total block count, blocks remaining, and a % complete during the build.
    • new command: survey shows the material list required to build in the current location, taking into account what is already there.
    • You may experience a small server hiccup when you call build for VERY large schematics (millions of blocks) Hope to reduce this for the future.
  • New command: timeout sets the maximum time between blocks. Can be set as low as 0.1 seconds. (The fastest possible build speed is about 5 blocks per second.)

v. 0.4.1 Beta 9/18/2012

  • Verical Build options you can now specify layers:X to build X number of layers at a time. Significantly speeds up building.
  • Grouping option you can specify groupall to build ALL of one group of materials at a time (instead of doing it at every set of layers)
  • added commands: origin me, origin current
  • excavate works from the top down, as you would expect.

v. 0.4 Beta 9/16/2012

  • New build order Builder now places items in groupings based on item type: base blocks, furniture, redstone, liquids, and decorations. This is done per layer because I didn't like how it looked building all the layers of one type first. Maybe configurable later.
  • New build patterns! builders can use: spiral, linear, reversespiral or reverselinear (this is for the x-z plane, builders still build from the bottom layer up, 1 layer at a time... for now!) the default is spiral.
  • (Okay I'll admit this sort of lets you use up to 4 builders on 1 schematic if they have the same origin and different patterns... but shhh it's our secret :))
  • Excavate mode! builders can optionally dig out the area before building!
  • Configuration! Builder now makes a config.yml that can be used to change the default schematics directory. messages and allowable 'marking' materials.
  • Holding items! Player and Endermen-type builders will now hold the item they are about to place, or a pickaxe if breaking blocks.
  • Fix mob-type builders, they no longer crash clients because cows can't swing their arms!
  • the ignoreliquid and ignoreair commands have been removed specify these options when calling /builder build.
  • Hooked into dynmap to trigger an area render on completion/cancellation of build.

v. 0.3.2 Beta 9/13/2012

  • Builder will remove previous marks before building or placing new ones.
  • Fix skipping first block in schematic.
  • Improved error messages an other minor fixes.
  • Target Java 6 instead of 7.

v. 0.3.1 Alpha 9/12/2012

  • Pathing and other minor bugfixes.
  • fix /builder mark
  • /builder help actually provides help.

v. 0.3 Alpha 9/11/2012

  • Added Denizen Task script execution option on build completion and cancellation.
  • Reduced memory usage of loaded schematics by 80%.
  • Last loaded schematic is now persistent.
  • Lots of updates to messages and info.

v. 0.2.1 Alpha 9/9/2012

  • added commands origin clear, origin schematic, check, compare

v. 0.2 Alpha 9/9/2012

  • Added commands ignoreair, ignoreliquid, origin, info

v. 0.1.1 Alpha 9/9/2012

  • Added Mark command.
  • Better pathing.

v. 0.1 Alpha 9/9/2012

  • First release


Installation

  • Install Citizens 2
  • Place Builder.jar file in /plugins directory.
  • Place .schematic files in /plugins/Builder/schematics/
  • Start Server
  • Create NPC and give the Builder trait.
/npc create Bob --trait builder

or

/npc create Bob
/trait builder

Permissions

  • builder.* Give access to all Builder permissions.
  • builder.[command] Give access to [command].
  • builder.donate Allows players to donate to a builder in Supply Mode (useful for locking out creative mode players)

Configuration

See Configuration.

Builder will create Builder/config.yml if it does not exist already. Be sure to check the configuration page if new options are added.

Commands

All commands can be run on a selected NPC as shown (/builder [command]), or on a target NPC with /builder [npcid] [command].

/builder list - Lists all available schematics in the configured schematics folder. Does not require a builder selected.

/builder load [schematic] - Loads a .schematic file. simply use the name of the schematic. Example

/builder load house

/builder origin - Sets the origin of the builder's projects to the builder's current location. Allows you to re-build in the same spot. If this is not set the builder will always start from his current location.

/builder origin clear - Clears the saved build origin.

/builder origin schematic - Sets the origin of the builder's projects to the origin of the loaded schematic. Best used for schematics created from the builder's world with worldedit.

/builder origin me - Sets the origin of the builder's projects to the player's position. Does not work from the console.

/builder origin current - Sets the origin of the builder's projects to the origin of the project currently being built. Use this if you forgot to set the origin before starting to build, and need to cancel it to resume later.

/builder origin x,y,z - Sets the origin of the builder's projects to the location x,y,z of the builder's current world.

/builder mark (item) - Places a block at the 4 corners of the footprint, then returns to the origin, so you can see where it's going to build. You can specify the item to use, although that item must be allowed in the config.yml. The first item on the list in the config is the default if no item is specified. If the config is missing the builder will use GLASS.

/builder timeout [value] - Sets the maximum time, in seconds, between blocks. Valid values are 0.1 - 2000000.0. Default is 2.0. Default can be changed in the config.yml.

/builder build (option1) (option2) ... etc - Start building the schematic. This command takes several optional arguments. The order does not matter. you can add to this command the following:

  • linear - build north to south
  • reverselinear - build south to north
  • sprial - build inside to outside (this is the default and thus does not need to be specified.)
  • reversespiral - build outside to inside.
  • excavate - The builder will clear out the area of blocks before starting to place them.
  • layers:# - The builder will build # number of layers at a time, the default is 1.
  • yoffset:# - The builder will start building the specified number of blocks up or down from the set starting location.
  • groupall - the builder will build all of a group of materials at once, instead of doing it per layer.
  • ignoreair - the builder will not place air blocks. (Use to build into an existing structure, pointless if used with excavate)
  • ignoreliquid - the builder will not place lava or water blocks. (Use if the schematic has unconstrained liquids on the bottom.)
  • onstart:Task - the builder will run the Denizen task script on start of build (after material collection). See #Advanced Usage
  • oncomplete:Task - the builder will run the Denizen task script on completion of build. See #Advanced Usage
  • oncancel:Task - the builder will run the Denizen task script on cancellation of build. See #Advanced Usage
  • silent - the builder will not send completion/error messages to the command sender.

Examples:

/builder build
/builder build excavate reverselinear yoffset:-3
/builder build ignoreair ignoreliquid oncomplete:Celebrate
/builder build groupall layers:3

/builder cancel - Cancel a build job.

/builder info - View a Builder's loaded schematic name and size, as well as the builder's options and status.

/builder survey (excavate) - Display a list of all the block types/count it would require to build at the current location. Specify excavate to show the list of materials if excavation is used. Does not show water or lava.

/builder supply true|false set whether the builder will need to be given the materials before he will start building. See #Supply Mode

/builder hold true|false set whether the builder will hold the items he is placing (Turn off only for compatibility with other plugins like Sentry)

/builder reload - reload options from the builder config.yml

/builder help - Display the help.

Usage

  • .schematic files should be placed in the /plugins/Builder/schematics/ directory. This directory can be configured in the config.yml
  • Position the builder, or set the builder's origin, to the center of the footpoint you want to build before calling build. The size of the schematic is shown upon load.
  • You can cancel a build and resume it later if you have an Origin set. You can use /builder origin current to set the origin after building has started if you forgot.
  • Do not try to resume a build with the excavate option!
  • The builder will ignore any empty space underneath the schematic object so that it will always rest on the ground where the builder starts. If you want to build above or below the origin, use the yoffset: build option.
  • The builder will not attempt to replace blocks that are already set properly, this means you can use a builder to quickly 'restore' any changed blocks in something he has previously built.
    • To set up a builder to maintain an existing building:
      • Select the building with worldedit and save it as a schematic.
      • Copy the schematic to the builder's schematics directory.
      • Load the schematic to a builder and call /builder origin schematic.
      • Call /builder build and the builder will place any missing blocks or destroy new ones.
  • Rail and dispensers my not be placed correctly. (Hey this is Construction, not Engimaneerin'.)
  • By default, NPCs despawn when their chunk unloads. This behavior can be changed in the Citizens2 config.yml, and is recommended if you would like builders to continue to work unattended.

Supply Mode

If the Builder is set to require materials for building (with /builder supply true), he will go into Supply Mode when /builder build is called. When Supply Mode starts the Builder will survey the build site and generate a list of required materials to start building. Players must provide these materials for the builder to begin.

While in Supply Mode:

  • Right-Click the Builder with an empty hand to view the list of materials still needed.
  • Right-Click the Builder with any block or item to see if he needs it. If he does, he will tell you how much he still needs.
  • After clicking with a needed material, Right-Click again within a few seconds to give it to the Builder.
  • After receiving a material the Builder will say how many more blocks he needs in total to begin, or he will begin building if he has everything.

What materials are required:

  • By default all blocks require their normal drop type (i.e. Cobwebs require String)
  • This behavior can be overridden via the 'supply.txt' file found in the \Builder folder.
    • Each line contains the Item ID of the block in the schematic, and the ItemID of the block/Item that is required.
    • Optionally you can specify the number of blocks/items required for each source block.
    • Setting the required Item ID to 0 will not include that source block in the requirements.

All blocks are currently matched on Item ID only. This means:

  • All Wool is Wool. Color is ignored building the list, and any color wool can be given to fulfill the requirement.
  • The same goes for saplings, slabs, logs, and wood planks.
  • Stairs are similar. All wood stairs count as 'oak'. All stone/brick stairs count as 'stone' with the exception of nether brick stairs which are separate.

If the build is canceled at any point, the collected materials are lost.

Advanced Usage

  • Builder can be set to run Denizen Task Scripts on start, completion, or cancellation of a build.
    • The NPC must have both the Builder and Denizen Trait.
    • Call /builder build with the optional modifiers
      • onstart:TaskName
      • oncomplete:TaskName
      • oncancel:TaskName.

Example:

/builder build oncomplete:DespawnTask oncancel:AnnounceTask
  • Builder can also run Denizen Actions at the 3 indicated events. Add the following to the NPC's actions:
    • "Build Start"
    • "Build Complete"
    • "Build Cancel"

Example:

BuilderAssignment:
  type: assignment
  actions:
    on Build Start:
      - ANNOUNCE "Let's do this!"
    on Build Complete:
      - ANNOUNCE "I have finished!"

For more complex examples with Denizen and Builder see Builder and Denizen Examples

FAQ

Q: How can I use multiple builders on one project?

A: You can use up to 4 builders on one project by giving them all the same schematic and origin, but different build patterns. You can also manually split your schematic into multiple parts with WorldEdit or MCEdit.

Q: How can I make builders go faster?

A: Use the /builder timeout command to set the max time between blocks. You can also make the builder walk faster with "/npc speed"

Donate to jrbudda