- Updated
factorio-datato version2.0.76(latest) - Added
ConstantCombinator.add_signalandConstantCombinator.get_signal- These make simple cases of setting a unique signals in a constant combinator much easier since you don't have to do the signal section management yourself
- Added
sqrt_lut.pyandtedius_inserters.pyto./examples - Merged Snagnar's pull request:
- Selector combinator
count_inputs_signalshould becount_signal
- Selector combinator
- Fixed #217 (Turret
priority_listshould bepriority-list)
- Updated
factorio-datato version2.0.71(latest) - Updated
Splitterto be circuit connectable (Factorio2.0.67) - Made more
SignalFilterattributes optional, bringing it more in line with how Factorio operates - Removed several hacks working around a bug in
attrs- Minimum
attrsversion is now25.4.0
- Minimum
- Fixed issues hidden by the hacky workaround of above bug
- Added (mostly) correct collision boxes for all new rail entities (
[Elevated]StraightRail,[Elevated]HalfDiagonalRail,[Elevated]CurvedRailA,[Elevated]CurvedRailB) - Fixed #205 (Cannot create or load an interrupt with targets)
- Fixed #207 (TypeError running README example)
- Removed validator issuing
GridAlignmentWarnings (possibly temporarily) due to lack of contextual information needed to make them useful and general code cruft
- Added Github workflow for automatically testing
draftsman update - Fixed #199 (draftsman update fails if multiple mods with no explicit dependencies)
- Fixed #200 (Failure to extract data from Factorio+ modpack)
- Added support for
Blueprint.parameters - Added
Valveprototype (added in Factorio2.0.48) - Improved Lua stack trace output on
LuaErrorswhen runningdraftsman update - Fixed #196 (draftsman update fails to load pyanadons mods)
- Fixed #197 (draftsman update fails on mod "Kuxynator's Production Rates")
- Updated
factorio-datato version2.0.64(latest stable) - Added
--ownsand--no-dlcarguments todraftsman updateanddraftsman.environment.run_data_lifecycle()(#184) - Added command
just benchmarkwhich will run a suite of benchmarks and record the result in a.benchmarksfolder - [PERF] Improved
ManualSection.get/set_signal()for requester chests and constant combinators - [PERF] Implemented a special
SpatialDataStructurefortiles, leading to ~16x speedup on adding tiles to blueprints - Fixed #185 (Load order inconsistencies/disparity on non-trivial mod lists)
- Updated
factorio-datato version2.0.63(latest stable) - Switched from
pydantictoattrs;- A much better fit for Draftsman's scope, much more flexible, and much less boilerplate to maintain
- Clearer distinction between loading steps:
- Constructors are for initializing Draftsman objects
from_dict()andfrom_string()methods are for importing from raw JSON/Blueprint Stringto_dict()andto_string()methods are for exporting to raw JSON/Blueprint String- Hooks are defined outside of the class scope which converts the raw JSON format to the internal Python object form
- This now means that the Python objects are not strictly tied to the JSON format, which means they can deviate for ease of use/performance reasons
- Conversion functions are separate from validation, meaning shorthands can be resolved even with validation functions turned off
- Draftsman entities can now handle importing/exporting between Factorio 1.0 and Factorio 2.0 blueprint string formats
- Simply specify
version=(1, 0)orversion=(2, 0)in any ofto/from_dict()orto/from_string()methods - While serialization/deserialization is correctly implemented, migration from an old to new string is not (fully) implemented, and so some parts will still have to be done manually
- For example, Draftsman will not convert a 1.0
"filter-inserter"into a 2.0"fast-inserter"for you
- For example, Draftsman will not convert a 1.0
- Simply specify
- Added tests to validate the exported formats of all objects match the above JSON schemas, on both game versions
- Added
draftsman.constants.InventoryTypewhich is part of defines - Changed the constant
ValidationMode.NONEto be the more explicitValidationMode.DISABLED - Removed the
validate_assignmentattribute entirely- Instead, validation is now on a global flag (until there is a good reason for it not to be); makes things much simpler
- Global flag can be acquired with
draftsman.validators.get_mode()and set withdraftsman.validators.set_mode(...) set_mode()can also be used as a context manager:# Default validation level is `STRICT` assert draftsman.validators.get_mode() is ValidationMode.STRICT with draftsman.validators.set_mode(ValidationMode.DISABLED): # No validators are run inside this block assert draftsman.validators.get_mode() is ValidationMode.DISABLED # Validation state returns to whatever it was set before assert draftsman.validators.get_mode() is ValidationMode.STRICT
- Calling a objects
validate()method is now guaranteed to also validate all of its children - Removed
RequestItemsMixinand implemented it directly inEntity(since all entities can request construction items) - Removed
__factorio_version__and__factorio_version_info__- Users should instead use
draftsman.data.mods.versions["base"]if you want to query the current Factorio version; this gives you the flexibility to change Factorio version midway through scripts (if necessary)
- Users should instead use
- Added
tilestoGroups(#118)Blueprint.entitiesis now 1-dimensional- A new attribute
Blueprint.groupsnow holds children associated with that blueprintblueprint = Blueprint() group = Group() group.entities.append("blah", position=...) blueprint.groups.append(group)
blueprint.entities[("a", "b", "c")]is nowblueprint.groups["a"].groups["b"].entities["c"], which is more explicit and allows for accessing the newly addedtilesattribute- However, ID-sequences are still permitted in function calls, a la:
blueprint.add_circuit_connection("red", ("a", "b", "c"), ("x", "y", "z"))
- Tidied up the build system
- Removed
setup.pyin favor of more modernpyproject.toml - You can now use
justwith draftsman to run common CI commands, see new README
- Removed
- Made docs pass and fixed code coverage
- Wrote an obnoxious amount of new and updated documentation
- Fixed an issue where certain mods would no be displayed correctly as disabled when using
draftsman list - Fixed #182 (Failing to update with any mods, with an AttributeError caused by an internal function.)
- Updated
factorio-datato version2.0.48(latest) - Fixed #164 (Decider combinator example doesn't work)
- Merged vjanell's pull request:
- Fix reversed operators in DeciderCombinator
__ge__and__le__methods
- Fix reversed operators in DeciderCombinator
- Fixed #178 (Entity flipping logic has multiple bugs and crashes)
- Updated
factorio-datato version2.0.45(latest) - Fixed #158 (Key "comparator" not found when exporting/importing Constant Combinator)
- Fixed #157 (Incompatibility with pydantic>=2.11)
- Updated
factorio-datato version2.0.41(latest) - Added
planets.get_surface_properties()which grabs a dict of surface properties with valid defaults - Added
Entity.surface_conditions, which maps directly to the Factorio APIsurface_conditions - Added
Entity.is_placeable_on(), which returns false if an entity'ssurface_conditionsprohibit their construction on a planet - Added
utils.passes_surface_conditions(), which acts as the abstract backend which runsEntity.is_placable_on()andrecipes.is_usable_on() - Added testing for
Asteroid Collector - Finished implementing features for
LogisticsContainers qualityis now an accessible and modifiable attribute ofEntitys- Made
Container.inventory_sizeproportional to the entity'squality- (note that all quality modifiers are not yet available)
- Merge RosieBaish's pull request:
- Add logic to allow mods with different special characters
- Merge Gavinp's pull requests:
- Add test for creating items with position
- Add test for recycler
get_world_bounding_box() draftsmannow prints usage/help on empty args.
- Fixed #142 (Logistics containers not importing properly)
- Fixed #121 (Support for Bob's Inserters)
- Fixed #151 (Severe Performance degradation when using
add_circuit_connection)
- Updated
factorio-datato version2.0.28(latest) - Updated
compatibility/defines.luato2.0.28(latest) - Updated all prototypes to match Factorio 2.0
- Added new prototypes in Factorio 2.0
AgriculturalTowerAsteroidCollectorCarCargoBayCargoLandingPadCurvedRailACurvedRailBDisplayPanelElevatedCurvedRailAElevatedCurvedRailBElevatedHalfDiagonalRailElevatedStraightRailFusionGeneratorFusionReactorHalfDiagonalRailLightningAttractorRailRampRailSupportSelectorCombinatorSpacePlatformHubSpiderVehicleThruster
- Removed command line utility
draftsman-update - Added command line utility
draftsmanwith multiple subcommandsdraftsman update ...for the original functionality of modifying a Factorio environmentdraftsman listto list all mods detected under a particular environmentdraftsman enable/disable ...enables or disables one or more modsdraftsman factorio-versionreports or sets the version of Factorio's datadraftsman versionreports Draftsman's own semantic version- Write
draftsman -hordraftsman [command] -hfor more information
- Swapped from
schematopydantic- Format for specifying schemas is now much clearer
- Both blueprintables and entities now share the same exporting code, overall making more sense
- Can now create a JSON schema of any entity or blueprintable (by calling
Object.json_schema()), which can be exported and used in any other program that reads JSON schema(!) - However, minimum Python version is now 3.7 to support type hints
- Switched from
unittesttopytest(more features with similar syntax;coverage runstill works the same) - Changed the code to be primarily Python3 compatible with the new minimum version
- Added
extrasmodule which implements some handy new features:- Added
flip_belts(blueprint)which flips all belt entities inside the blueprint (preserving continuity)
- Added
- Added a bunch of equivalent functions from the Factorio StdLib:
- Added
opposite(),next(),previous(),to_orientation(), andto_vector()toDirection - Added
Orientationclass, similar toDirection; comes with it's own suite of__add__(),to_direction(), andto_vector()helpers - Added
constants.Ticksenumeration which containsSECONDS,MINUTES,HOURS, etc. stored as quantities of Factorio ticks
- Added
- Added
union,intersection, anddifferencetoEntityList,TileList, andScheduleList - Updated
Directionto now be the Factorio 2.0 16-direction enum; useLegacyDirectionfor the old enumerations - Added
TrainConfiguration, which allows you to specify entire trains with strings like"1-4-1"and customize them on a per-car basis - Added
WaitConditionandWaitConditionsobjects which keep track of train station condition treesWaitConditionscan be combined using bitwiseandandorin order to collect them into aWaitConditionsobject:- Added
WaitConditionTypeandWaitConditionCompareTypeenumerations
- Added
Collection.add_train_at_position()andCollection.add_train_at_station()to make placing trains easier - Added
Collection.find_trains_filtered()to allow users to search Blueprints/Groups for trains of particular types - Added
RailPlanner(finally) - Added
data.fluidsmodule with some useful helpers - Added
data.planetsmodule allowing you to access planet metadata for things like surface properties - Added
data.items.fuelswhich is dict of sets of item names that fall under their respective fuel categories - Added data functions
signals.add_signal(),tiles.add_tile(),entities.add_entity(), etc. which allow you to add entities on the fly (primarily for Factorio environment compatibility) - Added
RequestItemsMixintoLocomotive,CargoWagon, andArtilleryWagon - Added
unknownkeyword to all entity/tile creation constructs which allows the user to specify what should happen when draftsman encounters an entity it doesn't recognize - Changed
InvalidEntityErrorandInvalidTileErrorsso that they now try to detect a similar tile/entity name and display that information to the user in the error message- For example, if you accidentally type
Container("wodenchest"), it will realize you probably meant to typeContainer("wooden-chest")and suggest that to you instead
- For example, if you accidentally type
- Added a bunch of new documentation to document the above
- Added a bunch of new examples to test out the above new features
- Added a fixture that ensures that Draftsman is running a vanilla configuration before running tests, and exits if it detects that it is not the case.
- Added a new command line option for
draftsman-update--lua-version, which prints the version of Lua currently being used for debugging compat issues - Added a README.md to the
examplesfolder which provides short descriptions for all of the examples - Integrated aforementioned examples into the test suite
- Removed the
area,tile_width, andtile_heightproperties fromBlueprint, which have been replaced withget_world_bounding_box()andget_dimensions()- These attributes are no longer cached in the blueprint and have to be recalculated each time such information is desired
- However, this means that it only has to be calculated when the user actually wants it, instead of every time a user adds a new entity/tile to a blueprint
- The user has a better idea of when they can cache the blueprint's dimension to reduce calculation, so it's deferred to the user
- By making them functions it also makes it abundantly clear that calling them is not likely
O(1)
- Added the
get_firstmethod to the defaults for the name of every entity- This means that if a data configuration has zero entities of a particular type, using a default name will result in a palatable error instead of something cryptic
- Added
indexattribute to allBlueprintabletypes, which allows the end user to customize the index in a parent BlueprintBook manually (Still autogenerated based on list order if unspecified, but now can be overridden) - Added data functions
signals.add_signal(),tiles.add_tile(),entities.add_entity(), etc. which allow you to add entities on the fly (primarily for Factorio environment compatibility) - Fixed a bunch of warts in the API:
- Added the ability to modify
xandyattributes of bothpositionandtile_positionand have each other update in tandem - Made it possible to rotate objects in parent
Collectionsas long as they're either square or rotated such that they preserve their original footprint (akin to Factorio) - Added
__eq__operators to pretty much all draftsman things (Entity,EntityList,TileList,ScheduleList,Schedule,WaitConditions, etc.) - Added more professional
__repr__functions to pretty much all draftsman things as well
- Added the ability to modify
- Normalized all import filenames to use underscores consistently (potentially breaking change!)
- Finished up documentation on
DeconstructionPlanner - [PERF] Reduced memory consumption by up to ~80 percent(!) (This also made it quite a bit faster to boot)
- Made it so that default
collision_maskkeys are resolved at once at the data level when you calldraftsman-update, so you can queryentities.rawfor the correct default value - Bumped Lupa to 2.0 which allows me to specify Lua version 5.2 which Factorio uses (#50)
draftsman-updatewill issue a warning if it cannot specify the correct Lua version: It'll still try to load and may still work anyway, but it's not guaranteed to\
- Added
--factorio-versioncommand fordraftsman-updatewhich either displays the current Factorio version or sets it to a specific Github tag - Patched InvalidModVersionError for now (#51)
- Removed
on_(tile/entity)_(insert/set/remove)from allEntityCollectionandTileCollectionclasses - Removed
on_(insert/set/remove)from allEntityimplementations as well (they were not used and are replaced with better things now) - Renamed
datamember to_rootmember onEntityListandTileList(Internal reasons) - Fixed issue #119
- Updated
factorio-datato version1.1.103 - Merged RosieBaish's pull request:
- Added an
extend()function toEntityListalong with notes about it's performance
- Added an
- Fixed issue #101 (finally)
- Added a number of missing prototype objects that are blueprintable:
SimpleEntityWithOwnerSimpleEntityWithForcePlayerPort
- Fixed an issue where color settings were not recognized in the settings stage (#103)
- Fixed issue loading IndustrialRevolution modpack (regression) (#98)
- Updated
factorio-datato version1.1.88 - Updated
compatibility/defines.luato1.1.88 - Merged arpheno's pull request:
- Fixed
Pumpso that it now correctly exports it'sdirection
- Fixed
- Merged SIGSTACKFAULT's pull requests:
- Fix type annotation of
Tile.__init__() - Fix type annotation of
BlueprintBook.insert()
- Fix type annotation of
draftsman-updateis now (finally) able to load mods from folder directories instead of just zip archivesdraftsman-updatewill now prefer mods in folders instead of zip archives if one of each type present and they have the exact same ID and version (I think this matches Factorio, create an issue if it's not)- Added
--reportcommand todraftsman-updatethat prints out a list of currently active mods and their versions (to aid in bug reports) - Fixed Lua
definestable not being defined by the timefactorio-data/coreruns (#85) - Fixed UTF-8 BOM tokens not being properly stripped from all mod Lua files, resulting in issues when sending to Lupa (#84)
- Changed the Lua load process a whole lot for
draftsman-update, hopefully behaving more predictably and causing no regressions
- Added
get_blueprintable_from_JSON()and patchedget_blueprintable_from_string()so that it no longer converts the string twice (accidentally) - Fixed issue where integer
playback_volumevalues on programmable speakers wasn't getting coerced to a float and failing validation (#72) - Fixed Blueprintable objects not being correctly initialized from their constructor when JSON dicts were passed as an argument (#75)
- Fixed
OverlappingObjectsWarningbeing incorrectly emitted whenGatesoverlapStraightRails(they now are only emitted if they're not perpendicular to each other) (#76) - Fixed
ConstantCombinatornot recognizing theis_onmember (#77)
- Updated
factorio-datato version1.1.80 - Updated
compatibility/defines.luato1.1.80 - Merged louga31's pull request:
- Fix recipes so that they correctly read either internal format
- Fixed an issue where not all entities were being assigned to
entities.flippable(#61) - Fixed mod dependency loading (hopefully) so that it should actually handle recursive requires across an arbitrary number of different mods (#70)
- Fixed an issue where required Lua files with a single prepended dot or slash would break the path resolution (#70)
- Updated
factorio-datato version1.1.76(latest stable) - Updated
compatibility/defines.luato1.1.76(latest stable) - Merged penguincounter's pull request:
- Fixed logistics requester and buffer chest signatures not having the correct
circuit_mode_of_operationkey
- Fixed logistics requester and buffer chest signatures not having the correct
- Added a
dump_format()method to entities that outputs a user friendly description of all of the possible key/value entries in the exported blueprint dict- Still needs to be done for Blueprintable; ideally there would be a
Exportableparent class that would implement the madness - Also need to investigate faster validation options since schema is pretty slow; maybe we can unify and improve speed at the same time
- Still needs to be done for Blueprintable; ideally there would be a
- Added a
get_format()method intended to get a readable formatted string (that can easily be autogenerated at the top of each entity in the documentation! Not yet but soon) - Changed
_exportsdict to be both more user readable and only defined on a per class basis instead of a per instance basis (so memory usage should be down) - Prepped
env.pyfor when Lupa version 2.0 goes live (which will resolve #50) - Fixed
"Mining_Drones_Harder"mod not loading because of stray "__MACOSX" folder defined alongside (#55) - Fixed
"FactorioExtended-Plus-Logistics"not loading due to internal file titled__init__.lua(#56) - Fixed
env.extract_entities().categorize_entities()togetflags instead of assuming they exist ("flags"set is common but optional)
- Added
UpgradePlannerandDeconstructionPlanner(#40) - Created an abstract class
Blueprintablewhich now implementsBlueprint,BlueprintBook,UpgradePlanner, andDeconstructionPlannerto increase code reuse - Added
descriptionattribute toBlueprintandBlueprintBook(#41) - Changed the behavior of
draftsman-updateto normalize all mod names to have no spaces (probably not perfect, but should work for now) (#49) - Added a
--pathargument todraftsman-updateso you can specify exactly where to load mods from instead of only the installation directory (#49) - Draftsman now distributes with a vanilla set of pickle data files, so you no longer need to run
draftsman-updateon first install (suggestion from rpdelaney) - Rolling Stock (Locomotives and Wagons) should now have proper collisions that are based on their
orientationand issue correct warnings (#47) - Updated the documentation around
draftsman-updateto make it more clear and reflect recent changes - Updated all
Blueprintabledocumentation files such that they now include a plaintext representation of their JSON structure
- Updated
factorio-datato version1.1.65 - Fixed #38 and #39
- Updated
factorio-datato version1.1.61 - Added a
Vectorclass to represent 2d positions, and changed most of the code to reflect this change- This is a breaking change, but it should be much more natural to access positions by attribute
xandyinstead of["x"]and["y"] - By specifying a class like this, custom operators are allowed such as vector math, which means that offsetting positions and other operations have become much easier as a result
Vectorhas a static member functionfrom_other()that constructs aVectorobject from all valid formats accepted in the past (tuple,dict,list, etc.) which is used in all standard functions, so you shouldn't have to change any of their signaturesVectoralso has ato_dict()method to turn it back into it's dictionary format for exporting ({"x": ..., "y": ...})- The
Vectorclass is only used on the "outermost" layer due to performance reasons, internally the most common representation is stilllist[float, float]
- This is a breaking change, but it should be much more natural to access positions by attribute
- Added an abstract
Shapeclass, along with two implementations:AABBandRectangleAABBandRectangleare now used for issuingOverlappingObjectWarning
- All functions that used to use
Sequencesorlist[list[float], list[float]]have been changed toVectorandAABBrespectively for user clarity - Added another class:
CollisionSet, which is a list ofShapesused for checking if twoEntitys intersect one another- This was needed because curved rails have 2 collision boxes instead of a single one
- Collision sets also support rotations, which means that rotations are automatically generated or specified manually for edge cases like rails
- In essence,
CollisionSetsprovide more flexibility for entity footprints on a per-entity-type (or even per-entity) level
- Added
find_entity_at_position()so you can simply check for any entity in particular at a position instead of having to use fully-blownfind_entities_filteredor the more-specificfind_entity()function - Abstracted
SpatialHashMapto be an implementation of abstract classSpatialDataStructure, which will allow for different implementations such as quadtrees or other algorithms if they happen to be more performant than hash-mapping (For now allCollectionsstill useSpatialHashMapthough) - Renamed
entity_hashmapandtile_hashmapto more genericentity_mapandtile_mapto reflect the above change - Move almost all entity insert/set/remove logic to
EntityCollection.on_entity_insert,on_entity_set, andon_entity_remove, which gets called fromEntityList.insertand related - Added
on_tile_insert,on_tile_set, andon_tile_removetoTileCollectionto mirror the changes toEntityCollection - Added
copykeyword toTileList.insertandTileList.appendto mirrorEntityList.insertandEntityList.append - Added Entity/Tile merging
- Added
mergekeyword to bothEntityList.insert/appendandTileList.insert/append - Attempting to use
merge=Truekeywords andcopy=Falsewill result in aValueError, as this behavior is loosely defined (for now at least)
- Added
- Rails now properly issue
OverlappingObjectsWarnings; Rails can overlap each other provided they don't have the exact same position + direction + type - Another big documentation pass
- Split the
signatures.CONTROL_BEHAVIORinto many sub implementations, which should improve both safety and (hopefully) performance - Fixed #24, #25, #27, #32, #33, and #34
- Merged louga31's pull request
- Rewrite of the
_shift_key_indicesinEntityListto make it faster using list comprehension
- Rewrite of the
- Merged elswindle's pull request
- Moved conversion of associations from
Blueprint.load_from_stringtoBlueprint.setupso they always take place - Fixed
UndergroundBeltio_typeattribute not reading correctly from keytype - Changed test case to account for this
- Moved conversion of associations from
- Added
DirectionalMixintoAssemblingMachine(as technically it can have it in select circumstances) - Fixed load conflict between
itemsandrecipeinAssemblingMachine(#23) - Fixed
setup.pyso that it properly requirestyping_extensionson versions of Python prior to 3.8 (#30) - Fixed importing
Literalso that it follows the above change (#30) - Fixed an issue where
BlueprintBookicons were not properly set and issued an incorrect warning (#31)
- Merged sposker's pull request
- Fixed an bug where
IndexErrorwould be triggered on setting the final item filter slot - Updated
signatures.CONTROL_BEHAVIORto include thesend_to_trainkey
- Fixed an bug where
- Merged elswindle's pull request
- Dictionary Blueprints and BlueprintBook's are now properly converted to
BlueprintandBlueprintBookobjects when added to aBlueprintableList
- Dictionary Blueprints and BlueprintBook's are now properly converted to
- Fixed documentation for
FilterMixin.set_item_filtersthat labeled"name"key as"signal" - Made docs for
FilterMixin.set_item_filtersandFilterMixin.set_item_filtermore clear - Changed
signals.rawto actually be the extraction fromdata.rawso people can query the order strings and other information (#17) - Sorted
signals.rawaccording to signal-processing order (virtual -> fluid -> item) instead of item sort order (#17) - Added
signals.type_ofas a more specific structure to fulfill the old functionality ofsignals.raw(#17) - Changed the functionality of
ConstantCombinatorso that attempting to set one of it's signals to a pure virtual signal results in aDraftsmanWarning(because for some grotesque reason Factorio actually allows this) - Renamed
InvalidConnectionErrorto more generalInvalidAssociationErrorand updated documentation - Removed requirement for
Groupsto have an ID associated with it (this was required in the past, but is no longer necessary) - Fixed unable to find connectable entities when calling
Blueprint.generate_power_connections()on blueprint that containedGroups(#19) - Added the capability to specify connections based on entity reference as well instead of just ID or index (
[add/remove]_power_connection,[add/remove]_circuit_connection) (#19)- Made these functions issue
InvalidAssociationErrorwhen attempting to connect two entities that lie outside of theEntityCollection - Added recursive
__contains__function toEntityListto facilitate the above
- Made these functions issue
- Fixed copying of entities between
BlueprintsandGroups(#20) - Added capability to deepcopy
Entities,Groups, andBlueprints, with appropriate errors - Added capability to set the
entitiesof aBlueprintorGroupto anotherBlueprintsorGroupsentities(#16) - Added optional
stringkeyword for the constructor ofGroupso you can import a blueprint string directly into a group instead of having to create a "scratch"Blueprint
- Added
keywordstosetup.py - Added
__contains__function toBlueprint(I thought it was inferred from__getitem__, whoops) (#14) - Added
defines.luaas a more comprehensive solution to the Factoriodefinesissue (#15) - Added distinguishing between multiple versions of the same mod; the latest mod is always preferred, with warnings for duplicates issued (#15)
- Started work on
RailPlanner - Other minor documentation changes
- Fixed the old repo link in
setup.py - Fixed #13:
- Implemented the functionality according to the game, preserving Factorio safety
- Added the new list
pure_virtualsignals todraftsman.data.signalsfor ease of access/iteration - Updated documentation to reflect these changes
- Moved initialization of
Blueprint.areaattribute before loading entities inBlueprint.setup()(#14)
- Added the capability to display any logged messages to during
draftsman-updatewith the command line argument-lor--log - Added
prep.pyto prepare releases more automatically so I don't miss steps like a fool (maybe I'll integrate something like poetry in the future) - Updated
env.pyto create thefactorio-modsfolder if it doesn't exist, in case the user accidentally deleted it - Updated
env.pyso that everything is now sorted (mostly) properly - Updated readme to point to related Alt-F4 article
- Updated
requirements.txtto includebuildfor development - Changed the manner in which sort items are searched in
env.py(related to issue #9) - Changed the manner in which the order of items are determined so there's less redundancy
- Changed
normalize_module_namefrom non-digit characters to alphanumeric characters (duh!) (#11) - Changed
normalize_module_nameto distinguish between "slash" paths and "dot" paths and only convert "dot" paths if found (#11) - Added more duct tape to the local file requiring issue machine (#11)
- Removed
temp.pyfrom GitHub distribution, it was only really intended as scrap paper for me - Fixed #10
- Fixed #12
- Fixed #9
- Added
signalsattribute toConstantCombinator, which aliasescontrol_behavior["filters"] - (Re)Added circuit attributes back to
ArithmeticCombinatorandDeciderCombinator - Minor docs fixes
- Bugfix: resolved #6
- Bugfix: resolved #8 (At least for now, current behavior should be more predictable)
- Also cleaned and documented the
updateprocess inenv.pyto make it a little clearer exactly what's going on, and trimmed the fat
- Updated
factorio-datato1.1.58 - Added description of
control_behaviorattribute structure todocs/sourcefolder - Added read-only
global_positionproperty toSpatialLike; allows for efficient querying of an objects root-most position - Added
SpatialHashMap.get_all - Added
utils.flatten_entitiessince it's used in a number of places - Added a
ItemCapacityWarning, issued when*Containerobjects request items that exceed their inventory size - Added
entities.flippableto hold whether or not each entity can be flipped or not (tentative, still WIP) - Integrated
entities.flippableintoEntityclass, as well asTransformable - Updated
tox.inito use--no-modsondraftsman-update - Reworked
SpatialHashMapandget_areato useglobal_positioninstead ofposition - Reworked
RequestItemsMixinand added it to more prototypes - Split
ModuleSlotsMixinfromRequestItemsMixinto compartmentalize more - Adding science pack item requests to a
Labno longer raises a warning (works with any lab) - Made
set_x_filtercode more consistent across different prototype filter types - Added folder loading to
draftsman-update - Documentation format fixes/additions
- Bugfix: Fixed the local paths that now point from
factorio-draftsmaninstead offactorio-draftsman/draftsmanindraftsman-updatefor folders - Bugfix: Changed Lua file requiring so that it makes (somewhat) more sense; Honestly the whole thing is pretty fricking scuffed, and needs a redo
- Bugfix: Fixed
OverlappingObjectsWarningoccurring when placing two groups with the same local coordinates but different global coordinates in anEntityCollection - Bugfix: Fixed Maximum recursion depth errors when running
examples/item_stack_signals.pywith large modpacks with many items; this should no longer occur period - Bugfix: Split
index_dictinenv.extract_itemstogroup_index_dictandsubgroup_index_dict - Bugfix: Encapsulated
orderswapping inenv.get_orderwith atry exceptblock
- Officially added to PyPI (in beta state for the foreseeable future)
- Finished first pass of documentation
- Added
factorio_version_testing.py, which tests against prior versions of Factorio - Draftsman is validated to work with versions of Factorio >= 1.0.0
- Added
Association, which is a loose wrapper aroundweakrefand takes care of the association problem - Added docs for
Association - Added
--no-modsflag todraftsman-updatethat just loads the base mod (why didn't I do this before)
- Added a whole lot of documentation, or a first pass at least
- Updated the quick-start with updated information
- Setup a GitHub workflow to automatically upload code coverage for the badge
- Split the
ModeOfOperationenumeration intoInserterModeOfOperationandLogisticModeOfOperation - Going to attempt to get Docs integration and passing
- Fixed
draftsman-updategreedy module name regex
- First public release!
- Added
Groups(!) - Added the
1KiB_sector_ROM.pyexample to illustrateGroups andrail_planner_usage.pyforRailPlanner(RailPlanneris not implemented yet) - Added
ltn_train_stop.pyexample - Lots of cleaning and formatting, though there's still many cases to analyze
- Added support for command line arguments with
draftsman-update(currently only--verbose) - updated
requirements.txt - Build system appears to be working as desired
- Backported to Python 2.7; tested via
toxthat it works with latest version of Python 2 and 3- (Should work with every version between, but I'm too lazy to test right now)
- Got everything prepared (I think) for building and ultimately distribution
- Fixed
setup.pyso that it should work with all versions greater than 2.7 (as well as requirements.txt) - Added entry-point
draftsman-updatethat must be called after installation to initialize the module - Lots of general folder restructuring (mainly moving everything needed into the module folder)
- Renamed
blueprint.pytoblueprintable.py - Formatted everything using
black - Updated readme
- Updated examples
- Removed some redundant files
- Split all of the mixins into their own files, as well as Entity, EntityLike, Group, etc.
- Added the
SpatialHashMapstructure for Blueprints to speed upfind_entitiesandfind_tiles - Added lots of utility functions related to
SpatialHashMap - Changed Blueprint
entitiesandtilestoKeyListinstead oflist - Added Blueprint warnings
- Changed ALL of the setters to use properties because I didn't know Python properties existed
- Revised test cases to match this revelation
- Unified all of the data into pickles instead of generating source files
- (Still need to figure out module init)
- Updated
.gitignoreto avoid committing previously mentioned pickle files - Added
warning.pyfor warning specification - Added lots of warnings and their messages
- Renamed
errors.pytoerror.pyto match the newwarning.py - Renamed all Errors to have the 'Error' suffix, renamed a few
- Added
DraftsmanErrorandDraftsmanWarningso you can catch any specific error or warning with them - Made the testing suite compatible (or, at least more compatible) with mods
- Added LogisticActiveContainer and LogisticPassiveContainer to complete the logistic suite (I think its clearer this way rather than treating them as containers)
- Hundreds of other small changes
- Finally finished entity testing (for now, reworks are coming)
- Split all of the entity definitions into their own file (much clearer)
- Added
image_converter.pyexample - Updated all other examples
- Changed data loading for items and entities to use pickle instead of writing source files (the rest need to be done like this I think)
- Renamed the package from "factoriotools" to the more succinct and pythonic "draftsman"
- General folder structure rework for both the package itself as well as testing
- Started the behemoth that is going to be Entity and Blueprint testing suites
- Added
.coveragercfor coverage configuration - Added this changelog
- Initial version