Craft DataTags and trackedlocations
Describe in detail what your pull request accomplishes
Craft DataTags: Useful for storing any type of Data in Key-Value format, "aboard" a Craft Object. As long as the Craft Object isn't erased/lost-track-of, the DataTags will remain.
Example Use-Case: Storing a List of Players who can Activate Certain Types of Blocks on a craft. Keeping track of the Number of Damaging Hits Recieved and
TrackedLocations: A MovecraftLocation and/or HitBox-Object that will move "with" the Craft it is bound to, when the Craft Translates or Rotates
Example Use-Case: A Better "Movecraft-Cannons" Addon-Plugin. Where the Cannon's Locations are automatically Updated/Moved with the Craft upon any successful Movement/Rotation.
Checklist
- [x] Proper internationalization (N/A)
- [ ] Tested (I have been using my Private Version of this for like a year or two now.)
I have no real functional experience with Git & GitHub, so I don't really know how I'd split the PR in two, though, I agree.
My idea for Data Tags was a simple way to store any type of data "aboard" a Craft Object, while in existence, and you could keep track of a variety of things with that. Ex: You could keep tally of the names of other ships who you've sunk; or the different pilots you have blown up, etc. I feel that, while using a namespace key makes sense from a Developer's Perspective, who has worked with the internals of plugins a lot. But for those just starting to get into Movecraft and integrating it into other plugins and systems, personally, I think it should remain how it is
Personally I think translateBox/rotateBox probably should stay the same.
translateBox and rotateBox are a simple shortcut for rotating/moving HitBoxes independently of a craft's movements, not just a Collection of Tracked MovecraftLocations/HitBoxes.
While it is used for moving/rotating Tracked MovecraftLocations/HitBoxes in the MapUpdater section of my changes, that's not all I have used it for on my end.
I can see a variety of uses such as tracking a Subcraft's Hitbox aboard a Craft or even not physically attached to a Craft, and rotating that relative to the Parent Craft, or rotating/translating a Hitbox without being bound to a Craft. Hitboxes can be useful for other things than just determining a Craft's Bounds, and for me, at least, is useful for tracking a multiblock or set of disconnected-multiblocks aboard ships.
However, as for an actual TrackedLocation Object being created, I agree, but I still think using the non-relative MovecraftLocation should still be an option for those who just want a simple way of keeping track of coordinates.
This PR has been superseded by #616 and #673.