Jump to content

Area Maker


CryptoCode
 Share

Recommended Posts

Posted (edited)

I updated the code to include an "inclusive" mode.

By default, and if you were to manually create the Area object as you normally would, the northern and eastern boundaries are not included. This is an implementation decision on Java's part in how they handle shapes, and is thus reflected in the way EpicBot's Area class works.

Since I found this unintuitive, I added the option to "include" the boundaries. To make this work, when inclusive mode is enabled, the set of Tiles output is NOT identical to the set of Tiles selected; rather I generated a new set of Tiles that build an Area that includes the selected Tiles. 

I feel this option is more intuitive, and allows you to define Areas more predictably.

Feedback is appreciated!

 

area_maker_default.thumb.png.4c4499e9a8cbde9fbd1d7a72f7dffd33.png

area_maker_inclusive.thumb.png.084ec1a2f364150f36f0222076339290.png

Edited by CryptoCode
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...