aboutsummaryrefslogtreecommitdiff
path: root/src/math/mod.rs
Commit message (Collapse)AuthorAgeLines
* Add previously missing docs where appropriateArne Dußin2020-12-21-0/+2
|
* Refactor to make interaction between tools easierArne Dußin2020-12-15-16/+2
|
* Change to f64 as the preferred floating point numberArne Dußin2020-11-27-3/+7
|
* Make polygons deletableArne Dußin2020-11-26-0/+6
| | | | | | Before, the deletion tool was not targeting polygons. I also took the liberty to broaden the functionality of the surface trait, which now can check if a rectangle or polygon is contained.
* Move containment of points/ lines into traitArne Dußin2020-11-21-0/+10
|
* Move polygon functions into own modArne Dußin2020-11-21-4/+0
| | | | | The math module was starting to be mostly polygon files and functions, so those got their own subfolder to make the math module less of a mess.
* Add triangle struct and triangulation templateArne Dußin2020-11-21-0/+4
|
* Fix silly bug in min functionArne Dußin2020-11-18-3/+25
|
* Add polygon graphArne Dußin2020-11-17-0/+2
|
* Add polygon that can check if a point is insideArne Dußin2020-11-11-2/+29
| | | | | ..except for one super super edgy edge case, but I wanted to get this algorithm out into a commit before I ruin it completely (probably)
* Refactor a major part of the projectArne Dußin2020-11-01-0/+23
In order to be able to save and load the map, a major rework of the code seemed necessary, since Vector2 and Rectangle of raylib do not implement serialize, and it seems cleanest to use the serialize/deserialize traits of serde, to save for instance to RON. ToolShed was renamed to Editor, since it should better show, that it does quite a bit more than harbour tools. The map data is now centrally saved in the editor, instead of decentralised in the tool structs.